xrootd
Static Public Member Functions | List of all members
XrdCl::Utils Class Reference

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...
 

Detailed Description

Random utilities.

Member Function Documentation

std::string XrdCl::Utils::BytesToString ( uint64_t  bytes)
static

Convert bytes to a human readable string.

Referenced by ProgressDisplay::JobProgress().

XRootDStatus XrdCl::Utils::CheckTPC ( const std::string &  server)
static
uint64_t XrdCl::Utils::GetElapsedMicroSecs ( timeval  start,
timeval  end 
)
static

Get the elapsed microseconds between two timevals.

Referenced by XrdCl::ClassicCopyJob::Run(), and XrdCl::ThirdPartyCopyJob::Run().

Status XrdCl::Utils::GetHostAddresses ( std::vector< sockaddr_in > &  addresses,
const URL url 
)
static
XRootDStatus XrdCl::Utils::GetLocalCheckSum ( std::string &  checkSum,
const std::string &  checkSumType,
const std::string &  path 
)
static
XRootDStatus XrdCl::Utils::GetRemoteCheckSum ( std::string &  checkSum,
const std::string &  checkSumType,
const std::string &  server,
const std::string &  path 
)
static
void XrdCl::Utils::LogHostAddresses ( Log log,
uint64_t  type,
const std::string &  hostId,
std::vector< sockaddr_in > &  addresses 
)
static

Log all the addresses on the list.

References XrdCl::Log::Debug(), and XrdSysDNS::IPFormat().

Referenced by XrdCl::Stream::EnableLink().

template<class Container >
static void XrdCl::Utils::splitString ( Container &  result,
const std::string &  input,
const std::string &  delimiter 
)
inlinestatic
std::string XrdCl::Utils::TimeToString ( time_t  timestamp)
static

Convert timestamp to a string.

Referenced by XrdCl::TaskManager::RegisterTask(), and XrdCl::TaskManager::RunTasks().


The documentation for this class was generated from the following files: