Package org.onosproject.event
Class AbstractEvent<T extends Enum,S>
- java.lang.Object
-
- org.onosproject.event.AbstractEvent<T,S>
-
- All Implemented Interfaces:
Event<T,S>
- Direct Known Subclasses:
AlarmEvent,ApplicationEvent,ClusterEvent,ClusterMetadataEvent,ComponentConfigEvent,ControlMessageEvent,DeviceAgentEvent,DeviceEvent,DeviceKeyEvent,DriverEvent,EdgePortEvent,FlowRuleBatchEvent,FlowRuleEvent,GroupEvent,HostEvent,HostProbingEvent,IntentEvent,InterfaceEvent,LeadershipEvent,LinkEvent,MastershipEvent,McastEvent,MeterEvent,NetworkConfigEvent,ObjectiveEvent,PacketEvent,PartitionEvent,PiPipeconfDeviceMappingEvent,PiPipeconfEvent,PiPipeconfWatchdogEvent,PiTranslationEvent,RegionEvent,ReplicaInfoEvent,ResourceEvent,TopologyEvent,UiModelEvent,UpgradeEvent,WorkPartitionEvent
public class AbstractEvent<T extends Enum,S> extends Object implements Event<T,S>
Base event implementation.
-
-
Constructor Summary
Constructors Modifier Constructor Description protectedAbstractEvent(T type, S subject)Creates an event of a given type and for the specified subject and the current time.protectedAbstractEvent(T type, S subject, long time)Creates an event of a given type and for the specified subject and time.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Ssubject()Returns the subject of the event.longtime()Returns the timestamp of when the event occurred, given in milliseconds since the start of epoch.StringtoString()Ttype()Returns the type of the event.
-
-
-
Method Detail
-
time
public long time()
Description copied from interface:EventReturns the timestamp of when the event occurred, given in milliseconds since the start of epoch.
-
subject
public S subject()
Description copied from interface:EventReturns the subject of the event.
-
-