|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.oddjob.logging.cache.PollingLogArchiver
public class PollingLogArchiver
A LogArchiver which maintains it's log archives by polling.
This archiver will remove a component from it's list of components to poll when no more listeners are listening to it.
This archiver will only poll the first component where many components share the same archive.
Field Summary |
---|
Fields inherited from interface org.oddjob.logging.LogArchiver |
---|
MAX_HISTORY, NO_LOG_AVAILABLE |
Constructor Summary | |
---|---|
PollingLogArchiver(ArchiveNameResolver resolver,
LogEventSource source)
Constructor with default history. |
|
PollingLogArchiver(int history,
ArchiveNameResolver resolver,
LogEventSource source)
Constructor that accepts a history count. |
Method Summary | |
---|---|
void |
addLogListener(LogListener l,
Object component,
LogLevel level,
long last,
int max)
Add a LogListener for the given component. |
void |
onDestroy()
|
void |
poll()
Poll for Log Messages. |
void |
removeLogListener(LogListener l,
Object component)
Remove the LogListener for the given component. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public PollingLogArchiver(ArchiveNameResolver resolver, LogEventSource source)
public PollingLogArchiver(int history, ArchiveNameResolver resolver, LogEventSource source)
Method Detail |
---|
public void addLogListener(LogListener l, Object component, LogLevel level, long last, int max)
addLogListener
in interface LogArchiver
l
- The LogListener.component
- The component.level
- The level.last
- The last message number required.max
- The maximum history.public void removeLogListener(LogListener l, Object component)
removeLogListener
in interface LogArchiver
l
- The LogListener.component
- The component.public void poll()
public void onDestroy()
|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |