Class MatlabNumericArray.DoubleArrayType<T>

  • Type Parameters:
    T - an array of 2 or more dimensions which holds doubles
    Enclosing class:
    MatlabNumericArray

    public static final class MatlabNumericArray.DoubleArrayType<T>
    extends java.lang.Object
    An array type of dimension 2 or greater which holds doubles. Instances for dimensions 2 through 9 are available as public static fields.

    This class is unconditionally thread-safe.
    • Method Detail

      • getInstance

        public static <T> MatlabNumericArray.DoubleArrayType<T> getInstance​(java.lang.Class<T> arrayType)
        Gets an instance of DoubleArrayType<T> where T is the type of arrayType. T must be an array of 1 or more dimensions that holds doubles. This is intended for getting array types in excess of 9 dimensions, as dimensions 2 through 9 are represented by constants DIM_2 ... DIM_9.

        Contrived example usage:
        DoubleArrayType<double[][][]> type3D = DoubleArrayType.getInstance(double[][][].class);
        Type Parameters:
        T -
        Parameters:
        arrayType -
        Returns:
        Throws:
        java.lang.IllegalArgumentException - if the type is not an array holding doubles or the type is of less than 2 dimensions
      • getDimensions

        public int getDimensions()
        The number of dimensions of the array type.
        Returns:
      • getArrayClass

        public java.lang.Class<T> getArrayClass()
        The type of array. The array holds doubles, and may be of any dimension 2 or greater.
        Returns:
      • toString

        public java.lang.String toString()
        Returns a brief description of this double array type. The exact details of this representation are unspecified and are subject to change.
        Overrides:
        toString in class java.lang.Object
        Returns: