Enum VTLChronoUnit
- java.lang.Object
-
- java.lang.Enum<VTLChronoUnit>
-
- it.bancaditalia.oss.vtl.impl.types.data.date.VTLChronoUnit
-
- All Implemented Interfaces:
Serializable
,Comparable<VTLChronoUnit>
,TemporalUnit
public enum VTLChronoUnit extends Enum<VTLChronoUnit> implements TemporalUnit
-
-
Enum Constant Summary
Enum Constants Enum Constant Description SEMESTERS
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description <R extends Temporal>
RaddTo(R temporal, long amount)
long
between(Temporal temporal1Inclusive, Temporal temporal2Exclusive)
Duration
getDuration()
boolean
isDateBased()
boolean
isDurationEstimated()
boolean
isSupportedBy(Temporal temporal)
boolean
isTimeBased()
String
toString()
static VTLChronoUnit
valueOf(String name)
Returns the enum constant of this type with the specified name.static VTLChronoUnit[]
values()
Returns an array containing the constants of this enum type, in the order they are declared.
-
-
-
Enum Constant Detail
-
SEMESTERS
public static final VTLChronoUnit SEMESTERS
-
-
Method Detail
-
values
public static VTLChronoUnit[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:for (VTLChronoUnit c : VTLChronoUnit.values()) System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
public static VTLChronoUnit valueOf(String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)- Parameters:
name
- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException
- if this enum type has no constant with the specified nameNullPointerException
- if the argument is null
-
getDuration
public Duration getDuration()
- Specified by:
getDuration
in interfaceTemporalUnit
-
isDurationEstimated
public boolean isDurationEstimated()
- Specified by:
isDurationEstimated
in interfaceTemporalUnit
-
isDateBased
public boolean isDateBased()
- Specified by:
isDateBased
in interfaceTemporalUnit
-
isTimeBased
public boolean isTimeBased()
- Specified by:
isTimeBased
in interfaceTemporalUnit
-
isSupportedBy
public boolean isSupportedBy(Temporal temporal)
- Specified by:
isSupportedBy
in interfaceTemporalUnit
-
addTo
public <R extends Temporal> R addTo(R temporal, long amount)
- Specified by:
addTo
in interfaceTemporalUnit
-
between
public long between(Temporal temporal1Inclusive, Temporal temporal2Exclusive)
- Specified by:
between
in interfaceTemporalUnit
-
toString
public String toString()
- Specified by:
toString
in interfaceTemporalUnit
- Overrides:
toString
in classEnum<VTLChronoUnit>
-
-