kaos.core.util
Class SimpleLogger
java.lang.Object
kaos.core.util.Logger
kaos.core.util.SimpleLogger
- All Implemented Interfaces:
- java.io.Serializable
public class SimpleLogger
- extends Logger
- See Also:
- Serialized Form
Constructor Summary |
SimpleLogger(java.lang.Object requestor)
|
Method Summary |
static int |
getDestination()
getDestination
Get the current destination. |
static int |
getLevel()
getLevel
Get the current message level. |
boolean |
isEnabledFor(int level)
|
void |
logMessage(java.lang.String message,
int level)
|
void |
logMessage(java.lang.String message,
java.lang.Throwable t,
int level)
|
static void |
setDestination(int destination)
setDestination
Set the output object; used by customers, also when object is null (as after an agent moves). |
static void |
setLevel(int newLevel)
setLevel
Get the current message level. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
OUTPUT_STDOUT
public static final int OUTPUT_STDOUT
- See Also:
- Constant Field Values
OUTPUT_STDERR
public static final int OUTPUT_STDERR
- See Also:
- Constant Field Values
SimpleLogger
public SimpleLogger(java.lang.Object requestor)
isEnabledFor
public boolean isEnabledFor(int level)
- Specified by:
isEnabledFor
in class Logger
logMessage
public void logMessage(java.lang.String message,
int level)
- Specified by:
logMessage
in class Logger
logMessage
public void logMessage(java.lang.String message,
java.lang.Throwable t,
int level)
- Specified by:
logMessage
in class Logger
getDestination
public static int getDestination()
- getDestination
Get the current destination.
- Parameters:
(none)
-
getLevel
public static int getLevel()
- getLevel
Get the current message level.
- Parameters:
(none)
-
setLevel
public static void setLevel(int newLevel)
- setLevel
Get the current message level.
- Parameters:
Integer
- 'newLevel'; use Logger.LEVEL_GENERAL, LEVEL_MAJOR, LEVEL_CAPTAIN, or LEVEL_PRIVATE.
setDestination
public static void setDestination(int destination)
- setDestination
Set the output object; used by customers, also when object is null (as after an agent moves).
- Parameters:
Integer
- 'desitination'; should be either Logger.OUTPUT_STDOUT or Logger.OUTPUT_STDERR