Class Event

Object
Event
All Implemented Interfaces:
Serializable, Ownage

@Entity public class Event extends Object implements Serializable, Ownage
An event, defined to execute at a certain time. The time can be defined in the following fields:
  • month
  • dayofmonth
  • dayofweek
  • hour
  • minute
Author:
maartenl
See Also:
  • Constructor Details

  • Method Details

    • getEventid

      public Integer getEventid()
    • setEventid

      public void setEventid(Integer eventid)
    • getPerson

      public Person getPerson()
    • setPerson

      public void setPerson(Person person)
    • getMonth

      public Integer getMonth()
      Returns the month in which this event should be run. Be warned JANUARY is month 0, the first month. December is month 11, the last month. If it returns null, it means every month is matched.
      Returns:
      integer
    • setMonth

      public void setMonth(Integer month)
    • getDayofmonth

      public Integer getDayofmonth()
      Returns the day of the month, starting with 1. If it returns null, it means every day of the month is matched.
      Returns:
      integer
    • setDayofmonth

      public void setDayofmonth(Integer dayofmonth)
    • getHour

      public Integer getHour()
      Returns the hour in which this event should be run. It's a 24 hour clock used here. First hour right after midnight is 0. If it returns null, it means every hour is matched.
      Returns:
      integer
    • setHour

      public void setHour(Integer hour)
    • getMinute

      public Integer getMinute()
      Returns the minute in which this event should be run. Any value between 0 and 59 would be okay. If it returns null, it means every minute is matched.
      Returns:
      integer
    • setMinute

      public void setMinute(Integer minute)
    • getDayofweek

      public Integer getDayofweek()
      Returns the day of the week at which this event should be run. SUNDAY being 1 and SATURDAY being 7. If it returns null, it means every day of the week is matched.
      Returns:
      integer
    • setDayofweek

      public void setDayofweek(Integer dayofweek)
    • getCallable

      public boolean getCallable()
      Returns if this event is 'active'.
      Returns:
      boolean, true if active, false otherwise.
    • setCallable

      public void setCallable(Boolean callable)
    • getRoom

      public Room getRoom()
    • setRoom

      public void setRoom(Room room)
    • getCreation

      public LocalDateTime getCreation()
    • setCreation

      public void setCreation(LocalDateTime creation)
    • getOwner

      public Admin getOwner()
      Description copied from interface: Ownage
      Retrieves the owner, the administrator, of this object. In case this is null, anyone can edit the object.
      Specified by:
      getOwner in interface Ownage
      Returns:
    • setOwner

      public void setOwner(Admin owner)
      Description copied from interface: Ownage
      Sets the owner, the administrator, of this object.
      Specified by:
      setOwner in interface Ownage
      Parameters:
      owner - the owner/administrator of the object. In case this is null, which is allowed, any administrator can edit this object. This is what happens when an object is "disowned".
    • getMethod

      public Method getMethod()
    • setMethod

      public void setMethod(Method method)
    • hashCode

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

      public boolean equals(Object object)
      Overrides:
      equals in class Object
    • toString

      public String toString()
      Overrides:
      toString in class Object