Class VariableTime

  • All Implemented Interfaces:
    Copy<ch.poole.openinghoursparser.Element>

    public class VariableTime
    extends java.lang.Object
    Container for objects from the opening_hours specification
    • Constructor Detail

      • VariableTime

        public VariableTime()
        Default constructor
      • VariableTime

        public VariableTime​(@NotNull
                            @NotNull VariableTime vt)
        Construct a new VariableTime with the same contents
        Parameters:
        vt - the original VariableTime
    • Method Detail

      • toString

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Object
      • equals

        public boolean equals​(java.lang.Object other)
      • hashCode

        public int hashCode()
      • getEvent

        public Event getEvent()
        Returns:
        the event
      • getOffset

        public int getOffset()
        Returns:
        the offset
      • setEvent

        public void setEvent​(Event event)
        Set the day the range starts on
        Parameters:
        event - the event to set
      • setEvent

        public void setEvent​(java.lang.String event)
        Set the day the range starts on
        Parameters:
        event - the event to set
      • setOffset

        public void setOffset​(int offset)
        Parameters:
        offset - the offset to set
      • copy

        public VariableTime copy()
        Description copied from interface: Copy
        Create a copy of the objecz
        Returns:
        a copy of the object
      • toDebugString

        public java.lang.String toDebugString()
        Create a string that identifies which class created it for debugging and testing
        Returns:
        the output of toString with the class name prepended