|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectorg.apache.velocity.runtime.log.SystemLogChute
Logger used when no other is configured. By default, all messages will be printed to the System.err output stream.
| Field Summary | |
static String |
RUNTIME_LOG_LEVEL_KEY
|
static String |
RUNTIME_LOG_SYSTEM_ERR_LEVEL_KEY
|
| Fields inherited from interface org.apache.velocity.runtime.log.LogChute |
DEBUG_ID, DEBUG_PREFIX, ERROR_ID, ERROR_PREFIX, INFO_ID, INFO_PREFIX, TRACE_ID, TRACE_PREFIX, WARN_ID, WARN_PREFIX |
| Constructor Summary | |
SystemLogChute()
|
|
| Method Summary | |
int |
getEnabledLevel()
Returns the current minimum level at which messages will be printed. |
protected String |
getPrefix(int level)
|
int |
getSystemErrLevel()
Returns the current minimum level at which messages will be printed to System.err instead of System.out. |
void |
init(RuntimeServices rs)
Initializes this LogChute. |
boolean |
isLevelEnabled(int level)
This will return true if the specified level is equal to or higher than the level this LogChute is enabled for. |
void |
log(int level,
String message)
Logs messages to either std.out or std.err depending on their severity. |
void |
log(int level,
String message,
Throwable t)
Logs messages to the system console so long as the specified level is equal to or greater than the level this LogChute is enabled for. |
void |
setEnabledLevel(int level)
Set the minimum level at which messages will be printed. |
void |
setSystemErrLevel(int level)
Set the minimum level at which messages will be printed to System.err instead of System.out. |
protected int |
toLevel(String level)
|
protected void |
write(PrintStream stream,
String prefix,
String message,
Throwable t)
|
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
public static final String RUNTIME_LOG_LEVEL_KEY
public static final String RUNTIME_LOG_SYSTEM_ERR_LEVEL_KEY
| Constructor Detail |
public SystemLogChute()
| Method Detail |
public void init(RuntimeServices rs)
throws Exception
LogChute
init in interface LogChuters -
Exceptionprotected int toLevel(String level)
protected String getPrefix(int level)
public void log(int level,
String message)
log in interface LogChutelevel - severity levelmessage - complete error message
public void log(int level,
String message,
Throwable t)
log in interface LogChutelevel - severity levelmessage - complete error messaget - the java.lang.Throwable
protected void write(PrintStream stream,
String prefix,
String message,
Throwable t)
public void setEnabledLevel(int level)
public int getEnabledLevel()
public void setSystemErrLevel(int level)
public int getSystemErrLevel()
public boolean isLevelEnabled(int level)
isLevelEnabled in interface LogChutelevel -
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||