Documentation of 'jhplot.math.num.DoubleArray' Java class.
DoubleArray
jhplot.math.num

Class DoubleArray



  • public class DoubleArray
    extends java.lang.Object
    An expandable double array.
    Since:
    1.1
    • Constructor Summary

      Constructors 
      Constructor and Description
      DoubleArray() 
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method and Description
      void add(double value)
      Adds an element to the end of this expandable array.
      void clear()
      Remove all elements from this collection.
      double get(int index)
      Access the element at the given index.
      int getSize()
      Access the size of this array.
      void set(int index, double value)
      Modify the element at the given index.
      void setSize(int n)
      Modify the size of this array.
      double[] toArray()
      Convert this array into a native array.
      • Methods inherited from class java.lang.Object

        equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • DoubleArray

        public DoubleArray()
    • Method Detail

      • add

        public void add(double value)
        Adds an element to the end of this expandable array.
        Parameters:
        value - to be added to end of array
      • clear

        public void clear()
        Remove all elements from this collection.
      • get

        public double get(int index)
        Access the element at the given index.
        Parameters:
        index - the index of the element to retrieve.
        Returns:
        the index-th element.
      • getSize

        public int getSize()
        Access the size of this array.
        Returns:
        the size.
      • set

        public void set(int index,
                        double value)
        Modify the element at the given index. The array may be expanded to hold a value at the given index.
        Parameters:
        index - the index of the element to modify.
        value - the new index-th element value.
      • setSize

        public void setSize(int n)
        Modify the size of this array.
        Parameters:
        n - the new array size.
      • toArray

        public double[] toArray()
        Convert this array into a native array.
        Returns:
        the native array.

DMelt 3.0 © DataMelt by jWork.ORG