BDE 4.14.0 Production release
Loading...
Searching...
No Matches
balm::CategoryHolder Class Reference

#include <balm_category.h>

Public Member Functions

void reset ()
 
void setCategory (const Category *category)
 
void setEnabled (bool enabledFlag)
 
void setNext (CategoryHolder *holder)
 Set this holder to point to the specified holder.
 
const Categorycategory () const
 
bool enabled () const
 
CategoryHoldernext () const
 

Public Attributes

bool d_enabled
 
const Categoryd_category_p
 
CategoryHolderd_next_p
 

Detailed Description

This class, informally referred to as a "category holder" (or simply "holder"), holds a category, an enabled value, and a pointer to a "next" holder. Both the category and next pointer may be null. The intended use is as follows: (1) instances of this class are (only) declared in contexts where collecting a metric occurs; (2) if the enabled value is true, the category contains the address of a valid, enabled, category; (3) if the next pointer is non-null, then the holder pointed to holds the same category and threshold. Instances of this class must be statically initializable. Hence, the data members are public, and no constructors or destructor are defined.

This class should not be used directly by client code. It is an implementation detail of the balm metric collection system.

See balm_category

Member Function Documentation

◆ category()

const Category * balm::CategoryHolder::category ( ) const
inline

Return the address of the non-modifiable category held by this holder.

◆ enabled()

bool balm::CategoryHolder::enabled ( ) const
inline

Return true if category is valid (i.e., non-null) and enabled, and false otherwise.

◆ next()

CategoryHolder * balm::CategoryHolder::next ( ) const
inline

Return the address of the modifiable holder pointed to by this holder.

◆ reset()

void balm::CategoryHolder::reset ( )

Reset this object to its default value. The default value is:

{ false, 0, 0 }

◆ setCategory()

void balm::CategoryHolder::setCategory ( const Category category)
inline

Set the address of the category held by this holder to the specified category.

◆ setEnabled()

void balm::CategoryHolder::setEnabled ( bool  enabledFlag)
inline

Set the enabled state of this category to the value of the specified enabledFlag.

◆ setNext()

void balm::CategoryHolder::setNext ( CategoryHolder holder)
inline

Member Data Documentation

◆ d_category_p

const Category* balm::CategoryHolder::d_category_p

◆ d_enabled

bool balm::CategoryHolder::d_enabled

◆ d_next_p

CategoryHolder* balm::CategoryHolder::d_next_p

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