ETDateTime class

Represents a date and time in the Ethiopian calendar system.

Inheritance
Available extensions

Constructors

ETDateTime(int year, [int month = 1, int day = 1, int hour = 0, int minute = 0, int second = 0, int millisecond = 0, int microsecond = 0, String timeofday = '', int? _weekday])
Represents a date and time in the Ethiopian calendar system.

Properties

asETDateTime ETDateTime

Available on DateTime, provided by the DateTimeConvertor extension

Casts the current Gregorian date time to Ethiopian date time.
no setter
day int
The day of the month.
getter/setter pairoverride-getter
hashCode int
The hash code for this object.
no setterinherited
hour int
The hour of the day (0-23).
getter/setter pairoverride-getter
isUtc bool
True if this DateTime is set to UTC time.
finalinherited
microsecond int
The microsecond within the millisecond (0-999).
getter/setter pairoverride-getter
microsecondsSinceEpoch int
The number of microseconds since the "Unix epoch" 1970-01-01T00:00:00Z (UTC).
no setterinherited
millisecond int
The millisecond within the second (0-999).
getter/setter pairoverride-getter
millisecondsSinceEpoch int
The number of milliseconds since the "Unix epoch" 1970-01-01T00:00:00Z (UTC).
no setterinherited
minute int
The minute within the hour (0-59).
getter/setter pairoverride-getter
month int
The month in the Ethiopian calendar system (1-13).
getter/setter pairoverride-getter
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
second int
The second within the minute (0-59).
getter/setter pairoverride-getter
timeofday String
A string representing the time of day (e.g., 'QEN','MATA,'TEWAT, or 'LELIT').
getter/setter pair
timeZoneName String
The time zone name.
no setterinherited
timeZoneOffset Duration
The time zone offset, which is the difference between local time and UTC.
no setterinherited
weekday int
The day of the week (1-7 where 7 represents Sunday).
getter/setter pairoverride-getter
year int
The year in the Ethiopian calendar system.
getter/setter pairoverride-getter

Methods

add(Duration duration) ETDateTime
Returns a new DateTime instance with duration added to this DateTime.
override
compareTo(DateTime other) int
Compares this DateTime object to other, returning zero if the values are equal.
inherited
convertToEthiopian([bool timeDependent = false]) ETDateTime

Available on DateTime, provided by the DateTimeConvertor extension

Converts a given Gregorian DateTime to the Ethiopian calendar representation.
convertToGregorian([bool timeDependent = false]) DateTime
Converts the current Ethiopian ETDateTime object to the Gregorian calendarDateTime.
copyWith({int? year, int? month, int? day, int? hour, int? minute, int? second, int? millisecond, int? microsecond, bool? isUtc}) DateTime

Available on DateTime, provided by the DateTimeCopyWith extension

Creates a new DateTime from this one by updating individual properties.
difference(DateTime other) Duration
Returns a Duration with the difference when subtracting other from this DateTime.
inherited
isAfter(DateTime other) bool
Whether this DateTime occurs after other.
inherited
isAtSameMomentAs(DateTime other) bool
Whether this DateTime occurs at the same moment as other.
inherited
isBefore(DateTime other) bool
Whether this DateTime occurs before other.
inherited
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
subtract(Duration duration) ETDateTime
Returns a new DateTime instance with duration subtracted from this DateTime.
override
toIso8601String() String
Returns an ISO-8601 full-precision extended format representation.
inherited
toLocal() DateTime
Returns this DateTime value in the local time zone.
inherited
toString() String
Returns a human-readable string for this instance.
inherited
toUtc() DateTime
Returns this DateTime value in the UTC time zone.
inherited

Operators

operator ==(Object other) bool
Whether other is a DateTime at the same moment and in the same time zone (UTC or local).
inherited

Static Methods

listOfETDateSymbol(String? locale, String key) List<String>
now([bool timeDependent = false]) ETDateTime
Returns the current date and time in the Ethiopian calendar.

Constants

arb → const int
daysPerWeek → const int
ehud → const int
erob → const int
ginbot → const int
hamle → const int
hamus → const int
hidar → const int
maksegno → const int
megabit → const int
meskerem → const int
miyazya → const int
monthsPerYear → const int
nehase → const int
pagume → const int
qdame → const int
segno → const int
sene → const int
tahsas → const int
tikimt → const int
tir → const int
yekatit → const int