Uses of Class
javax.time.calendar.PeriodUnit
Packages that use PeriodUnit
Package
Description
Provides classes to manage the human time scale including date, time,
date-time and time-zone representations.
Provides classes representing dates and times in alternate calendar systems.
-
Uses of PeriodUnit in javax.time.calendar
Subclasses of PeriodUnit in javax.time.calendarModifier and TypeClassDescription(package private) static final class
Single unit subclass, which means fewer classes to load at startup.Fields in javax.time.calendar declared as PeriodUnitModifier and TypeFieldDescriptionprivate final PeriodUnit
CalendricalRule.periodRange
The period range, not null.private final PeriodUnit
CalendricalRule.periodUnit
The period unit, not null.private final PeriodUnit
PeriodField.unit
The unit the period is measured in.private static final PeriodUnit[]
Period.UNITS
The ISO period units, trusted to not be altered.Fields in javax.time.calendar with type parameters of type PeriodUnitModifier and TypeFieldDescriptionprivate final TreeMap<PeriodUnit,
PeriodField> PeriodFields.unitFieldMap
The map of periods.Methods in javax.time.calendar that return PeriodUnitModifier and TypeMethodDescriptionPeriodUnit.getBaseUnit()
Gets the base unit of this unit.CalendricalRule.getPeriodRange()
Gets the range that the rule is bound by.CalendricalRule.getPeriodUnit()
Gets the unit that the rule is measured in.PeriodField.getUnit()
Gets the unit of this period.static PeriodUnit
ISOChronology.period12Hours()
Gets the period unit for twelve hours, as used by AM/PM.static PeriodUnit
ISOChronology.period24Hours()
Gets the period unit for twenty-four hours, that is often treated as a day.static PeriodUnit
ISOChronology.periodCenturies()
Gets the period unit for centuries of 100 years.static PeriodUnit
ISOChronology.periodDays()
Gets the period unit for days.static PeriodUnit
ISOChronology.periodDecades()
Gets the period unit for decades of 10 years.static PeriodUnit
ISOChronology.periodEras()
Gets the period unit for eras.static PeriodUnit
ISOChronology.periodHours()
Gets the period unit for hours of 60 minutes.static PeriodUnit
ISOChronology.periodMicros()
Gets the period unit for microseconds.static PeriodUnit
ISOChronology.periodMillennia()
Gets the period unit for millennia of 1000 years.static PeriodUnit
ISOChronology.periodMillis()
Gets the period unit for milliseconds.static PeriodUnit
ISOChronology.periodMinutes()
Gets the period unit for minutes of 60 seconds.static PeriodUnit
ISOChronology.periodMonths()
Gets the period unit for months.static PeriodUnit
ISOChronology.periodNanos()
Gets the period unit for nanoseconds.static PeriodUnit
ISOChronology.periodQuarters()
Gets the period unit for quarters of 3 months.static PeriodUnit
ISOChronology.periodSeconds()
Gets the period unit for seconds.static PeriodUnit
ISOChronology.periodWeekBasedYears()
Gets the period unit for week-based-years.static PeriodUnit
ISOChronology.periodWeeks()
Gets the period unit for weeks of 7 days.static PeriodUnit
ISOChronology.periodYears()
Gets the period unit for years of 12 months.Methods in javax.time.calendar that return types with arguments of type PeriodUnitModifier and TypeMethodDescriptionprivate TreeMap<PeriodUnit,
PeriodField> PeriodFields.clonedMap()
Clone the internal data storage map.private static TreeMap<PeriodUnit,
PeriodField> PeriodFields.createMap()
Creates a new empty map.PeriodFields.toMap()
Returns aMap
equivalent to this period.Methods in javax.time.calendar with parameters of type PeriodUnitModifier and TypeMethodDescriptionint
ISOChronology.Unit.compareTo
(PeriodUnit other) int
PeriodUnit.compareTo
(PeriodUnit other) Compares this unit to another.boolean
PeriodFields.contains
(PeriodUnit unit) Checks whether this period contains an amount for the unit.PeriodFields.get
(PeriodUnit unit) Gets the period for the specified unit.long
PeriodFields.getAmount
(PeriodUnit unit) Gets the amount of this period for the specified unit.int
PeriodFields.getAmountInt
(PeriodUnit unit) Gets the amount of this period for the specified unit converted to anint
.PeriodUnit.getEquivalentPeriod
(PeriodUnit requiredUnit) Gets the period in the specified unit that is equivalent to this unit.boolean
PeriodUnit.isConvertibleTo
(PeriodUnit unit) Checks whether this unit can be converted to the specified unit.PeriodFields.minus
(long amount, PeriodUnit unit) Returns a copy of this period with the specified period subtracted.PeriodFields.normalizedTo
(PeriodUnit... units) Returns a copy of this period with the amounts normalized to the specified units.static Period
Period.of
(int amount, PeriodUnit unit) Obtains aPeriod
from an amount and unit.static PeriodField
PeriodField.of
(long amount, PeriodUnit unit) Obtains aPeriodField
from an amount and unit.static PeriodFields
PeriodFields.of
(long amount, PeriodUnit unit) Obtains aPeriodFields
from an amount and unit.PeriodFields.plus
(long amount, PeriodUnit unit) Returns a copy of this period with the specified period added.PeriodFields.retain
(PeriodUnit... units) Returns a copy of this period with the specified units retained.PeriodFields.retainConvertible
(PeriodUnit... units) Returns a copy of this period with only those units that can be converted to the specified units.PeriodField.toEquivalent
(PeriodUnit requiredUnit) Converts this period to an equivalent in the specified unit.PeriodField.toEquivalent
(PeriodUnit... requiredUnits) Converts this period to an equivalent in one of the units specified.PeriodFields.toEquivalent
(PeriodUnit... units) Converts this period to one containing only the units specified.PeriodFields.toTotal
(PeriodUnit unit) Totals this period in terms of a single unit.PeriodFields.with
(long amount, PeriodUnit unit) Returns a copy of this period with the specified amount for the unit.PeriodFields.without
(PeriodUnit unit) Returns a copy of this period with the specified unit removed.PeriodField.withUnit
(PeriodUnit unit) Returns a copy of this period with a different unit.Method parameters in javax.time.calendar with type arguments of type PeriodUnitModifier and TypeMethodDescription(package private) static PeriodFields
PeriodFields.create
(TreeMap<PeriodUnit, PeriodField> periodMap) Internal factory to create an instance using a pre-built map.Constructors in javax.time.calendar with parameters of type PeriodUnitModifierConstructorDescriptionprotected
CalendricalRule
(Class<T> reifiedClass, Chronology chronology, String name, PeriodUnit periodUnit, PeriodUnit periodRange) Constructor used to create a rule.protected
DateTimeFieldRule
(Class<T> reifiedClass, Chronology chronology, String name, PeriodUnit periodUnit, PeriodUnit periodRange, int minimumValue, int maximumValue) Constructor.protected
DateTimeFieldRule
(Class<T> reifiedClass, Chronology chronology, String name, PeriodUnit periodUnit, PeriodUnit periodRange, int minimumValue, int maximumValue, boolean hasText) Constructor.private
PeriodField
(long amount, PeriodUnit unit) Constructor.private
Rule
(int ordinal, String name, PeriodUnit periodUnit, PeriodUnit periodRange, int minimumValue, int maximumValue, int smallestMaximum) Constructor parameters in javax.time.calendar with type arguments of type PeriodUnitModifierConstructorDescriptionprivate
PeriodFields
(TreeMap<PeriodUnit, PeriodField> periodMap) Constructs an instance using a pre-built map. -
Uses of PeriodUnit in javax.time.i18n
Subclasses of PeriodUnit in javax.time.i18nModifier and TypeClassDescriptionprivate static final class
Unit class for months.private static final class
Unit class for years.private static final class
Unit class for months.private static final class
Unit class for years.private static final class
Unit class for months.private static final class
Unit class for years.Fields in javax.time.i18n declared as PeriodUnitModifier and TypeFieldDescriptionprivate static final PeriodUnit
CopticChronology.MONTHS
Period unit for months.private static final PeriodUnit
HistoricChronology.MONTHS
Period unit for months.private static final PeriodUnit
JulianChronology.MONTHS
Period unit for months.private static final PeriodUnit
CopticChronology.YEARS
Period unit for years.private static final PeriodUnit
HistoricChronology.YEARS
Period unit for years.private static final PeriodUnit
JulianChronology.YEARS
Period unit for years.Methods in javax.time.i18n that return PeriodUnitModifier and TypeMethodDescriptionstatic PeriodUnit
CopticChronology.periodDays()
Gets the period unit for days.static PeriodUnit
HistoricChronology.periodDays()
Gets the period unit for days.static PeriodUnit
JulianChronology.periodDays()
Gets the period unit for days.static PeriodUnit
HistoricChronology.periodEras()
Gets the period unit for eras.static PeriodUnit
CopticChronology.periodMonths()
Gets the period unit for months.static PeriodUnit
HistoricChronology.periodMonths()
Gets the period unit for months.static PeriodUnit
JulianChronology.periodMonths()
Gets the period unit for months.static PeriodUnit
CopticChronology.periodWeeks()
Gets the period unit for weeks.static PeriodUnit
HistoricChronology.periodWeeks()
Gets the period unit for weeks.static PeriodUnit
JulianChronology.periodWeeks()
Gets the period unit for weeks.static PeriodUnit
CopticChronology.periodYears()
Gets the period unit for years.static PeriodUnit
HistoricChronology.periodYears()
Gets the period unit for years.static PeriodUnit
JulianChronology.periodYears()
Gets the period unit for years.