| Modifier and Type | Field and Description |
|---|---|
| public static final int | DEFAULT_PRECISION
The default leading field precision for intervals. |
| public static final int | DEFAULT_SCALE
The default scale for intervals with seconds. |
| private final long | |
| public static final int | MAXIMUM_PRECISION
The maximum leading field precision for intervals. |
| public static final int | MAXIMUM_SCALE
The maximum scale for intervals with seconds. |
| private static final long[] | |
| private final boolean | |
| private final long | |
| private final int |
| Access | Constructor and Description |
|---|---|
| private |
| Modifier and Type | Method and Description |
|---|---|
| public Value | |
| pack-priv boolean | Returns: true if the precision of this value is smaller or equal to the given precisionthe maximum precision prec)Check if the precision is smaller or equal than the given precision. |
| public int | compareTypeSafe(Value
the other value v, CompareMode the compare mode mode, CastDataProvider the cast information provider provider)Implements abstract org. Compare this value against another value given that the values are of the same data type. |
| public boolean | equals(Object
the other value obj)Implements abstract org. Check if the two values have the same hash code. |
| public static ValueInterval | Returns: interval valuequalifier qualifier, boolean whether interval is negative negative, long value of leading field leading, long values of all remaining fields remaining)Create a ValueInterval instance. |
| public BigDecimal | |
| public static int | Returns: display sizethe value type type, int leading field precision precision, int fractional seconds precision. Ignored if specified type of
interval does not have seconds. scale)Returns display size for the specified qualifier, precision and fractional seconds precision. |
| public double | |
| public float | |
| public Interval | |
| public long | |
| public long | |
| public int | |
| public IntervalQualifier | |
| public long | Returns: combined value of remaining fieldsReturns combined value of remaining fields of this interval. |
| public int | |
| public StringBuilder | getSQL(StringBuilder
string builder builder, int formatting flags sqlFlags)Implements org. Appends the SQL statement of this object to the specified builder. |
| public String | |
| public TypeInfo | getType()
Implements abstract org. Implements org. Returns the data type. |
| public int | |
| public int | hashCode()
Implements abstract org. Returns a hash code value for this object. |
| public boolean | |
| public Value | negate()
Overrides org. Return -value if this value support arithmetic operations. |
| pack-priv ValueInterval | |
| public Value | subtract(Value
the value to subtract v)Overrides org. Subtract a value and return the result. |
| DEFAULT_PRECISION | back to summary |
|---|---|
| public static final int DEFAULT_PRECISION The default leading field precision for intervals. | |
| DEFAULT_SCALE | back to summary |
|---|---|
| public static final int DEFAULT_SCALE The default scale for intervals with seconds. | |
| leading | back to summary |
|---|---|
| private final long leading | |
| MAXIMUM_PRECISION | back to summary |
|---|---|
| public static final int MAXIMUM_PRECISION The maximum leading field precision for intervals. | |
| MAXIMUM_SCALE | back to summary |
|---|---|
| public static final int MAXIMUM_SCALE The maximum scale for intervals with seconds. | |
| MULTIPLIERS | back to summary |
|---|---|
| private static final long[] MULTIPLIERS | |
| negative | back to summary |
|---|---|
| private final boolean negative | |
| remaining | back to summary |
|---|---|
| private final long remaining | |
| valueType | back to summary |
|---|---|
| private final int valueType | |
| ValueInterval | back to summary |
|---|---|
| private ValueInterval(int type, boolean negative, long leading, long remaining) | |
| add | back to summary |
|---|---|
| public Value add(Value v) Overrides org. Doc from org. Add a value and return the result. | |
| checkPrecision | back to summary |
|---|---|
| pack-priv boolean checkPrecision(long prec) Check if the precision is smaller or equal than the given precision.
| |
| compareTypeSafe | back to summary |
|---|---|
| public int compareTypeSafe(Value v, CompareMode mode, CastDataProvider provider) Implements abstract org. Doc from org. Compare this value against another value given that the values are of the same data type.
| |
| equals | back to summary |
|---|---|
| public boolean equals(Object obj) Implements abstract org. Doc from org. Check if the two values have the same hash code. No data conversion is made; this method returns false if the other object is not of the same class. For some values, compareTo may return 0 even if equals return false. Example: ValueDecimal 0.0 and 0.00. | |
| from | back to summary |
|---|---|
| public static ValueInterval from(IntervalQualifier qualifier, boolean negative, long leading, long remaining) Create a ValueInterval instance.
| |
| getBigDecimal | back to summary |
|---|---|
| public BigDecimal getBigDecimal() Overrides org.
| |
| getDisplaySize | back to summary |
|---|---|
| public static int getDisplaySize(int type, int precision, int scale) Returns display size for the specified qualifier, precision and fractional seconds precision.
| |
| getDouble | back to summary |
|---|---|
| public double getDouble() Overrides org. Doc from org. Returns this value as a Java
| |
| getFloat | back to summary |
|---|---|
| public float getFloat() Overrides org. Doc from org. Returns this value as a Java
| |
| getInterval | back to summary |
|---|---|
| public Interval getInterval() Returns the interval.
| |
| getLeading | back to summary |
|---|---|
| public long getLeading() Returns value of leading field of this interval. For
| |
| getLong | back to summary |
|---|---|
| public long getLong() Overrides org. Doc from org. Returns this value as a Java
| |
| getMemory | back to summary |
|---|---|
| public int getMemory() Overrides org. Doc from org. Get the memory used by this object.
| |
| getQualifier | back to summary |
|---|---|
| public IntervalQualifier getQualifier() Returns the interval qualifier.
| |
| getRemaining | back to summary |
|---|---|
| public long getRemaining() Returns combined value of remaining fields of this interval. For
| |
| getSignum | back to summary |
|---|---|
| public int getSignum() Overrides org.
| |
| getSQL | back to summary |
|---|---|
| public StringBuilder getSQL(StringBuilder builder, int sqlFlags) Implements org. Doc from org. Appends the SQL statement of this object to the specified builder.
| |
| getString | back to summary |
|---|---|
| public String getString() Implements abstract org. Doc from org. Get the value as a string. | |
| getType | back to summary |
|---|---|
| public TypeInfo getType() Implements abstract org. Implements org. Doc from org. Returns the data type. | |
| getValueType | back to summary |
|---|---|
| public int getValueType() Implements abstract org. Doc from org. Get the value type.
| |
| hashCode | back to summary |
|---|---|
| public int hashCode() Implements abstract org. Doc from java. Returns a hash code value for this object. This method is
supported for the benefit of hash tables such as those provided by
The general contract of
| |
| isNegative | back to summary |
|---|---|
| public boolean isNegative() Returns where the interval is negative.
| |
| negate | back to summary |
|---|---|
| public Value negate() Overrides org. Doc from org. Return -value if this value support arithmetic operations. | |
| setPrecisionAndScale | back to summary |
|---|---|
| pack-priv ValueInterval setPrecisionAndScale(TypeInfo targetType, Object column) | |
| subtract | back to summary |
|---|---|
| public Value subtract(Value v) Overrides org. Doc from org. Subtract a value and return the result. | |