Class WrapperOf<T>

java.lang.Object
org.oddjob.events.WrapperOf<T>
Type Parameters:
T - The type the event is of.
All Implemented Interfaces:
InstantEvent<T>

public class WrapperOf<T> extends Object implements InstantEvent<T>
An event of something create by wrapping it.
  • Constructor Details

    • WrapperOf

      public WrapperOf(T event, Date date)
    • WrapperOf

      public WrapperOf(T event, Instant time)
  • Method Details

    • getOf

      public T getOf()
      Description copied from interface: InstantEvent
      Get the underlying event or trigger. Will not be null.
      Specified by:
      getOf in interface InstantEvent<T>
      Returns:
      The event/trigger.
    • getTime

      public Instant getTime()
      Description copied from interface: InstantEvent
      Get the UTC time of the event.
      Specified by:
      getTime in interface InstantEvent<T>
      Returns:
      The time.
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • toString

      public String toString()
      Overrides:
      toString in class Object