|
xrootd
|
Random utilities. More...
#include <XrdClUtils.hh>
Static Public Member Functions | |
| template<class Container > | |
| static void | splitString (Container &result, const std::string &input, const std::string &delimiter) |
| Split a string. More... | |
| static Status | GetHostAddresses (std::vector< sockaddr_in > &addresses, const URL &url) |
| Resolve IP addresses. More... | |
| static void | LogHostAddresses (Log *log, uint64_t type, const std::string &hostId, std::vector< sockaddr_in > &addresses) |
| Log all the addresses on the list. More... | |
| static std::string | TimeToString (time_t timestamp) |
| Convert timestamp to a string. More... | |
| static uint64_t | GetElapsedMicroSecs (timeval start, timeval end) |
| Get the elapsed microseconds between two timevals. More... | |
| static XRootDStatus | GetRemoteCheckSum (std::string &checkSum, const std::string &checkSumType, const std::string &server, const std::string &path) |
| Get a checksum from a remote xrootd server. More... | |
| static XRootDStatus | GetLocalCheckSum (std::string &checkSum, const std::string &checkSumType, const std::string &path) |
| Get a checksum from local file. More... | |
| static std::string | BytesToString (uint64_t bytes) |
| Convert bytes to a human readable string. More... | |
| static XRootDStatus | CheckTPC (const std::string &server) |
| Check if peer supports tpc. More... | |
Random utilities.
|
static |
Convert bytes to a human readable string.
Referenced by ProgressDisplay::JobProgress().
|
static |
Check if peer supports tpc.
References XrdCl::QueryCode::Config, XrdCl::Log::Debug(), XrdCl::errNotSupported, XrdCl::Log::Error(), XrdCl::Buffer::FromString(), XrdCl::DefaultEnv::GetLog(), XrdCl::Status::IsOK(), XrdCl::FileSystem::Query(), XrdCl::Status::status, XrdCl::stError, XrdCl::stFatal, XrdCl::XRootDStatus::ToStr(), XrdCl::Buffer::ToString(), and XrdCl::UtilityMsg.
Referenced by XrdCl::ThirdPartyCopyJob::CanDo().
|
static |
Get the elapsed microseconds between two timevals.
Referenced by XrdCl::ClassicCopyJob::Run(), and XrdCl::ThirdPartyCopyJob::Run().
|
static |
Resolve IP addresses.
References XrdCl::errInvalidAddr, XrdSysDNS::getHostAddr(), XrdCl::URL::GetHostName(), XrdCl::URL::GetPort(), and XrdCl::stError.
Referenced by XrdCl::Stream::EnableLink().
|
static |
Get a checksum from local file.
References XrdCl::CheckSumManager::Calculate(), XrdCl::Log::Dump(), XrdCl::errCheckSumError, XrdCl::errInternal, XrdCl::Log::Error(), XrdCksData::Get(), XrdCl::DefaultEnv::GetCheckSumManager(), XrdCl::DefaultEnv::GetLog(), XrdCksData::Set(), XrdCl::stError, and XrdCl::UtilityMsg.
|
static |
Get a checksum from a remote xrootd server.
References XrdCl::QueryCode::Checksum, XrdCl::Log::Dump(), XrdCl::errCheckSumError, XrdCl::errInternal, XrdCl::errInvalidResponse, XrdCl::Buffer::FromString(), XrdCl::DefaultEnv::GetLog(), XrdCl::Status::IsOK(), XrdCl::FileSystem::Query(), splitString(), XrdCl::stError, XrdCl::Buffer::ToString(), and XrdCl::UtilityMsg.
Referenced by XrdCl::ThirdPartyCopyJob::Run().
|
static |
Log all the addresses on the list.
References XrdCl::Log::Debug(), and XrdSysDNS::IPFormat().
Referenced by XrdCl::Stream::EnableLink().
|
inlinestatic |
Split a string.
Referenced by BuildPath(), XrdClTests::Utils::CRC32TextToInt(), XrdCl::PollerFactory::CreatePoller(), XrdCl::FSExecutor::Execute(), GetRemoteCheckSum(), main(), XrdCl::LocationInfo::ParseServerResponse(), XrdCl::StatInfo::ParseServerResponse(), XrdCl::StatInfoVFS::ParseServerResponse(), XrdCl::DirectoryList::ParseServerResponse(), XrdCl::XRootDMsgHandler::Process(), and XrdCl::URL::SetParams().
|
static |
Convert timestamp to a string.
Referenced by XrdCl::TaskManager::RegisterTask(), and XrdCl::TaskManager::RunTasks().
1.8.3.1