Utility Code

C++ utilty declarations.

Utility code used to implement the Cuddl C++ API. The following entities are defined in the cuddl namespace.

template<class F>
class Flags

C++ class template used to implement MemRegionFlags, MemRegionClaimFlags, MemRegionMapFlags, EventSrcFlags, EventSrcClaimFlags, and EventSrcOpenFlags.

Constructors

inline Flags(int flags = 0)
inline Flags(const F &f)

Public Functions

inline int as_int() const

Return an integer representation of the flags.

inline bool is_set(const F &f) const

Test if a specified flag bit is set.

inline void set(const F &f)

Set the specified flag bit.

inline void clear(const F &f)

Clear the specified flag bit.

inline void set(const Flags &f)

Set the specified flag bits.

inline void clear(const Flags &f)

Clear the specified flag bits.

inline Flags &operator|=(const F &r)

Alias for set().

inline Flags &operator|=(const Flags &r)

Alias for set().

inline Flags operator|(const F &r)

Combine flags together.

inline Flags operator|(const Flags &r)

Combine sets of flags together.