Class IntBinaryData

java.lang.Object
llnl.gnem.core.waveform.io.BinaryData
llnl.gnem.core.waveform.io.IntBinaryData

public class IntBinaryData extends BinaryData
Author:
addair1
  • Constructor Details

    • IntBinaryData

      public IntBinaryData(int n)
      Constructs a BinaryData object using an array of ints.
    • IntBinaryData

      public IntBinaryData(IntBinaryData source, int newLength)
  • Method Details

    • getIntData

      public int[] getIntData()
      Description copied from class: BinaryData
      Returns an array of ints corresponding to the contents of this object. If the internal data are in float or double form a loss of precision may occur.
      Specified by:
      getIntData in class BinaryData
      Returns:
      The contents of this object as an array of ints.
    • getFloatData

      public float[] getFloatData()
      Description copied from class: BinaryData
      Returns an array of floats corresponding to the contents of this object. If the internal data are in double form a loss of precision may occur. If the internal data are stored as ints with values that require more precision that can be represented by a float then a loss of precision will occur.
      Specified by:
      getFloatData in class BinaryData
      Returns:
      The contents of this object as an array of floats.
    • getDoubleData

      public double[] getDoubleData()
      Description copied from class: BinaryData
      Returns an array of doubles corresponding to the contents of this object. If the internal data are stored as ints with values that require more precision that can be represented by a double then a loss of precision will occur.
      Specified by:
      getDoubleData in class BinaryData
      Returns:
      The contents of this object as an array of doubles.
    • getInt

      public int getInt(int i)
      Specified by:
      getInt in class BinaryData
    • size

      public int size()
      Specified by:
      size in class BinaryData
    • setInt

      public void setInt(int i, int value)
      Specified by:
      setInt in class BinaryData
    • setFloat

      public void setFloat(int i, float value)
      Specified by:
      setFloat in class BinaryData
    • setDouble

      public void setDouble(int i, double value)
      Specified by:
      setDouble in class BinaryData