| Package | org.as3commons.logging.setup |
| Class | public final class HierarchicalSetup |
| Inheritance | HierarchicalSetup Object |
| Implements | ILogSetup |
| Since : | 2.7 |
Much like a log4j setup this setup allows hierarchical defininition of loggers. It allows the definition of a target and level per hierarchy level and automatically pass it to all sublevels.
The setup allows to define a "threshold", a global maximal LogLevel. This allows to switch off the setup with a simple flag.
| Property | Defined By | ||
|---|---|---|---|
| threshold : LogSetupLevel [write-only]
Global threshold that limits the output levels. | HierarchicalSetup | ||
| Method | Defined By | ||
|---|---|---|---|
HierarchicalSetup(levelSeparator:String = ., threshold:LogSetupLevel = null)
Creates a new HierarchicalSetup
| HierarchicalSetup | ||
Sets targets of the passed-in Logger to the ones
desired by the setup. | HierarchicalSetup | ||
setHierarchy(path:String = null, target:ILogTarget = null, level:LogSetupLevel = null, additive:Boolean = true):void
Sets the properties of one hierarchy level
| HierarchicalSetup | ||
| threshold | property |
threshold:LogSetupLevel [write-only] Global threshold that limits the output levels.
public function set threshold(value:LogSetupLevel):void| HierarchicalSetup | () | Constructor |
public function HierarchicalSetup(levelSeparator:String = ., threshold:LogSetupLevel = null)
Creates a new HierarchicalSetup
levelSeparator:String (default = .) — Seperator for the levels in our hierarchy (as loggers just have names)
| |
threshold:LogSetupLevel (default = null) — Global threshold that limits the output level.
|
| applyTo | () | method |
public function applyTo(logger:Logger):void
Sets targets of the passed-in Logger to the ones
desired by the setup.
The setup should fill the desired targets to the Logger
instances created by LoggerFactory.
Parameters
logger:Logger — Logger to be augmented by the setup
|
| setHierarchy | () | method |
public function setHierarchy(path:String = null, target:ILogTarget = null, level:LogSetupLevel = null, additive:Boolean = true):voidSets the properties of one hierarchy level
Parameters
path:String (default = null) — Hierarchy path, unseparated.
| |
target:ILogTarget (default = null) — Target to be used for logging in this hierarchy and subhierarchies.
| |
level:LogSetupLevel (default = null) — Level to be used from this hierarchy on, if not given, the parent level will be used
| |
additive:Boolean (default = true) — Flat to set if the hierarchy level should merge the target
with the parent targets or not.
|