Era class

Represents an era used in a calendar.

All the built-in calendars in Time Machine use the values specified by the static read-only fields in this class. These may be compared for reference equality to check for specific eras.

Annotations
  • @immutable

Properties

hashCode int
The hash code for this object.
no setterinherited
name String
Returns the name of this era, e.g. 'CE' or "BCE".
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
Returns the name of this era.
override

Operators

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

Constants

annoHegirae → const Era
The 'Anno Hegira' era. This is the sole era used in the Hijri (Islamic) calendar.
annoMartyrum → const Era
The 'Anno Martyrum' or "Era of the Martyrs". This is the sole era used in the Coptic calendar.
annoMundi → const Era
The 'Anno Mundi' era. This is the sole era used in the Hebrew calendar.
annoPersico → const Era
The 'Anno Persico' era. This is the sole era used in the Persian calendar.
bahai → const Era
The "Bahá'í" era. This is the sole era used in the Wondrous calendar.
beforeCommon → const Era
The 'before common' era (BCE), also known as Before Christ (BC). This is used in the ISO, Gregorian and Julian calendars.
common → const Era
The 'Common' era (CE), also known as Anno Domini (AD). This is used in the ISO, Gregorian and Julian calendars.