Class TimeSlot

  • All Implemented Interfaces:
    java.io.Serializable

    public final class TimeSlot
    extends java.lang.Object
    implements java.io.Serializable
    Business class of the time slot
    Author:
    Laurent Payen
    See Also:
    Serialized Form
    • Constructor Summary

      Constructors 
      Constructor Description
      TimeSlot()  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      java.time.LocalDateTime getEndingDateTime()  
      java.time.LocalTime getEndingTime()
      Get the ending time of the time slot
      java.sql.Time getEndingTimeSqlTime()
      Get the ending time in sql time
      int getIdTimeSlot()
      Get the id of the time slot
      int getIdWorkingDay()
      Get the working day id the time slot belongs to
      boolean getIsOpen()
      Indicate whether the time slot is open or not
      int getMaxCapacity()
      Get the maximum capacity of the slot
      java.time.LocalDateTime getStartingDateTime()  
      java.time.LocalTime getStartingTime()
      Get the starting time of the time slot
      java.sql.Time getStartingTimeSqlTime()
      Get the starting time of the time slot (in sql time)
      void setEndingDateTime​(java.time.LocalDateTime endingDateTime)  
      void setEndingTime​(java.time.LocalTime endingTime)
      Set the ending time of the time slot
      void setIdTimeSlot​(int nIdTimeSlot)
      Set the id of the time slot
      void setIdWorkingDay​(int nIdWorkingDay)
      Set the working day id the time slot belongs to
      void setIsOpen​(boolean bIsOpen)
      Set the opening boolean value of the time slot
      void setMaxCapacity​(int nMaxCapacity)
      Set the maximum capacity of the slot
      void setSqlEndingTime​(java.sql.Time endingTime)
      Set the ending time of the time slot
      void setSqlStartingTime​(java.sql.Time startingTime)
      Set the starting time of the time slot
      void setStartingDateTime​(java.time.LocalDateTime startingDateTime)  
      void setStartingTime​(java.time.LocalTime startingTime)
      Set the starting time of the time slot
      • Methods inherited from class java.lang.Object

        equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • TimeSlot

        public TimeSlot()
    • Method Detail

      • getIdTimeSlot

        public int getIdTimeSlot()
        Get the id of the time slot
        Returns:
      • setIdTimeSlot

        public void setIdTimeSlot​(int nIdTimeSlot)
        Set the id of the time slot
        Parameters:
        nIdTimeSlot - the id to set
      • getStartingTime

        public java.time.LocalTime getStartingTime()
        Get the starting time of the time slot
        Returns:
        the starting time of the time slot
      • getStartingTimeSqlTime

        public java.sql.Time getStartingTimeSqlTime()
        Get the starting time of the time slot (in sql time)
        Returns:
        the starting time
      • setStartingTime

        public void setStartingTime​(java.time.LocalTime startingTime)
        Set the starting time of the time slot
        Parameters:
        startingTime - the starting time to set
      • setSqlStartingTime

        public void setSqlStartingTime​(java.sql.Time startingTime)
        Set the starting time of the time slot
        Parameters:
        startingTime - the starting time (in sql time)
      • getEndingTime

        public java.time.LocalTime getEndingTime()
        Get the ending time of the time slot
        Returns:
        the ending time of the time slot
      • getEndingTimeSqlTime

        public java.sql.Time getEndingTimeSqlTime()
        Get the ending time in sql time
        Returns:
        the ending time in sql time
      • setEndingTime

        public void setEndingTime​(java.time.LocalTime endingTime)
        Set the ending time of the time slot
        Parameters:
        endingTime - the ending time to set
      • setSqlEndingTime

        public void setSqlEndingTime​(java.sql.Time endingTime)
        Set the ending time of the time slot
        Parameters:
        endingTime - the ending time (in sql time format)
      • getIsOpen

        public boolean getIsOpen()
        Indicate whether the time slot is open or not
        Returns:
        true if the time slot is open
      • setIsOpen

        public void setIsOpen​(boolean bIsOpen)
        Set the opening boolean value of the time slot
        Parameters:
        bIsOpen - the opening boolean value
      • getMaxCapacity

        public int getMaxCapacity()
        Get the maximum capacity of the slot
        Returns:
        the maximum capacity
      • setMaxCapacity

        public void setMaxCapacity​(int nMaxCapacity)
        Set the maximum capacity of the slot
        Parameters:
        nMaxCapacity - the maximum capacity
      • getIdWorkingDay

        public int getIdWorkingDay()
        Get the working day id the time slot belongs to
        Returns:
        the working day id the time slot belongs to
      • setIdWorkingDay

        public void setIdWorkingDay​(int nIdWorkingDay)
        Set the working day id the time slot belongs to
        Parameters:
        nIdWorkingDay - the working day id to set
      • getStartingDateTime

        public java.time.LocalDateTime getStartingDateTime()
      • setStartingDateTime

        public void setStartingDateTime​(java.time.LocalDateTime startingDateTime)
      • getEndingDateTime

        public java.time.LocalDateTime getEndingDateTime()
      • setEndingDateTime

        public void setEndingDateTime​(java.time.LocalDateTime endingDateTime)