XrdCl::ParallelOperation< HasHndl >::Ctx Struct Reference

List of all members.

Public Member Functions

 Ctx (PipelineHandler *handler, PolicyExecutor *policy)
 ~Ctx ()
 Destructor.
void Examine (const XRootDStatus &st)
void Handle (const XRootDStatus &st)

Public Attributes

std::atomic< PipelineHandler * > handler
 PipelineHandler of the ParallelOperation.
std::unique_ptr< PolicyExecutorpolicy
 Policy defining when the user handler should be called.

Detailed Description

template<bool HasHndl>
struct XrdCl::ParallelOperation< HasHndl >::Ctx

Helper class for handling the PipelineHandler of the ParallelOperation (RAII).

Guarantees that the handler will be executed exactly once.


Constructor & Destructor Documentation

template<bool HasHndl>
XrdCl::ParallelOperation< HasHndl >::Ctx::Ctx ( PipelineHandler handler,
PolicyExecutor policy 
) [inline]

Constructor.

Parameters:
handler : the PipelineHandler of the Parallel operation
template<bool HasHndl>
XrdCl::ParallelOperation< HasHndl >::Ctx::~Ctx (  )  [inline]

Member Function Documentation

template<bool HasHndl>
void XrdCl::ParallelOperation< HasHndl >::Ctx::Examine ( const XRootDStatus st  )  [inline]

Forwards the status to the PipelineHandler if the handler haven't been called yet.

Parameters:
st : status

References XrdCl::ParallelOperation< HasHndl >::Ctx::Handle(), and XrdCl::ParallelOperation< HasHndl >::Ctx::policy.

template<bool HasHndl>
void XrdCl::ParallelOperation< HasHndl >::Ctx::Handle ( const XRootDStatus st  )  [inline]

Member Data Documentation

template<bool HasHndl>
std::atomic<PipelineHandler*> XrdCl::ParallelOperation< HasHndl >::Ctx::handler
template<bool HasHndl>
std::unique_ptr<PolicyExecutor> XrdCl::ParallelOperation< HasHndl >::Ctx::policy

Policy defining when the user handler should be called.

Referenced by XrdCl::ParallelOperation< HasHndl >::Ctx::Examine().


The documentation for this struct was generated from the following file:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines

Generated on 7 Jul 2020 for xrootd by  doxygen 1.6.1