All Implemented Interfaces:
Serializable, Comparable<Event>, Element, PropertyElement, SchemaMixedElement, ModelElement, Event, Property

public class EventImpl extends PropertyImpl implements Event
The default implementation of the Event interface.
Author:
Luca Frosini (ISTI - CNR)
See Also:
  • Field Details

    • what

      protected String what
      A description of what happened.
    • when

      protected Date when
      When the event occurred.
    • who

      protected String who
      Who triggered the event.
    • where

      protected String where
      Where the event occurred.
    • why

      protected String why
      The reason why the event occurred.
    • how

      protected String how
      How the event occurred.
  • Constructor Details

    • EventImpl

      public EventImpl()
      Default constructor.
  • Method Details

    • getWhat

      public String getWhat()
      Returns a description of what happened.
      Specified by:
      getWhat in interface Event
      Returns:
      The event description.
    • setWhat

      public void setWhat(String what)
      Sets the description of what happened.
      Specified by:
      setWhat in interface Event
      Parameters:
      what - The event description.
    • getWhen

      public Date getWhen()
      Returns when the event occurred.
      Specified by:
      getWhen in interface Event
      Returns:
      The date and time of the event.
    • setWhen

      public void setWhen(Date when)
      Sets when the event occurred.
      Specified by:
      setWhen in interface Event
      Parameters:
      when - The date and time of the event.
    • getWho

      public String getWho()
      Returns who triggered the event.
      Specified by:
      getWho in interface Event
      Returns:
      The identifier of the actor.
    • setWho

      public void setWho(String who)
      Sets who triggered the event.
      Specified by:
      setWho in interface Event
      Parameters:
      who - The identifier of the actor.
    • getWhere

      public String getWhere()
      Returns where the event occurred.
      Specified by:
      getWhere in interface Event
      Returns:
      The location (physical or virtual).
    • setWhere

      public void setWhere(String where)
      Sets where the event occurred.
      Specified by:
      setWhere in interface Event
      Parameters:
      where - The location.
    • getWhy

      public String getWhy()
      Returns the reason why the event occurred.
      Specified by:
      getWhy in interface Event
      Returns:
      The reason.
    • setWhy

      public void setWhy(String why)
      Sets the reason why the event occurred.
      Specified by:
      setWhy in interface Event
      Parameters:
      why - The reason.
    • getHow

      public String getHow()
      Returns how the event occurred.
      Specified by:
      getHow in interface Event
      Returns:
      The manner in which the event occurred.
    • setHow

      public void setHow(String how)
      Sets how the event occurred.
      Specified by:
      setHow in interface Event
      Parameters:
      how - The manner in which the event occurred.
    • compareTo

      public int compareTo(Event o)
      Specified by:
      compareTo in interface Comparable<Event>
    • hashCode

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

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