xrootd
Loading...
Searching...
No Matches
Public Member Functions | Private Types | Private Attributes | List of all members
XrdCl::AsyncHSWriter Class Reference

Utility class encapsulating writing hand-shake request logic. More...

#include <XrdClAsyncHSWriter.hh>

Collaboration diagram for XrdCl::AsyncHSWriter:
Collaboration graph
[legend]

Public Member Functions

 AsyncHSWriter (Socket &socket, const std::string &strmname)
 
void Reset (Message *msg=nullptr)
 Reset the state of the object (makes it ready to read out next msg)
 
void Replay ()
 Replay the message that has been sent.
 
bool HasMsg ()
 Check if writer was assigned with a message.
 
XRootDStatus Write ()
 Write the request into the socket.
 

Private Types

enum  Stage { WriteRequest , WriteDone }
 Stages of reading out a response from the socket. More...
 

Private Attributes

Stage writestage
 
Socketsocket
 
const std::string & strmname
 
std::unique_ptr< Messageoutmsg
 

Detailed Description

Utility class encapsulating writing hand-shake request logic.

Member Enumeration Documentation

◆ Stage

Stages of reading out a response from the socket.

Enumerator
WriteRequest 
WriteDone 

Constructor & Destructor Documentation

◆ AsyncHSWriter()

XrdCl::AsyncHSWriter::AsyncHSWriter ( Socket socket,
const std::string &  strmname 
)
inline

Constructor

Parameters
socket: the socket with the message to be read out
strmname: stream name

Member Function Documentation

◆ HasMsg()

bool XrdCl::AsyncHSWriter::HasMsg ( )
inline

Check if writer was assigned with a message.

References outmsg.

◆ Replay()

void XrdCl::AsyncHSWriter::Replay ( )
inline

Replay the message that has been sent.

References outmsg, WriteRequest, and writestage.

◆ Reset()

void XrdCl::AsyncHSWriter::Reset ( Message msg = nullptr)
inline

Reset the state of the object (makes it ready to read out next msg)

References outmsg, WriteRequest, and writestage.

◆ Write()

XRootDStatus XrdCl::AsyncHSWriter::Write ( )
inline

Member Data Documentation

◆ outmsg

std::unique_ptr<Message> XrdCl::AsyncHSWriter::outmsg
private

Referenced by HasMsg(), Replay(), Reset(), and Write().

◆ socket

Socket& XrdCl::AsyncHSWriter::socket
private

Referenced by Write().

◆ strmname

const std::string& XrdCl::AsyncHSWriter::strmname
private

Referenced by Write().

◆ writestage

Stage XrdCl::AsyncHSWriter::writestage
private

Referenced by Replay(), Reset(), and Write().


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