#include <ball_thresholdaggregate.h>
This class implements an aggregate of the four logging threshold levels.
See ball_thresholdaggregate
◆ ThresholdAggregate() [1/3]
ball::ThresholdAggregate::ThresholdAggregate |
( |
| ) |
|
|
inline |
◆ ThresholdAggregate() [2/3]
ball::ThresholdAggregate::ThresholdAggregate |
( |
int |
recordLevel, |
|
|
int |
passLevel, |
|
|
int |
triggerLevel, |
|
|
int |
triggerAllLevel |
|
) |
| |
|
inline |
Create a threshold aggregate whose threshold levels are the specified recordLevel
, passLevel
, triggerLevel
, and triggerAllLevel
, respectively. The behavior is undefined if any threshold level is not in the range [0 .. 255]
.
◆ ThresholdAggregate() [3/3]
Create a threshold aggregate having the same value as that of the specified original
threshold aggregate.
◆ ~ThresholdAggregate()
ball::ThresholdAggregate::~ThresholdAggregate |
( |
| ) |
|
|
default |
◆ areValidThresholdLevels()
bool ball::ThresholdAggregate::areValidThresholdLevels |
( |
int |
recordLevel, |
|
|
int |
passLevel, |
|
|
int |
triggerLevel, |
|
|
int |
triggerAllLevel |
|
) |
| |
|
inlinestatic |
Return true
if each of the specified recordLevel
, passLevel
, triggerLevel
, and triggerAllLevel
threshold values is in the range [0 .. 255]
, and false
otherwise.
◆ hash()
static int ball::ThresholdAggregate::hash |
( |
const ThresholdAggregate & |
aggregate, |
|
|
int |
size |
|
) |
| |
|
static |
Return a hash value calculated from the specified threshold aggregate
using the specified size
as the number of slots. The hash value is guaranteed to be in the range [0, size - 1]
. The behavior is undefined unless 0 < size
.
◆ maxLevel() [1/2]
Return the numerically greatest of the four logging threshold levels held by the specified threshold aggregate
.
◆ maxLevel() [2/2]
static int ball::ThresholdAggregate::maxLevel |
( |
int |
recordLevel, |
|
|
int |
passLevel, |
|
|
int |
triggerLevel, |
|
|
int |
triggerAllLevel |
|
) |
| |
|
static |
Return the numerically greatest of the specified recordLevel
, passLevel
, triggerLevel
, and triggerAllLevel
values.
◆ operator=()
Assign the value of the specified rhs
threshold aggregate to this aggregate, and return a reference to this modifiable aggregate.
◆ passLevel()
int ball::ThresholdAggregate::passLevel |
( |
| ) |
const |
|
inline |
◆ print()
bsl::ostream & ball::ThresholdAggregate::print |
( |
bsl::ostream & |
stream, |
|
|
int |
level = 0 , |
|
|
int |
spacesPerLevel = 4 |
|
) |
| const |
Format this object to the specified output stream
at the (absolute value of) the optionally specified indentation level
and return a reference to stream
. If level
is specified, optionally specify spacesPerLevel
, the number of spaces per indentation level for this and all of its nested objects. If level
is negative, suppress indentation of the first line. If spacesPerLevel
is negative, format the entire output on one line, suppressing all but the initial indentation (as governed by level
). If stream
is not valid on entry, this operation has no effect.
◆ recordLevel()
int ball::ThresholdAggregate::recordLevel |
( |
| ) |
const |
|
inline |
◆ setLevels()
int ball::ThresholdAggregate::setLevels |
( |
int |
recordLevel, |
|
|
int |
passLevel, |
|
|
int |
triggerLevel, |
|
|
int |
triggerAllLevel |
|
) |
| |
Set the threshold levels of this threshold aggregate to the specified recordLevel
, passLevel
, triggerLevel
, and triggerAllLevel
values, respectively, if each of the specified values is in the range [0 .. 255]
. Return 0 on success, and a non-zero value otherwise (with no effect on the threshold levels of this aggregate).
◆ setPassLevel()
void ball::ThresholdAggregate::setPassLevel |
( |
int |
passLevel | ) |
|
|
inline |
Set the pass level of this threshold aggregate to the specified passLevel
.
◆ setRecordLevel()
void ball::ThresholdAggregate::setRecordLevel |
( |
int |
recordLevel | ) |
|
|
inline |
Set the record level of this threshold aggregate to the specified recordLevel
.
◆ setTriggerAllLevel()
void ball::ThresholdAggregate::setTriggerAllLevel |
( |
int |
triggerAllLevel | ) |
|
|
inline |
Set the trigger-all level of this threshold aggregate to the specified triggerAllLevel
.
◆ setTriggerLevel()
void ball::ThresholdAggregate::setTriggerLevel |
( |
int |
triggerLevel | ) |
|
|
inline |
Set the trigger level of this threshold aggregate to the specified triggerLevel
.
◆ triggerAllLevel()
int ball::ThresholdAggregate::triggerAllLevel |
( |
| ) |
const |
|
inline |
◆ triggerLevel()
int ball::ThresholdAggregate::triggerLevel |
( |
| ) |
const |
|
inline |
◆ operator==
Return true
if the specified lhs
and rhs
threshold aggregates have the same value, and false
otherwise. Two threshold aggregates have the same value if all four of their respective threshold levels are the same.
The documentation for this class was generated from the following file: