Class ChangeEventSeed

java.lang.Object
com.sodius.oslc.server.trs.model.ChangeEventSeed

public class ChangeEventSeed extends Object
An ordered ResourceEvent which can be used to create ChangeEvents.
Since:
1.10.0
  • Method Details

    • of

      public static ChangeEventSeed of(ResourceEvent resourceEvent, long order)
      Constructs an instance specifying the underlying resource event and order.
      Parameters:
      resourceEvent - the underlying resource event.
      order - the underlying order.
      Returns:
      the corresponding change event seed
      Since:
      4.0.0
    • getResourceEvent

      public ResourceEvent getResourceEvent()
      Gets the resource event.
      Returns:
      the resource event.
    • getOrder

      public long getOrder()
      Gets the event order.
      Returns:
      event order.
      Since:
      4.0.0
    • asChangeEvent

      public ChangeEvent asChangeEvent(Function<ResourceSeed,URI> seedsUriFunction)
      Convenient method to create a ChangeEvent from this instance. This method encodes the event time in the fragment of the about property.
      Parameters:
      seedsUriFunction - a function solving the URI of a resource seed.
      Returns:
      the corresponding change event.
    • hashCode

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

      public boolean equals(Object obj)
      Overrides:
      equals in class Object