public class UnitComponent extends Unit implements LoggerSimple
Unit and exposes the logging methods. See Unit for details. It implements LoggerSimple.
This allows a class to use the functionality of a Unit without extending Unit.
net.xqhs.util.config.Config.ConfigLockedExceptionLoggerSimple.LevelDEFAULT_LEVEL, DEFAULT_UNIT_NAME, display, ensureNew, level, linkData, log, loggerWrapperClass, loggerWrapperType, logName, reporter, unitNameARGUMENT_BEGIN, ARGUMENT_END, ARGUMENT_PLACEHOLDER| Constructor and Description |
|---|
UnitComponent() |
| Modifier and Type | Method and Description |
|---|---|
void |
dbg(Debug.DebugItem debug,
java.lang.String message,
java.lang.Object... arguments)
This method displays a log message (with the level
TRACE) only if the specified Debug.DebugItem is
activated. |
void |
doExit()
Instructs the Unit to exit.
|
java.lang.String |
getUnitName()
This method is only accessible inside the instance, except if for good reasons an extending class makes it
public.
|
void |
le(java.lang.String message,
java.lang.Object... arguments)
Post an error message.
|
void |
lf(java.lang.String message,
java.lang.Object... arguments)
Post a tracing message.
|
void |
li(java.lang.String message,
java.lang.Object... arguments)
Post an informative message.
|
java.lang.Object |
lr(java.lang.Object ret)
This method should be used in return statements.
|
java.lang.Object |
lr(java.lang.Object ret,
java.lang.String message,
java.lang.Object... arguments)
This method should be used in return statements.
|
void |
lw(java.lang.String message,
java.lang.Object... arguments)
Post a warning message.
|
compose, getDefaultUnitName, l, lock, lockedR, setLink, setLink, setLogDisplay, setLogEnsureNew, setLoggerClass, setLoggerType, setLoggerTypeClass, setLogLevel, setLogReporter, setUnitName, setUnitNamepublic void le(java.lang.String message,
java.lang.Object... arguments)
UnitLoggerSimple.le in interface LoggerSimplele in class Unitmessage - : the message to displayarguments - : arguments to insert into the message. See LoggerSimple.public void lw(java.lang.String message,
java.lang.Object... arguments)
UnitLoggerSimple.lw in interface LoggerSimplelw in class Unitmessage - : the message to displayarguments - : arguments to insert into the message. See LoggerSimple.public void li(java.lang.String message,
java.lang.Object... arguments)
UnitLoggerSimple.li in interface LoggerSimpleli in class Unitmessage - : the message to displayarguments - : arguments to insert into the message. See LoggerSimple.public void lf(java.lang.String message,
java.lang.Object... arguments)
UnitLoggerSimple.lf in interface LoggerSimplelf in class Unitmessage - : the message to displayarguments - : arguments to insert into the message. See LoggerSimple.public java.lang.Object lr(java.lang.Object ret)
UnitObject
in the argument, displaying the Object. See LoggerSimple.lr in interface LoggerSimplelr in class Unitret - : the Object to return.Object passed as argument.public java.lang.Object lr(java.lang.Object ret,
java.lang.String message,
java.lang.Object... arguments)
UnitObject
in the argument. See LoggerSimple.
The Object in the argument is also put in the log message.
lr in interface LoggerSimplelr in class Unitret - : the Object to return and to display.message - : the message to display beside the Object.arguments - : arguments to insert into the message. See LoggerSimple.Object passed as argument.public void dbg(Debug.DebugItem debug, java.lang.String message, java.lang.Object... arguments)
UnitTRACE) only if the specified Debug.DebugItem is
activated. See LoggerSimple.dbg in interface LoggerSimpledbg in class Unitdebug - : the Debug.DebugItemmessage - : the log messagearguments - : arguments to insert into the message. See LoggerSimple.public void doExit()
UnitAs the Unit layer only manages logging, the only thing that happens is that the log exits (if any).
public java.lang.String getUnitName()
UnitgetUnitName in class UnitUnit name, as given to or set in the constructor.