19#ifndef __XRD_CL_SOCKET_HH__
20#define __XRD_CL_SOCKET_HH__
24#include <sys/socket.h>
36 class AsyncSocketHandler;
105 uint16_t timout = 10 );
115 uint16_t timout = 10 );
147 uint32_t &bytesRead );
158 uint32_t &bytesWritten );
303 const std::string &thehost = std::string() );
Definition: XrdClAnyObject.hh:33
Definition: XrdClAsyncSocketHandler.hh:43
The message representation used throughout the system.
Definition: XrdClMessage.hh:30
A network socket.
Definition: XrdClSocket.hh:43
const AnyObject * GetChannelID() const
Definition: XrdClSocket.hh:255
std::string GetSockName() const
Get the name of the socket.
std::string pSockName
Definition: XrdClSocket.hh:330
std::string GetName() const
Get the string representation of the socket.
XRootDStatus Send(const char *buffer, size_t size, int &bytesWritten)
XRootDStatus Initialize(int family=AF_INET)
Initialize the socket.
Socket(int socket=-1, SocketStatus status=Disconnected)
SocketStatus
Status of the socket.
Definition: XrdClSocket.hh:49
@ Disconnected
The socket is disconnected.
Definition: XrdClSocket.hh:50
@ Connected
The socket is connected.
Definition: XrdClSocket.hh:51
@ Connecting
The connection process is in progress.
Definition: XrdClSocket.hh:52
void SetChannelID(AnyObject *channelID)
Definition: XrdClSocket.hh:246
SocketStatus pStatus
Definition: XrdClSocket.hh:328
XRootDStatus Send(Message &msg, const std::string &strmname)
AnyObject * pChannelID
Definition: XrdClSocket.hh:334
static XRootDStatus ClassifyErrno(int error)
XRootDStatus Read(char *buffer, size_t size, int &bytesRead)
std::unique_ptr< Tls > pTls
Definition: XrdClSocket.hh:337
XRootDStatus ConnectToAddress(const XrdNetAddr &addr, uint16_t timout=10)
int pSocket
Definition: XrdClSocket.hh:327
int GetFD()
Get the file descriptor.
Definition: XrdClSocket.hh:214
XRootDStatus SetSockOpt(int level, int optname, const void *optval, socklen_t optlen)
Set socket options.
bool IsCorked() const
Definition: XrdClSocket.hh:286
XRootDStatus ReadV(iovec *iov, int iocnt, int &bytesRead)
XRootDStatus TlsHandShake(AsyncSocketHandler *socketHandler, const std::string &thehost=std::string())
const XrdNetAddr * GetServerAddress() const
Get the server address.
Definition: XrdClSocket.hh:237
XRootDStatus GetFlags(int &flags)
Get the socket flags (man fcntl)
uint8_t MapEvent(uint8_t event)
std::string pName
Definition: XrdClSocket.hh:332
XRootDStatus Send(XrdSys::KernelBuffer &kbuff, int &bytesWritten)
XRootDStatus Connect(const std::string &host, uint16_t port, uint16_t timout=10)
int pProtocolFamily
Definition: XrdClSocket.hh:333
XRootDStatus GetSockOpt(int level, int optname, void *optval, socklen_t *optlen)
Get socket options.
XRootDStatus WriteRaw(void *buffer, uint32_t size, int32_t timeout, uint32_t &bytesWritten)
std::string pPeerName
Definition: XrdClSocket.hh:331
bool pCorked
Definition: XrdClSocket.hh:335
XRootDStatus ReadRaw(void *buffer, uint32_t size, int32_t timeout, uint32_t &bytesRead)
SocketStatus GetStatus() const
Get the socket status.
Definition: XrdClSocket.hh:125
XRootDStatus Poll(bool readyForReading, bool readyForWriting, int32_t timeout)
std::unique_ptr< XrdNetAddr > pServerAddr
Definition: XrdClSocket.hh:329
void SetStatus(SocketStatus status)
Set socket status - do not use unless you know what you're doing.
Definition: XrdClSocket.hh:133
XRootDStatus SetFlags(int flags)
Set the socket flags (man fcntl)
std::string GetPeerName() const
Get the name of the remote peer.
Request status.
Definition: XrdClXRootDResponses.hh:219
Definition: XrdNetAddr.hh:42
Definition: XrdSysKernelBuffer.hh:46
Definition: XrdClAction.hh:34
Definition: XrdOucIOVec.hh:65