com.github.asvid.biedra.domain / TimeRange

TimeRange

class TimeRange (source)

TimeRange allows easer storing and manipulating time ranges, for example: Shop open hours This class uses Duration and LocalTime from JodaTime library, because similar Java classes are available from API26

Constructors

Name Summary
<init> TimeRange(start: LocalTime, length: Duration)
that takes LocalTime start and Duration duration of rangeTimeRange(startDate: Date, endDate: Date)
that takes standard Java Date start and Date endTimeRange(start: LocalTime, end: LocalTime)
TimeRange allows easer storing and manipulating time ranges, for example: Shop open hours This class uses Duration and LocalTime from JodaTime library, because similar Java classes are available from API26

Properties

Name Summary
end val end: LocalTime
end of range
start val start: LocalTime
beginning of range

Functions

Name Summary
toHours fun toHours(): Int
toMinutes fun toMinutes(): Int
toString fun toString(): String
withinRange fun withinRange(time: LocalTime): Boolean