Class SystemWideAlert

java.lang.Object
org.dspace.alerts.SystemWideAlert
All Implemented Interfaces:
ReloadableEntity<Integer>

@Entity public class SystemWideAlert extends Object implements ReloadableEntity<Integer>
Database object representing system-wide alerts
  • Constructor Summary

    Constructors
    Modifier
    Constructor
    Description
    protected
     
  • Method Summary

    Modifier and Type
    Method
    Description
    boolean
    equals(Object other)
    Return true if other is the same SystemWideAlert as this object, false otherwise
    Retrieve what kind of sessions are allowed while the system-wide alert is active
    Retrieve the date to which will be count down when the system-wide alert is active
    This method returns the ID that the system-wide alert holds within the database
    Retrieve the message of the system-wide alert
    int
     
    boolean
    Retrieve whether the system-wide alert is active
    void
    setActive(boolean active)
    Set whether the system-wide alert is active
    void
    Set what kind of sessions are allowed while the system-wide alert is active
    void
    setCountdownTo(Date countdownTo)
    Set the date to which will be count down when the system-wide alert is active
    void
    setID(Integer alertID)
    Set the ID for the system-wide alert
    void
    setMessage(String message)
    Set the message of the system-wide alert

    Methods inherited from class java.lang.Object

    clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • SystemWideAlert

      protected SystemWideAlert()
  • Method Details

    • getID

      public Integer getID()
      This method returns the ID that the system-wide alert holds within the database
      Specified by:
      getID in interface ReloadableEntity<Integer>
      Returns:
      The ID that the system-wide alert holds within the database
    • setID

      public void setID(Integer alertID)
      Set the ID for the system-wide alert
      Parameters:
      alertID - The ID to set
    • getMessage

      public String getMessage()
      Retrieve the message of the system-wide alert
      Returns:
      the message of the system-wide alert
    • setMessage

      public void setMessage(String message)
      Set the message of the system-wide alert
      Parameters:
      message - The message to set
    • getAllowSessions

      public AllowSessionsEnum getAllowSessions()
      Retrieve what kind of sessions are allowed while the system-wide alert is active
      Returns:
      what kind of sessions are allowed while the system-wide alert is active
    • setAllowSessions

      public void setAllowSessions(AllowSessionsEnum allowSessions)
      Set what kind of sessions are allowed while the system-wide alert is active
      Parameters:
      allowSessions - Integer representing what kind of sessions are allowed
    • getCountdownTo

      public Date getCountdownTo()
      Retrieve the date to which will be count down when the system-wide alert is active
      Returns:
      the date to which will be count down when the system-wide alert is active
    • setCountdownTo

      public void setCountdownTo(Date countdownTo)
      Set the date to which will be count down when the system-wide alert is active
      Parameters:
      countdownTo - The date to which will be count down
    • isActive

      public boolean isActive()
      Retrieve whether the system-wide alert is active
      Returns:
      whether the system-wide alert is active
    • setActive

      public void setActive(boolean active)
      Set whether the system-wide alert is active
      Parameters:
      active - Whether the system-wide alert is active
    • equals

      public boolean equals(Object other)
      Return true if other is the same SystemWideAlert as this object, false otherwise
      Overrides:
      equals in class Object
      Parameters:
      other - object to compare to
      Returns:
      true if object passed in represents the same system-wide alert as this object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object