Package org.joda.time
Class DurationFieldType.StandardDurationFieldType
- java.lang.Object
-
- org.joda.time.DurationFieldType
-
- org.joda.time.DurationFieldType.StandardDurationFieldType
-
- All Implemented Interfaces:
java.io.Serializable
- Enclosing class:
- DurationFieldType
private static class DurationFieldType.StandardDurationFieldType extends DurationFieldType
-
-
Field Summary
Fields Modifier and Type Field Description private byte
iOrdinal
The ordinal of the standard field type, for switch statementsprivate static long
serialVersionUID
Serialization version-
Fields inherited from class org.joda.time.DurationFieldType
CENTURIES, CENTURIES_TYPE, DAYS, DAYS_TYPE, ERAS, ERAS_TYPE, HALFDAYS, HALFDAYS_TYPE, HOURS, HOURS_TYPE, MILLIS, MILLIS_TYPE, MINUTES, MINUTES_TYPE, MONTHS, MONTHS_TYPE, SECONDS, SECONDS_TYPE, WEEKS, WEEKS_TYPE, WEEKYEARS, WEEKYEARS_TYPE, YEARS, YEARS_TYPE
-
-
Constructor Summary
Constructors Constructor Description StandardDurationFieldType(java.lang.String name, byte ordinal)
Constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
equals(java.lang.Object obj)
DurationField
getField(Chronology chronology)
Gets a suitable field for this type from the given Chronology.int
hashCode()
private java.lang.Object
readResolve()
Ensure a singleton is returned.
-
-
-
Field Detail
-
serialVersionUID
private static final long serialVersionUID
Serialization version- See Also:
- Constant Field Values
-
iOrdinal
private final byte iOrdinal
The ordinal of the standard field type, for switch statements
-
-
Method Detail
-
equals
public boolean equals(java.lang.Object obj)
- Overrides:
equals
in classjava.lang.Object
-
hashCode
public int hashCode()
- Overrides:
hashCode
in classjava.lang.Object
-
getField
public DurationField getField(Chronology chronology)
Description copied from class:DurationFieldType
Gets a suitable field for this type from the given Chronology.- Specified by:
getField
in classDurationFieldType
- Parameters:
chronology
- the chronology to use, null means ISOChronology in default zone- Returns:
- a suitable field
-
readResolve
private java.lang.Object readResolve()
Ensure a singleton is returned.- Returns:
- the singleton type
-
-