BloombergLP::ball::LoggerCategoryUtil::setThresholdLevelsHierarchically

Set threshold levels for categories matching a hierarchical name prefix.

Synopsis

Declared in <ball_loggercategoryutil.h>

static
int
setThresholdLevelsHierarchically(
    LoggerManager* loggerManager,
    char const* categoryNamePrefix,
    int recordLevel,
    int passLevel,
    int triggerLevel,
    int triggerAllLevel);

Description

In case the specified categoryNamePrefix is not empty set, in the specified loggerManager, the threshold levels of every existing and future category whose name has, as a prefix, categoryNamePrefix to the specified threshold values, recordLevel, passLevel, triggerLevel, and triggerAllLevel. In case categoryNamePrefix is empty set the threshold level of every existing category, and remove all preliminary settings (for categories that do not exist yet). Return the number of categories whose threshold levels were set, and a negative value, with no effect, if any of the specified threshold values is outside the range [0 .. 255]. The behavior is undefined unless loggerManager is not in the process of being destroyed. See also ball::CategoryManager::setThresholdLevelsHierarchically.

Return Value

number of categories updated, or a negative value on error

Parameters

NameDescription
loggerManagerlogger manager whose categories are updated
categoryNamePrefixname prefix of categories to update
recordLevelrecord threshold level to set
passLevelpass threshold level to set
triggerLeveltrigger threshold level to set
triggerAllLeveltrigger-all threshold level to set