Package fi.bitwards.service
Class BitwardsSchedule.ExceptionDay
java.lang.Object
fi.bitwards.service.BitwardsSchedule.ExceptionDay
- Enclosing class:
BitwardsSchedule
Represents an exception day with alternative access times, which overrule regular rules.
Example exception day: 2021-12-25 (no access on Christmas day)
- exceptionDate: Date instance 2021-12-25 00:00:00, where year, month and day of month are meaningful; ignore time part
- startingTime: -1 (not specified; no access)
- endingTime: -1 (not specified; no access)
Example exception day. 2021-12-24 from 9:15 to 13:15
- exceptionDate: Date instance 2021-12-24 00:00:00, where year, month and day of month are meaningful; ignore time part
- startingTime: 555, inclusive (minutes since midnight, i.e., 9:15)
- endingTime: 795, exclusive (minutes since midnight, i.e., 13:15)
-
Method Summary
Modifier and TypeMethodDescriptionintGet ending time of day when access is granted, exclusive.Get the exception date.getName()Get the name of the exception day.intGet starting time of day when access is granted, inclusive.
-
Method Details
-
getName
Get the name of the exception day.- Returns:
- the name of the exception; null if exception day does not have a name.
-
getExceptionDate
Get the exception date. Only the year, month, and day of month are meaningful. The time of day should be ignored (it usually is midnight, i.e., 0:00:00).- Returns:
- the exception date
-
getStartingTime
public int getStartingTime()Get starting time of day when access is granted, inclusive.- Returns:
- the start time as minutes since midnight
-
getEndingTime
public int getEndingTime()Get ending time of day when access is granted, exclusive.- Returns:
- the ending time as minutes since midnight
-