libbmq  a5f8a06ba1d16cb5a65643e1fa7f1a1d6aadef40
BloombergLP::bmqt::QueueFlagsUtil Struct Reference

#include <bmqt_queueflags.h>

Static Public Member Functions

static bool isSet (bsls::Types::Uint64 flags, QueueFlags::Enum flag)
 
static bool isValid (bsl::ostream &errorDescription, bsls::Types::Uint64 flags)
 
static bsls::Types::Uint64 empty ()
 The empty value for flags. More...
 
static bool isEmpty (bsls::Types::Uint64 flags)
 Returns true if the specified flags have the empty value. More...
 
static bool isReader (bsls::Types::Uint64 flags)
 Returns true if the specified flags represent a reader. More...
 
static bool isWriter (bsls::Types::Uint64 flags)
 Returns true if the specified flags represent a writer. More...
 
static bool isAdmin (bsls::Types::Uint64 flags)
 Returns true if the specified flags represent an admin. More...
 
static bool isAck (bsls::Types::Uint64 flags)
 Returns true if the specified flags represent ack required. More...
 
static void setReader (bsls::Types::Uint64 *flags)
 Sets the specified flags representation for reader. More...
 
static void setAdmin (bsls::Types::Uint64 *flags)
 Sets the specified flags representation for admin. More...
 
static void setWriter (bsls::Types::Uint64 *flags)
 Sets the specified flags representation for writer. More...
 
static void setAck (bsls::Types::Uint64 *flags)
 Sets the specified flags representation for ack. More...
 
static void unsetReader (bsls::Types::Uint64 *flags)
 Resets the specified flags representation for reader. More...
 
static void unsetAdmin (bsls::Types::Uint64 *flags)
 Resets the specified flags representation for admin. More...
 
static void unsetWriter (bsls::Types::Uint64 *flags)
 Resets the specified flags representation for writer. More...
 
static void unsetAck (bsls::Types::Uint64 *flags)
 Resets the specified flags representation for ack. More...
 
static bsls::Types::Uint64 additions (bsls::Types::Uint64 oldFlags, bsls::Types::Uint64 newFlags)
 
static bsls::Types::Uint64 removals (bsls::Types::Uint64 oldFlags, bsls::Types::Uint64 newFlags)
 
static bsl::ostream & prettyPrint (bsl::ostream &stream, bsls::Types::Uint64 flags)
 
static int fromString (bsl::ostream &errorDescription, bsls::Types::Uint64 *out, const bsl::string &str)
 

Member Function Documentation

◆ isSet()

bool BloombergLP::bmqt::QueueFlagsUtil::isSet ( bsls::Types::Uint64  flags,
QueueFlags::Enum  flag 
)
inlinestatic

Return true if the bit-mask in the specified flags has the specified flag set, or false if not.

DEPRECATED: This method is deprecated in favor of the below more specific accessors; and should be made private once all clients have been updated to the new APIs.

Referenced by isAck(), isAdmin(), isReader(), and isWriter().

◆ isValid()

static bool BloombergLP::bmqt::QueueFlagsUtil::isValid ( bsl::ostream &  errorDescription,
bsls::Types::Uint64  flags 
)
static

Check whether the specified flags represent a valid combination of flags to use for opening a queue. Return true if it does, or false if some exclusive flags are both set, and populate the specified errorDescription with the reason of the failure.

◆ empty()

bsls::Types::Uint64 BloombergLP::bmqt::QueueFlagsUtil::empty ( )
inlinestatic

Referenced by isEmpty().

◆ isEmpty()

bool BloombergLP::bmqt::QueueFlagsUtil::isEmpty ( bsls::Types::Uint64  flags)
inlinestatic

References empty().

◆ isReader()

bool BloombergLP::bmqt::QueueFlagsUtil::isReader ( bsls::Types::Uint64  flags)
inlinestatic

◆ isWriter()

bool BloombergLP::bmqt::QueueFlagsUtil::isWriter ( bsls::Types::Uint64  flags)
inlinestatic

◆ isAdmin()

bool BloombergLP::bmqt::QueueFlagsUtil::isAdmin ( bsls::Types::Uint64  flags)
inlinestatic

◆ isAck()

bool BloombergLP::bmqt::QueueFlagsUtil::isAck ( bsls::Types::Uint64  flags)
inlinestatic

◆ setReader()

void BloombergLP::bmqt::QueueFlagsUtil::setReader ( bsls::Types::Uint64 *  flags)
inlinestatic

◆ setAdmin()

void BloombergLP::bmqt::QueueFlagsUtil::setAdmin ( bsls::Types::Uint64 *  flags)
inlinestatic

◆ setWriter()

void BloombergLP::bmqt::QueueFlagsUtil::setWriter ( bsls::Types::Uint64 *  flags)
inlinestatic

◆ setAck()

void BloombergLP::bmqt::QueueFlagsUtil::setAck ( bsls::Types::Uint64 *  flags)
inlinestatic

◆ unsetReader()

void BloombergLP::bmqt::QueueFlagsUtil::unsetReader ( bsls::Types::Uint64 *  flags)
inlinestatic

◆ unsetAdmin()

void BloombergLP::bmqt::QueueFlagsUtil::unsetAdmin ( bsls::Types::Uint64 *  flags)
inlinestatic

◆ unsetWriter()

void BloombergLP::bmqt::QueueFlagsUtil::unsetWriter ( bsls::Types::Uint64 *  flags)
inlinestatic

◆ unsetAck()

void BloombergLP::bmqt::QueueFlagsUtil::unsetAck ( bsls::Types::Uint64 *  flags)
inlinestatic

◆ additions()

static bsls::Types::Uint64 BloombergLP::bmqt::QueueFlagsUtil::additions ( bsls::Types::Uint64  oldFlags,
bsls::Types::Uint64  newFlags 
)
static

Return a new flag mask that only set bits are the ones that are in the specified newFlags and not in the specified oldFlags.

◆ removals()

static bsls::Types::Uint64 BloombergLP::bmqt::QueueFlagsUtil::removals ( bsls::Types::Uint64  oldFlags,
bsls::Types::Uint64  newFlags 
)
static

Return a new flag mask that only set bits are the ones that are in the specified oldFlags and not in the specified newFlags.

◆ prettyPrint()

static bsl::ostream& BloombergLP::bmqt::QueueFlagsUtil::prettyPrint ( bsl::ostream &  stream,
bsls::Types::Uint64  flags 
)
static

Print the ascii-representation of all the values set in the specified flags to the specified stream. Each value is , separated.

◆ fromString()

static int BloombergLP::bmqt::QueueFlagsUtil::fromString ( bsl::ostream &  errorDescription,
bsls::Types::Uint64 *  out,
const bsl::string &  str 
)
static

Convert the string representation of the enum bit mask from the specified str (which format corresponds to the one of the prettyPrint method) and populate the specified out with the result on success returning 0, or return a non-zero error code on error, populating the specified errorDescription with a description of the error.


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