pkg dateTime TimeSlot - yshehab/SchoolRoomBooking GitHub Wiki

TimeSlot Class

Overview

Models use periods for general-use school areas. For some areas/uses Session is more appropriate. TimeSlot is polymorphic in that different schools will have different meanings for a TimeSlot.

TimeSlot implements the repeat interface.

Package

DateTimePackage

Static Members

BEFORE_SCHOOL

PERIOD_1

PERIOD_2

PERIOD_3

PERIOD_4

PERIOD_5

PERIOD_6

PERIOD_7

PERIOD_8

PERIOD_9

AFTER_SCHOOL

EVENING

LATE

NONE

Static Methods

Those inherited from Enum

Attributes

private String display

    The string to display the Enum

Links

None

Constructor

private TimeSlot(String display)

Protocol

public String getDisplayString()

    Post-condition: returns a string representing the Enum

public TimeSlot add(RepeatRate rate)

    Post-condition: Returns the TimeSlot after the receiver or NONE.

public boolean isAfter(TimeSlot slot)

    Post-condition: Returns true if slot is after the receiver, otherwise false.

Examples

Discussion