Class EventSchedule

java.lang.Object
com.example.skeddly.business.event.EventSchedule

public class EventSchedule extends Object
This class represents the schedule of an event with a start and end time + reg start/end times
  • Constructor Details

    • EventSchedule

      public EventSchedule()
      No arg Constructor for the EventSchedule. Required by Firestore.
    • EventSchedule

      public EventSchedule(LocalDateTime start, LocalDateTime end, LocalDateTime regStart, LocalDateTime regEnd, Boolean[] daysOfWeek)
      Constructor for the EventSchedule
      Parameters:
      start - The start time of the event
      end - The end time of the event
      daysOfWeek - The days of the week the event occurs on
    • EventSchedule

      public EventSchedule(LocalDateTime start, LocalDateTime end, LocalDateTime regStart, LocalDateTime regEnd)
      Constructor for the EventSchedule without days of week
      Parameters:
      start - The start time of the event
      end - The end time of the event
  • Method Details

    • getStartTime

      public long getStartTime()
      Gets the start time of the event
      Returns:
      The start time of the event
    • setStartTime

      public void setStartTime(long startTime)
      Sets the start time of the event
      Parameters:
      startTime - The start time of the event
    • getEndTime

      public long getEndTime()
      Gets the end time of the event
      Returns:
      The end time of the event
    • setEndTime

      public void setEndTime(long endTime)
      Sets the end time of the event
      Parameters:
      endTime - The end time of the event
    • getRegStart

      public long getRegStart()
      Gets the start of the registration period.
      Returns:
      A unix epoch representing the start of the registration period.
    • setRegStart

      public void setRegStart(long regStart)
      Sets the start of the registration period.
      Parameters:
      regStart - A unix epoch representing the start of the registration period.
    • getRegEnd

      public long getRegEnd()
      Gets the end of the registration period.
      Returns:
      A unix epoch representing the end of the registration period.
    • setRegEnd

      public void setRegEnd(long regEnd)
      Sets the end of the registration period.
      Parameters:
      regEnd - A unix epoch representing the end of the registration period.
    • isRegistrationOver

      public boolean isRegistrationOver()
      Gets whether the event registration period has ended or not.
      Returns:
      True if it has ended. False otherwise.
    • getDaysOfWeek

      public List<Boolean> getDaysOfWeek()
      Gets the days of the week the event occurs on
      Returns:
      The days of the week the event occurs on
    • setDaysOfWeek

      public void setDaysOfWeek(List<Boolean> daysOfWeek)
      Sets the days of the week the event occurs on
      Parameters:
      daysOfWeek - The days of the week the event occurs on
    • isRecurring

      public boolean isRecurring()
      Returns if the event is recurring
      Returns:
      If the event is recurring
    • setRecurring

      public void setRecurring(boolean recurring)
      Sets if the event is recurring
      Parameters:
      recurring - If the event is recurring