plugins.adufour.vars.util
Interface ArrayType
- All Known Implementing Classes:
- VarArray, VarDoubleArray, VarDoubleArrayNative, VarFileArray, VarFloatArray, VarFloatArrayNative, VarGenericArray, VarIntegerArray, VarIntegerArrayNative, VarROIArray, VarSequenceArray
public interface ArrayType
getDimensions
int getDimensions()
- Returns:
- the number of dimensions in this array
getInnerType
java.lang.Class<?> getInnerType()
- Returns:
- the type of each element of this array
getSeparator
java.lang.String getSeparator(int dimension)
throws java.lang.ArrayIndexOutOfBoundsException
- Parameters:
dimension
- the dimension for which the separator is wanted
- Returns:
- The character used to separate array values when displaying the value as a String
- Throws:
java.lang.ArrayIndexOutOfBoundsException
parseComponent
java.lang.Object parseComponent(java.lang.String s)
throws java.lang.UnsupportedOperationException
- Parse a string representing an element of the underlying array. Note that this method throws
an
UnsupportedOperationException
by default, therefore the implementation must
be provided by overriding classes
- Parameters:
s
- the string to parse
- Returns:
- a primitive type representing the given string
- Throws:
java.lang.UnsupportedOperationException
size
int size(int dimension)
throws java.lang.ArrayIndexOutOfBoundsException
- Parameters:
dimension
- the dimension along which the size is wanted
- Returns:
- the size of the array in the specified dimension,or -1 if the array is
null
- Throws:
java.lang.ArrayIndexOutOfBoundsException
- if the dimension does not exist