lcls2
C++ API: public headers of xtcdata, psalg, psdaq and psana
Loading...
Searching...
No Matches
Pds::Fabrics::Info Class Reference

Owns a libfabric fi_info hints structure, preset by initialize() for FI_EP_MSG endpoints with FI_MSG and FI_RMA capabilities, FI_SOCKADDR_IN addresses and FI_RX_CQ_DATA mode. More...

#include <Endpoint.hh>

Inherits Pds::Fabrics::ErrorHandler.

Public Member Functions

 Info ()
 Allocate and preset the hints; ready() reports whether this succeeded.
 
 Info (const std::map< std::string, std::string > &kwargs)
 Allocate and preset the hints, then apply the optional kwargs entries ep_fabric, ep_domain and ep_provider as fabric name, domain name and provider name.
 
 ~Info ()
 Free the hints with fi_freeinfo() if this object still owns them.
 
void take_hints ()
 Give up ownership of hints so that the destructor does not free them.
 
bool ready () const
 Return the ready flag set by the constructor.
 
- Public Member Functions inherited from Pds::Fabrics::ErrorHandler
 ErrorHandler ()
 Allocate the message buffer and start with no error (FI_SUCCESS and a message built from the text None).
 
virtual ~ErrorHandler ()
 Free the message buffer.
 
int error_num () const
 Return the last recorded error number (FI_SUCCESS if none).
 
const char * error () const
 Return the last recorded error message.
 
void clear_error ()
 Reset the error number to FI_SUCCESS and the message to the no-error text.
 

Public Attributes

struct fi_info * hints
 Hints for fi_getinfo(); owned by this object unless take_hints() was called.
 

Additional Inherited Members

- Protected Member Functions inherited from Pds::Fabrics::ErrorHandler
void set_custom_error (const char *fmt,...)
 
void set_error (const char *error_desc)
 
- Protected Attributes inherited from Pds::Fabrics::ErrorHandler
int _errno
 
char * _error
 

Detailed Description

Owns a libfabric fi_info hints structure, preset by initialize() for FI_EP_MSG endpoints with FI_MSG and FI_RMA capabilities, FI_SOCKADDR_IN addresses and FI_RX_CQ_DATA mode.

Constructor & Destructor Documentation

◆ Info() [1/2]

Pds::Fabrics::Info::Info ( )

Allocate and preset the hints; ready() reports whether this succeeded.

◆ Info() [2/2]

Pds::Fabrics::Info::Info ( const std::map< std::string, std::string > &  kwargs)

Allocate and preset the hints, then apply the optional kwargs entries ep_fabric, ep_domain and ep_provider as fabric name, domain name and provider name.

Note that ready() is set true even if the allocation failed.

◆ ~Info()

Pds::Fabrics::Info::~Info ( )

Free the hints with fi_freeinfo() if this object still owns them.

Member Function Documentation

◆ ready()

bool Pds::Fabrics::Info::ready ( ) const

Return the ready flag set by the constructor.

◆ take_hints()

void Pds::Fabrics::Info::take_hints ( )

Give up ownership of hints so that the destructor does not free them.

Member Data Documentation

◆ hints

struct fi_info* Pds::Fabrics::Info::hints

Hints for fi_getinfo(); owned by this object unless take_hints() was called.


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