Time class

Model wrapper class Time for TimeOfDay

Inheritance

Constructors

Time({required int hour, required int minute, int? second})
Constructor for the class
Time.fromTimeOfDay(TimeOfDay time, int? secondVal)
Get Time instance from TimeOfDay
factory

Properties

hashCode int
The hash code for this object.
no setterinherited
hour int
The selected hour, in 24 hour time from 0..23.
finalinherited
hourOfPeriod int
Which hour of the current period (e.g., am or pm) this time is.
no setterinherited
minute int
The selected minute.
finalinherited
period DayPeriod
Whether this time of day is before or after noon.
no setterinherited
periodOffset int
The hour at which the current period starts.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
second int
getter/setter pair

Methods

format(BuildContext context) String
Returns the localized string representation of this time of day.
inherited
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
replacing({int? hour, int? minute, int? second}) Time
Overide TimeOfDay.replacing
override
setPeriod(DayPeriod period) Time
Toggle DayPeriod
toString() String
A string representation of this object.
inherited
toTimeOfDay() TimeOfDay
Get TimeOfDay instance from Time

Operators

operator ==(Object other) bool
The equality operator.
inherited