Record Class NetCDFDimensionIndexes.ArrayTimeAxisLookup
- All Implemented Interfaces:
NetCDFDimensionIndexes.AxisLookup,NetCDFDimensionIndexes.TimeAxisLookup
- Enclosing class:
- NetCDFDimensionIndexes
public static record NetCDFDimensionIndexes.ArrayTimeAxisLookup(long[] values)
extends Record
implements NetCDFDimensionIndexes.TimeAxisLookup
Array-backed time lookup for irregular temporal axes.
-
Constructor Summary
ConstructorsConstructorDescriptionArrayTimeAxisLookup(long[] values) Builds a temporal lookup backed by explicit axis values. -
Method Summary
Modifier and TypeMethodDescriptionfinal booleanIndicates whether some other object is "equal to" this one.intReturns the index of the axis element exactly matching the provided value.intfirstIndexAfter(Date value, boolean inclusive) Returns the first index whose value is after, or optionally equal to, the provided value.final inthashCode()Returns a hash code value for this object.intlastIndexBefore(Date value, boolean inclusive) Returns the exclusive upper bound index for values before, or optionally equal to, the provided value.intsize()Returns the number of values available on the axis.final StringtoString()Returns a string representation of this record class.valueAt(int index) Returns the temporal value at the specified axis index.long[]values()Returns the value of thevaluesrecord component.
-
Constructor Details
-
ArrayTimeAxisLookup
public ArrayTimeAxisLookup(long[] values) Builds a temporal lookup backed by explicit axis values.
-
-
Method Details
-
size
public int size()Description copied from interface:NetCDFDimensionIndexes.AxisLookupReturns the number of values available on the axis.- Specified by:
sizein interfaceNetCDFDimensionIndexes.AxisLookup
-
exact
Description copied from interface:NetCDFDimensionIndexes.TimeAxisLookupReturns the index of the axis element exactly matching the provided value.- Specified by:
exactin interfaceNetCDFDimensionIndexes.TimeAxisLookup
-
firstIndexAfter
Description copied from interface:NetCDFDimensionIndexes.TimeAxisLookupReturns the first index whose value is after, or optionally equal to, the provided value.- Specified by:
firstIndexAfterin interfaceNetCDFDimensionIndexes.TimeAxisLookup
-
lastIndexBefore
Description copied from interface:NetCDFDimensionIndexes.TimeAxisLookupReturns the exclusive upper bound index for values before, or optionally equal to, the provided value.- Specified by:
lastIndexBeforein interfaceNetCDFDimensionIndexes.TimeAxisLookup
-
valueAt
Description copied from interface:NetCDFDimensionIndexes.TimeAxisLookupReturns the temporal value at the specified axis index.- Specified by:
valueAtin interfaceNetCDFDimensionIndexes.TimeAxisLookup
-
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
hashCode
public final int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared withObjects::equals(Object,Object). -
values
public long[] values()Returns the value of thevaluesrecord component.- Returns:
- the value of the
valuesrecord component
-