Class HippoEvent<E extends HippoEvent<E>>

  • All Implemented Interfaces:
    Cloneable
    Direct Known Subclasses:
    HippoSecurityEvent

    public class HippoEvent<E extends HippoEvent<E>>
    extends Object
    implements Cloneable
    Event for Hippo. A bag of properties with a number of pre-defined keys. Can be used in a fluent style to build; sub-classes are encouraged to follow the same pattern. The event can be sealed when no further changes need to be made. It is immutable after sealing, so it is safe to access concurrently.

    When creating a subclass, it is possible to keep the fluent style by extending as public class MyEvent<E extends MyEvent> extends HippoEvent<E> { } Note that subclasses should not introduce any fields of their own.

    • Constructor Detail

      • HippoEvent

        public HippoEvent​(String application)
      • HippoEvent

        public HippoEvent​(HippoEvent<?> event)
        Copy constructor
        Parameters:
        event - the to-be-copied event
    • Method Detail

      • sealEvent

        public void sealEvent()
      • isSealed

        public boolean isSealed()
      • application

        public E application​(String application)
      • application

        public String application()
      • user

        public E user​(String user)
      • action

        public E action​(String action)
      • action

        public String action()
      • category

        public E category​(String category)
      • category

        public String category()
      • timestamp

        public E timestamp​(long timestamp)
      • timestamp

        public long timestamp()
      • result

        public E result​(String result)
      • result

        public String result()
      • message

        public E message​(String message)
      • message

        public String message()
      • system

        public E system​(Boolean system)
      • get

        public <T> T get​(String key)
      • clone

        public E clone()
        Overrides:
        clone in class Object