Methods Summary |
---|
public int | getDebug()Return the debugging detail level for this component.
// ------------------------------------------------------------- Properties
return (this.debug);
|
public void | lifecycleEvent(org.apache.catalina.LifecycleEvent event)Process the START event for an associated Engine.
// Identify the engine we are associated with
try {
engine = (Engine) event.getLifecycle();
if (engine instanceof StandardEngine) {
int engineDebug = ((StandardEngine) engine).getDebug();
if (engineDebug > this.debug)
this.debug = engineDebug;
}
} catch (ClassCastException e) {
log(sm.getString("engineConfig.cce", event.getLifecycle()), e);
return;
}
// Process the event that has occurred
if (event.getType().equals(Lifecycle.START_EVENT))
start();
else if (event.getType().equals(Lifecycle.STOP_EVENT))
stop();
|
private void | log(java.lang.String message)Log a message on the Logger associated with our Engine (if any)
Logger logger = null;
if (engine != null)
logger = engine.getLogger();
if (logger != null)
logger.log("EngineConfig: " + message);
else
System.out.println("EngineConfig: " + message);
|
private void | log(java.lang.String message, java.lang.Throwable throwable)Log a message on the Logger associated with our Engine (if any)
Logger logger = null;
if (engine != null)
logger = engine.getLogger();
if (logger != null)
logger.log("EngineConfig: " + message, throwable);
else {
System.out.println("EngineConfig: " + message);
System.out.println("" + throwable);
throwable.printStackTrace(System.out);
}
|
public void | setDebug(int debug)Set the debugging detail level for this component.
this.debug = debug;
|
private void | start()Process a "start" event for this Engine.
if (debug > 0)
log(sm.getString("engineConfig.start"));
|
private void | stop()Process a "stop" event for this Engine.
if (debug > 0)
log(sm.getString("engineConfig.stop"));
|