|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectthings.common.commands.CommandLogger
public class CommandLogger
Command logger. It is a wrapper around the simple Thinger logger.
Version History
EPG - Initial - 10 AUG 06
| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from interface things.thinger.io.Logger |
|---|
Logger.LEVEL, Logger.TYPE |
| Constructor Summary | |
|---|---|
CommandLogger()
|
|
| Method Summary | |
|---|---|
CommandLogger |
clone(java.lang.String tag)
Create a clone of this logger, but with a new tag. |
void |
debug(java.lang.String msg)
Log a trivial debug entry. |
void |
debug(java.lang.String msg,
int numeric)
Log a trivial error entry with a numeric. |
void |
debug(java.lang.String msg,
int numeric,
java.util.Collection<NVImmutable> attributes)
Log a complex debug entry with numerics and attributes. |
void |
debug(java.lang.String msg,
int numeric,
NVImmutable... attributes)
Log a complex debug entry with numerics and attributes. |
void |
debug(java.lang.String msg,
int numeric,
java.lang.String... attributes)
Log a complex debug entry with numerics and attributes. |
void |
debuggingOff()
Turn debugging off. |
void |
debuggingOn()
Turn debugging on. |
boolean |
debuggingState()
Get the current debugging state. |
void |
error(java.lang.String msg)
Log a trivial error entry. |
void |
error(java.lang.String msg,
int numeric)
Log a trivial error entry with a numeric. |
void |
error(java.lang.String msg,
int numeric,
java.util.Collection<NVImmutable> attributes)
Log a complex error entry with numerics and attributes. |
void |
error(java.lang.String msg,
int numeric,
NVImmutable... attributes)
Log a complex error entry with numerics and attributes. |
void |
error(java.lang.String msg,
int numeric,
java.lang.String... attributes)
Log a complex error entry with numerics and attributes. |
void |
exception(java.lang.Throwable tr)
Log an exception. |
void |
flush()
Tell the underlying system to flush any entries. |
Logger.LEVEL |
getLevel()
This will get the level of entries that will pass. |
void |
info(java.lang.String msg)
Log a trivial information entry. |
void |
info(java.lang.String msg,
int numeric)
Log a trivial information entry with a numeric. |
void |
info(java.lang.String msg,
int numeric,
java.util.Collection<NVImmutable> attributes)
Log a complex information entry with numerics and attributes. |
void |
info(java.lang.String msg,
int numeric,
NVImmutable... attributes)
Log a complex information entry with numerics and attributes. |
void |
info(java.lang.String msg,
int numeric,
java.lang.String... attributes)
Log a complex info entry with numerics and attributes. |
void |
init(Logger.TYPE loggerType)
Initialized the logger. |
void |
init(Logger logger,
java.lang.String tag,
Logger.LEVEL level)
Initialize the LoggerWriter with a Writer and a prefix ID. |
void |
init(java.io.PrintWriter out,
java.lang.String tag,
Logger.LEVEL level)
Initialize the LoggerWriter with a Writer and a prefix ID. |
void |
post(Entry e)
Post an Entry. |
void |
post(java.lang.String message)
Post as a message. |
void |
postit(java.lang.String message)
Post as a message. |
void |
setLevel(Logger.LEVEL newLevel)
This will set the level of entries that will pass. |
void |
setPostLevel(Logger.LEVEL newLevel)
This will set the default level of StringPoster posted entries. |
void |
shout(java.lang.String msg,
int numeric,
Logger.LEVEL theLevel)
Shout a log entry with numerics. |
void |
shout(java.lang.String msg,
int numeric,
Logger.LEVEL theLevel,
java.util.Collection<NVImmutable> attributes)
Shout a log entry with numerics and attributes. |
void |
shout(java.lang.String msg,
int numeric,
Logger.LEVEL theLevel,
NVImmutable... attributes)
Shout a log entry with numerics and attributes. |
void |
shout(java.lang.String msg,
int numeric,
Logger.LEVEL theLevel,
java.lang.String... attributes)
Shout a log entry with numerics and attributes. |
void |
shout(java.lang.String msg,
Logger.LEVEL theLevel)
Shout a log entry. |
void |
warning(java.lang.String msg)
Log a trivial warning entry. |
void |
warning(java.lang.String msg,
int numeric)
Log a trivial warning entry with a numeric. |
void |
warning(java.lang.String msg,
int numeric,
java.util.Collection<NVImmutable> attributes)
Log a complex warning entry with numerics and attributes. |
void |
warning(java.lang.String msg,
int numeric,
NVImmutable... attributes)
Log a complex warning entry with numerics and attributes. |
void |
warning(java.lang.String msg,
int numeric,
java.lang.String... attributes)
Log a complex warning entry with numerics and attributes. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public CommandLogger()
| Method Detail |
|---|
public void init(java.io.PrintWriter out,
java.lang.String tag,
Logger.LEVEL level)
throws SystemException
out - A writer. The implementation doesn't care what kind. If the Logger type is set as reliable, then every write will be flushed.tag - A tag for the line.level - The logging level. Note that the debug methods will override any value passed here.
SystemException
public void init(Logger logger,
java.lang.String tag,
Logger.LEVEL level)
throws SystemException
logger - A logger where to post. The implementation doesn't care what kind. If the Logger type is set as reliable, then every write will be flushed.tag - A tag for the line.level - The logging level. Note that the debug methods will override any value passed here.
SystemException
public CommandLogger clone(java.lang.String tag)
throws SystemException
tag - A tag for the line.
SystemException
public void post(java.lang.String message)
throws ThingsException
post in interface StringPostermessage - String to post
ThingsExceptionpublic void postit(java.lang.String message)
postit in interface StringPostermessage - String to postpublic void setLevel(Logger.LEVEL newLevel)
setLevel in interface LoggernewLevel - the new level.public Logger.LEVEL getLevel()
getLevel in interface Loggerpublic void setPostLevel(Logger.LEVEL newLevel)
setPostLevel in interface LoggernewLevel - the new default level.
SystemException
public void init(Logger.TYPE loggerType)
throws SystemException
init in interface LoggerloggerType - The type of logger this should be. This is more a request than a demand.
SystemExceptionpublic void debuggingOn()
debuggingOn in interface Debuggablepublic void debuggingOff()
debuggingOff in interface Debuggablepublic boolean debuggingState()
debuggingState in interface Debuggablepublic void flush()
flush in interface StringPosterflush in interface Logger
public void post(Entry e)
throws SystemException
post in interface Loggere - The entry.
SystemExceptionEntry
public void exception(java.lang.Throwable tr)
throws SystemException
exception in interface Loggertr - The Exception.
SystemException
public void error(java.lang.String msg)
throws SystemException
error in interface Loggermsg - The text message.
SystemException
public void error(java.lang.String msg,
int numeric)
throws SystemException
error in interface Loggermsg - The text message.numeric - The numeric.
SystemException
public void error(java.lang.String msg,
int numeric,
NVImmutable... attributes)
throws SystemException
error in interface Loggermsg - The text message.numeric - The numeric.attributes - Sequence of NVs representing attributes.
SystemExceptionNVImmutable
public void error(java.lang.String msg,
int numeric,
java.util.Collection<NVImmutable> attributes)
throws SystemException
error in interface Loggermsg - The text message.numeric - The numeric.attributes - Sequence of NVs representing attributes.
SystemExceptionNVImmutable
public void error(java.lang.String msg,
int numeric,
java.lang.String... attributes)
throws SystemException
error in interface Loggermsg - The text message.numeric - The numeric.attributes - Name/value pairs for attributes. Must be an even number of Strings.
SystemExceptionNV
public void warning(java.lang.String msg)
throws SystemException
warning in interface Loggermsg - The text message.
SystemException
public void warning(java.lang.String msg,
int numeric)
throws SystemException
warning in interface Loggermsg - The text message.numeric - The numeric.
SystemException
public void warning(java.lang.String msg,
int numeric,
NVImmutable... attributes)
throws SystemException
warning in interface Loggermsg - The text message.numeric - The numeric.attributes - Sequence of NVs representing attributes.
SystemExceptionNVImmutable
public void warning(java.lang.String msg,
int numeric,
java.util.Collection<NVImmutable> attributes)
throws SystemException
warning in interface Loggermsg - The text message.numeric - The numeric.attributes - Sequence of NVs representing attributes.
SystemExceptionNVImmutable
public void warning(java.lang.String msg,
int numeric,
java.lang.String... attributes)
throws SystemException
warning in interface Loggermsg - The text message.numeric - The numeric.attributes - Name/value pairs for attributes. Must be an even number of Strings.
SystemException
public void info(java.lang.String msg)
throws SystemException
info in interface Loggermsg - The text message.
SystemException
public void info(java.lang.String msg,
int numeric)
throws SystemException
info in interface Loggermsg - The text message.numeric - The numeric.
SystemException
public void info(java.lang.String msg,
int numeric,
NVImmutable... attributes)
throws SystemException
info in interface Loggermsg - The text message.numeric - The numeric.attributes - Sequence of NVs representing attributes.
SystemExceptionNVImmutable
public void info(java.lang.String msg,
int numeric,
java.util.Collection<NVImmutable> attributes)
throws SystemException
info in interface Loggermsg - The text message.numeric - The numeric.attributes - Sequence of NVs representing attributes.
SystemExceptionNVImmutable
public void info(java.lang.String msg,
int numeric,
java.lang.String... attributes)
throws SystemException
info in interface Loggermsg - The text message.numeric - The numeric.attributes - Name/value pairs for attributes. Must be an even number of Strings.
SystemException
public void debug(java.lang.String msg)
throws SystemException
debug in interface Loggermsg - The text message.
SystemException
public void debug(java.lang.String msg,
int numeric)
throws SystemException
debug in interface Loggermsg - The text message.numeric - The numeric.
SystemException
public void debug(java.lang.String msg,
int numeric,
NVImmutable... attributes)
throws SystemException
debug in interface Loggermsg - The text message.numeric - The numeric.attributes - Sequence of NVs representing attributes.
SystemExceptionNVImmutable
public void debug(java.lang.String msg,
int numeric,
java.util.Collection<NVImmutable> attributes)
throws SystemException
debug in interface Loggermsg - The text message.numeric - The numeric.attributes - Sequence of NVs representing attributes.
SystemExceptionNVImmutable
public void debug(java.lang.String msg,
int numeric,
java.lang.String... attributes)
throws SystemException
debug in interface Loggermsg - The text message.numeric - The numeric.attributes - Name/value pairs for attributes. Must be an even number of Strings.
SystemExceptionNV
public void shout(java.lang.String msg,
Logger.LEVEL theLevel)
shout in interface Loggermsg - The text message.theLevel - The level of the message.
public void shout(java.lang.String msg,
int numeric,
Logger.LEVEL theLevel)
shout in interface Loggermsg - The text message.numeric - The numeric.theLevel - The level of the message.NV
public void shout(java.lang.String msg,
int numeric,
Logger.LEVEL theLevel,
NVImmutable... attributes)
shout in interface Loggermsg - The text message.numeric - The numeric.theLevel - The level of the message.attributes - Sequence of NVs representing attributes.NVImmutable
public void shout(java.lang.String msg,
int numeric,
Logger.LEVEL theLevel,
java.util.Collection<NVImmutable> attributes)
shout in interface Loggermsg - The text message.numeric - The numeric.theLevel - The level of the message.attributes - Sequence of NVs representing attributes.NVImmutable
public void shout(java.lang.String msg,
int numeric,
Logger.LEVEL theLevel,
java.lang.String... attributes)
shout in interface Loggermsg - The text message.numeric - The numeric.theLevel - The level of the message.attributes - Name/value pairs for attributes. Must be an even number of Strings.NV
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||