|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.jwall.web.audit.AuditEventProcessorPipeline
public class AuditEventProcessorPipeline
This singleton class encapsulates a global, static queue of event processor instances. The processors can be registered using a priority, affecting their execution order in the queue.
For each incoming event, this queue is processed before the event is stored within the event storage.
In addition to the processors, this queue also provides a place for registering event-listeners. These are notified after all processors have been applied to the event.
| Nested Class Summary | |
|---|---|
class |
AuditEventProcessorPipeline.Priority
|
| Field Summary | |
|---|---|
static Double |
DEFAULT_PRIORITY
|
| Constructor Summary | |
|---|---|
AuditEventProcessorPipeline()
|
|
| Method Summary | |
|---|---|
List<EventListener<AuditEvent>> |
getListeners()
|
Double |
getPriority(EventProcessor<AuditEvent> proc)
|
List<EventProcessor<AuditEvent>> |
getProcessors()
|
void |
logInfo()
|
void |
process(AuditEvent event)
|
AuditEvent |
processEvent(AuditEvent event)
This method applies all registered processors to the specified event. |
void |
register(Double priority,
EventProcessor<AuditEvent> proc)
Register a new event processor in this pipeline. |
void |
registerListener(EventListener<AuditEvent> l)
|
void |
unregister(EventProcessor<AuditEvent> proc)
Unregister the given processor from this pipeline. |
void |
unregisterEventProcessor(EventProcessor<AuditEvent> p)
This method is used to unregister an event-processor from the AuditStorage |
void |
unregisterListener(EventListener<AuditEvent> l)
|
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final Double DEFAULT_PRIORITY
| Constructor Detail |
|---|
public AuditEventProcessorPipeline()
| Method Detail |
|---|
public AuditEvent processEvent(AuditEvent event)
throws EventProcessorException
event -
EventProcessorExceptionpublic void unregisterEventProcessor(EventProcessor<AuditEvent> p)
p - public void unregisterListener(EventListener<AuditEvent> l)
public void registerListener(EventListener<AuditEvent> l)
public void logInfo()
public void process(AuditEvent event)
throws EventProcessorException
process in interface EventProcessorPipeline<AuditEvent>EventProcessorExceptionorg.jwall.web.audit.console.event.EventProcessorPipeline#process(org.jwall.audit.Event)public List<EventProcessor<AuditEvent>> getProcessors()
public List<EventListener<AuditEvent>> getListeners()
public void unregister(EventProcessor<AuditEvent> proc)
EventProcessorPipeline
unregister in interface EventProcessorPipeline<AuditEvent>proc - The processor to remove from the pipeline.org.jwall.web.audit.console.event.EventProcessorPipeline#unregister(org.jwall.audit.EventProcessor)
public void register(Double priority,
EventProcessor<AuditEvent> proc)
EventProcessorPipeline
register in interface EventProcessorPipeline<AuditEvent>priority - The priority with which this processor is inserted into the pipeline.proc - The new processor to be added to the pipeline.org.jwall.web.audit.console.event.EventProcessorPipeline#register(java.lang.Double, org.jwall.audit.EventProcessor)public Double getPriority(EventProcessor<AuditEvent> proc)
getPriority in interface EventProcessorPipeline<AuditEvent>
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||