@Deprecated public class ConsoleLogger extends java.lang.Object implements LogReaderService
| Modifier and Type | Class and Description |
|---|---|
class |
ConsoleLogger.Facade
Deprecated.
|
static class |
ConsoleLogger.LogEntryImpl
Deprecated.
|
| Modifier and Type | Field and Description |
|---|---|
java.util.List<LogEntry> |
entries
Deprecated.
|
java.util.List<ConsoleLogger.Facade> |
facades
Deprecated.
|
java.util.List<LogListener> |
logListeners
Deprecated.
|
java.io.PrintStream |
logToConsole
Deprecated.
|
static java.util.concurrent.atomic.AtomicLong |
timer
Deprecated.
|
| Constructor and Description |
|---|
ConsoleLogger(BundleContext context)
Deprecated.
|
| Modifier and Type | Method and Description |
|---|---|
void |
addLogListener(LogListener listener)
Deprecated.
Subscribes to
LogEntry objects. |
void |
close()
Deprecated.
|
java.util.Enumeration |
getLog()
Deprecated.
Returns an
Enumeration of all LogEntry objects in the
log. |
void |
removeLogListener(LogListener listener)
Deprecated.
Unsubscribes to
LogEntry objects. |
public java.util.List<LogEntry> entries
public java.util.List<ConsoleLogger.Facade> facades
public java.util.List<LogListener> logListeners
public static java.util.concurrent.atomic.AtomicLong timer
public java.io.PrintStream logToConsole
public ConsoleLogger(BundleContext context)
public void addLogListener(LogListener listener)
LogReaderServiceLogEntry objects.
This method registers a LogListener object with the Log Reader
Service. The LogListener.logged(LogEntry) method will be called
for each LogEntry object placed into the log.
When a bundle which registers a LogListener object is stopped or
otherwise releases the Log Reader Service, the Log Reader Service must
remove all of the bundle's listeners.
If this Log Reader Service's list of listeners already contains a
listener l such that (l==listener), this method does
nothing.
addLogListener in interface LogReaderServicelistener - A LogListener object to register; the
LogListener object is used to receive LogEntry
objects.LogListener,
LogEntry,
LogListener.logged(LogEntry)public void removeLogListener(LogListener listener)
LogReaderServiceLogEntry objects.
This method unregisters a LogListener object from the Log Reader
Service.
If listener is not contained in this Log Reader Service's list of
listeners, this method does nothing.
removeLogListener in interface LogReaderServicelistener - A LogListener object to unregister.LogListenerpublic java.util.Enumeration getLog()
LogReaderServiceEnumeration of all LogEntry objects in the
log.
Each element of the enumeration is a LogEntry object, ordered
with the most recent entry first. Whether the enumeration is of all
LogEntry objects since the Log Service was started or some recent
past is implementation-specific. Also implementation-specific is whether
informational and debug LogEntry objects are included in the
enumeration.
getLog in interface LogReaderServiceEnumeration of all LogEntry objects in the
log.public void close()
Copyright (c) aQute SARL (2000, 2019) and others. All Rights Reserved.