com.cysols.iodef.analysis
Class AggregatedEvent

java.lang.Object
  extended by com.cysols.iodef.analysis.AggregatedEvent
Direct Known Subclasses:
AggregatedAlertEvent, AggregatedPacketEvent

public abstract class AggregatedEvent
extends Object

This class is an abstract value object which represents an aggregated event generated by analyzing events.


Field Summary
protected  List eventList
          Used for keeping the concrete Event instances by its sub class.
 
Constructor Summary
AggregatedEvent(String sourceAddress)
          Default Constructor with Source Address, The aggregated event is generated for each source address.
 
Method Summary
 void addEvent(Event event)
          Adds an event in the aggregated event.
 long getEarliestTime()
          Returns the earliest timestamp among the aggregated events
 long getLatestTime()
          Returns the latest timestamp among the aggregated events.
 String getSrcAddress()
          Returns source address of this aggregated event.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

eventList

protected List eventList
Used for keeping the concrete Event instances by its sub class.

Constructor Detail

AggregatedEvent

public AggregatedEvent(String sourceAddress)
Default Constructor with Source Address, The aggregated event is generated for each source address.

Parameters:
sourceAddress - source address of the aggregated events
Method Detail

addEvent

public void addEvent(Event event)
Adds an event in the aggregated event. Then the earliest timestamp and the latest timestamp are updated according to the added event's timestamp.

Parameters:
event - an Event instance to be aggregated.

getSrcAddress

public String getSrcAddress()
Returns source address of this aggregated event.

Returns:
source address.

getLatestTime

public long getLatestTime()
Returns the latest timestamp among the aggregated events.

Returns:
time milliseconds.

getEarliestTime

public long getEarliestTime()
Returns the earliest timestamp among the aggregated events

Returns:
time milliseconds.