Class Cast

java.lang.Object
io.deephaven.function.Cast

public class Cast extends Object
Functions for casting between types.
  • Nested Class Summary

    Nested Classes
    Modifier and Type
    Class
    Description
    static class 
    Cast can not preserve the value.
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    static double
    castDouble(byte value)
    Casts a value to a double.
    static double[]
    castDouble(byte... values)
    Casts an array to a double array.
    static double[]
    castDouble(byte[] values, boolean checkFidelity)
    Casts an array to a double array.
    static double
    castDouble(byte value, boolean checkFidelity)
    Casts a value to a double.
    static double
    castDouble(double value)
    Casts a value to a double.
    static double[]
    castDouble(double... values)
    Casts an array to a double array.
    static double[]
    castDouble(double[] values, boolean checkFidelity)
    Casts an array to a double array.
    static double
    castDouble(double value, boolean checkFidelity)
    Casts a value to a double.
    static double
    castDouble(float value)
    Casts a value to a double.
    static double[]
    castDouble(float... values)
    Casts an array to a double array.
    static double[]
    castDouble(float[] values, boolean checkFidelity)
    Casts an array to a double array.
    static double
    castDouble(float value, boolean checkFidelity)
    Casts a value to a double.
    static double
    castDouble(int value)
    Casts a value to a double.
    static double[]
    castDouble(int... values)
    Casts an array to a double array.
    static double[]
    castDouble(int[] values, boolean checkFidelity)
    Casts an array to a double array.
    static double
    castDouble(int value, boolean checkFidelity)
    Casts a value to a double.
    static double
    castDouble(long value)
    Casts a value to a double.
    static double[]
    castDouble(long... values)
    Casts an array to a double array.
    static double[]
    castDouble(long[] values, boolean checkFidelity)
    Casts an array to a double array.
    static double
    castDouble(long value, boolean checkFidelity)
    Casts a value to a double.
    static double
    castDouble(short value)
    Casts a value to a double.
    static double[]
    castDouble(short... values)
    Casts an array to a double array.
    static double[]
    castDouble(short[] values, boolean checkFidelity)
    Casts an array to a double array.
    static double
    castDouble(short value, boolean checkFidelity)
    Casts a value to a double.
    static double[]
    Casts an array to a double array.
    static double[]
    castDouble(ByteVector values, boolean checkFidelity)
    Casts an array to a double array.
    static double[]
    Casts an array to a double array.
    static double[]
    castDouble(DoubleVector values, boolean checkFidelity)
    Casts an array to a double array.
    static double[]
    Casts an array to a double array.
    static double[]
    castDouble(FloatVector values, boolean checkFidelity)
    Casts an array to a double array.
    static double[]
    Casts an array to a double array.
    static double[]
    castDouble(IntVector values, boolean checkFidelity)
    Casts an array to a double array.
    static double[]
    Casts an array to a double array.
    static double[]
    castDouble(LongVector values, boolean checkFidelity)
    Casts an array to a double array.
    static double[]
    Casts an array to a double array.
    static double[]
    castDouble(ShortVector values, boolean checkFidelity)
    Casts an array to a double array.
    static int
    castInt(byte value)
    Casts a value to an int.
    static int[]
    castInt(byte... values)
    Casts an array to an int array.
    static int[]
    castInt(byte[] values, boolean checkFidelity)
    Casts an array to an int array.
    static int
    castInt(byte value, boolean checkFidelity)
    Casts a value to an int.
    static int
    castInt(int value)
    Casts a value to an int.
    static int[]
    castInt(int... values)
    Casts an array to an int array.
    static int[]
    castInt(int[] values, boolean checkFidelity)
    Casts an array to an int array.
    static int
    castInt(int value, boolean checkFidelity)
    Casts a value to an int.
    static int
    castInt(long value)
    Casts a value to an int.
    static int[]
    castInt(long... values)
    Casts an array to an int array.
    static int[]
    castInt(long[] values, boolean checkFidelity)
    Casts an array to an int array.
    static int
    castInt(long value, boolean checkFidelity)
    Casts a value to an int.
    static int
    castInt(short value)
    Casts a value to an int.
    static int[]
    castInt(short... values)
    Casts an array to an int array.
    static int[]
    castInt(short[] values, boolean checkFidelity)
    Casts an array to an int array.
    static int
    castInt(short value, boolean checkFidelity)
    Casts a value to an int.
    static int[]
    Casts an array to an int array.
    static int[]
    castInt(ByteVector values, boolean checkFidelity)
    Casts an array to an int array.
    static int[]
    Casts an array to an int array.
    static int[]
    castInt(IntVector values, boolean checkFidelity)
    Casts an array to an int array.
    static int[]
    Casts an array to an int array.
    static int[]
    castInt(LongVector values, boolean checkFidelity)
    Casts an array to an int array.
    static int[]
    Casts an array to an int array.
    static int[]
    castInt(ShortVector values, boolean checkFidelity)
    Casts an array to an int array.
    static long
    castLong(byte value)
    Casts a value to a long.
    static long[]
    castLong(byte... values)
    Casts an array to a long array.
    static long[]
    castLong(byte[] values, boolean checkFidelity)
    Casts an array to a long array.
    static long
    castLong(byte value, boolean checkFidelity)
    Casts a value to a long.
    static long
    castLong(int value)
    Casts a value to a long.
    static long[]
    castLong(int... values)
    Casts an array to a long array.
    static long[]
    castLong(int[] values, boolean checkFidelity)
    Casts an array to a long array.
    static long
    castLong(int value, boolean checkFidelity)
    Casts a value to a long.
    static long
    castLong(long value)
    Casts a value to a long.
    static long[]
    castLong(long... values)
    Casts an array to a long array.
    static long[]
    castLong(long[] values, boolean checkFidelity)
    Casts an array to a long array.
    static long
    castLong(long value, boolean checkFidelity)
    Casts a value to a long.
    static long
    castLong(short value)
    Casts a value to a long.
    static long[]
    castLong(short... values)
    Casts an array to a long array.
    static long[]
    castLong(short[] values, boolean checkFidelity)
    Casts an array to a long array.
    static long
    castLong(short value, boolean checkFidelity)
    Casts a value to a long.
    static long[]
    Casts an array to a long array.
    static long[]
    castLong(ByteVector values, boolean checkFidelity)
    Casts an array to a long array.
    static long[]
    Casts an array to a long array.
    static long[]
    castLong(IntVector values, boolean checkFidelity)
    Casts an array to a long array.
    static long[]
    Casts an array to a long array.
    static long[]
    castLong(LongVector values, boolean checkFidelity)
    Casts an array to a long array.
    static long[]
    Casts an array to a long array.
    static long[]
    castLong(ShortVector values, boolean checkFidelity)
    Casts an array to a long array.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • Cast

      public Cast()
  • Method Details

    • castInt

      public static int castInt(byte value, boolean checkFidelity)
      Casts a value to an int.
      Parameters:
      value - value
      checkFidelity - check to see if the cast preserves the value.
      Returns:
      cast value.
    • castInt

      public static int castInt(short value, boolean checkFidelity)
      Casts a value to an int.
      Parameters:
      value - value
      checkFidelity - check to see if the cast preserves the value.
      Returns:
      cast value.
    • castInt

      public static int castInt(int value, boolean checkFidelity)
      Casts a value to an int.
      Parameters:
      value - value
      checkFidelity - check to see if the cast preserves the value.
      Returns:
      cast value.
    • castInt

      public static int castInt(long value, boolean checkFidelity)
      Casts a value to an int.
      Parameters:
      value - value
      checkFidelity - check to see if the cast preserves the value.
      Returns:
      cast value.
    • castLong

      public static long castLong(byte value, boolean checkFidelity)
      Casts a value to a long.
      Parameters:
      value - value
      checkFidelity - check to see if the cast preserves the value.
      Returns:
      cast value.
    • castLong

      public static long castLong(short value, boolean checkFidelity)
      Casts a value to a long.
      Parameters:
      value - value
      checkFidelity - check to see if the cast preserves the value.
      Returns:
      cast value.
    • castLong

      public static long castLong(int value, boolean checkFidelity)
      Casts a value to a long.
      Parameters:
      value - value
      checkFidelity - check to see if the cast preserves the value.
      Returns:
      cast value.
    • castLong

      public static long castLong(long value, boolean checkFidelity)
      Casts a value to a long.
      Parameters:
      value - value
      checkFidelity - check to see if the cast preserves the value.
      Returns:
      cast value.
    • castDouble

      public static double castDouble(byte value, boolean checkFidelity)
      Casts a value to a double.
      Parameters:
      value - value
      checkFidelity - check to see if the cast preserves the value.
      Returns:
      cast value.
    • castDouble

      public static double castDouble(short value, boolean checkFidelity)
      Casts a value to a double.
      Parameters:
      value - value
      checkFidelity - check to see if the cast preserves the value.
      Returns:
      cast value.
    • castDouble

      public static double castDouble(int value, boolean checkFidelity)
      Casts a value to a double.
      Parameters:
      value - value
      checkFidelity - check to see if the cast preserves the value.
      Returns:
      cast value.
    • castDouble

      public static double castDouble(long value, boolean checkFidelity)
      Casts a value to a double.
      Parameters:
      value - value
      checkFidelity - check to see if the cast preserves the value.
      Returns:
      cast value.
    • castDouble

      public static double castDouble(float value, boolean checkFidelity)
      Casts a value to a double.
      Parameters:
      value - value
      checkFidelity - check to see if the cast preserves the value.
      Returns:
      cast value.
    • castDouble

      public static double castDouble(double value, boolean checkFidelity)
      Casts a value to a double.
      Parameters:
      value - value
      checkFidelity - check to see if the cast preserves the value.
      Returns:
      cast value.
    • castInt

      public static int castInt(byte value)
      Casts a value to an int.
      Parameters:
      value - value
      Returns:
      cast value.
    • castInt

      public static int[] castInt(byte... values)
      Casts an array to an int array.
      Parameters:
      values - values
      Returns:
      cast array.
    • castInt

      public static int[] castInt(byte[] values, boolean checkFidelity)
      Casts an array to an int array.
      Parameters:
      values - values
      checkFidelity - check to see if the cast preserves the value.
      Returns:
      cast array.
    • castInt

      public static int[] castInt(ByteVector values)
      Casts an array to an int array.
      Parameters:
      values - values
      Returns:
      cast array.
    • castInt

      public static int[] castInt(ByteVector values, boolean checkFidelity)
      Casts an array to an int array.
      Parameters:
      values - values
      checkFidelity - check to see if the cast preserves the value.
      Returns:
      cast array.
    • castLong

      public static long castLong(byte value)
      Casts a value to a long.
      Parameters:
      value - value
      Returns:
      cast value.
    • castLong

      public static long[] castLong(byte... values)
      Casts an array to a long array.
      Parameters:
      values - values
      Returns:
      cast array.
    • castLong

      public static long[] castLong(byte[] values, boolean checkFidelity)
      Casts an array to a long array.
      Parameters:
      values - values
      checkFidelity - check to see if the cast preserves the value.
      Returns:
      cast array.
    • castLong

      public static long[] castLong(ByteVector values)
      Casts an array to a long array.
      Parameters:
      values - values
      Returns:
      cast array.
    • castLong

      public static long[] castLong(ByteVector values, boolean checkFidelity)
      Casts an array to a long array.
      Parameters:
      values - values
      checkFidelity - check to see if the cast preserves the value.
      Returns:
      cast array.
    • castDouble

      public static double castDouble(byte value)
      Casts a value to a double.
      Parameters:
      value - value
      Returns:
      cast value.
    • castDouble

      public static double[] castDouble(byte... values)
      Casts an array to a double array.
      Parameters:
      values - values
      Returns:
      cast array.
    • castDouble

      public static double[] castDouble(byte[] values, boolean checkFidelity)
      Casts an array to a double array.
      Parameters:
      values - values
      checkFidelity - check to see if the cast preserves the value.
      Returns:
      cast array.
    • castDouble

      public static double[] castDouble(ByteVector values)
      Casts an array to a double array.
      Parameters:
      values - values
      Returns:
      cast array.
    • castDouble

      public static double[] castDouble(ByteVector values, boolean checkFidelity)
      Casts an array to a double array.
      Parameters:
      values - values
      checkFidelity - check to see if the cast preserves the value.
      Returns:
      cast array.
    • castInt

      public static int castInt(short value)
      Casts a value to an int.
      Parameters:
      value - value
      Returns:
      cast value.
    • castInt

      public static int[] castInt(short... values)
      Casts an array to an int array.
      Parameters:
      values - values
      Returns:
      cast array.
    • castInt

      public static int[] castInt(short[] values, boolean checkFidelity)
      Casts an array to an int array.
      Parameters:
      values - values
      checkFidelity - check to see if the cast preserves the value.
      Returns:
      cast array.
    • castInt

      public static int[] castInt(ShortVector values)
      Casts an array to an int array.
      Parameters:
      values - values
      Returns:
      cast array.
    • castInt

      public static int[] castInt(ShortVector values, boolean checkFidelity)
      Casts an array to an int array.
      Parameters:
      values - values
      checkFidelity - check to see if the cast preserves the value.
      Returns:
      cast array.
    • castLong

      public static long castLong(short value)
      Casts a value to a long.
      Parameters:
      value - value
      Returns:
      cast value.
    • castLong

      public static long[] castLong(short... values)
      Casts an array to a long array.
      Parameters:
      values - values
      Returns:
      cast array.
    • castLong

      public static long[] castLong(short[] values, boolean checkFidelity)
      Casts an array to a long array.
      Parameters:
      values - values
      checkFidelity - check to see if the cast preserves the value.
      Returns:
      cast array.
    • castLong

      public static long[] castLong(ShortVector values)
      Casts an array to a long array.
      Parameters:
      values - values
      Returns:
      cast array.
    • castLong

      public static long[] castLong(ShortVector values, boolean checkFidelity)
      Casts an array to a long array.
      Parameters:
      values - values
      checkFidelity - check to see if the cast preserves the value.
      Returns:
      cast array.
    • castDouble

      public static double castDouble(short value)
      Casts a value to a double.
      Parameters:
      value - value
      Returns:
      cast value.
    • castDouble

      public static double[] castDouble(short... values)
      Casts an array to a double array.
      Parameters:
      values - values
      Returns:
      cast array.
    • castDouble

      public static double[] castDouble(short[] values, boolean checkFidelity)
      Casts an array to a double array.
      Parameters:
      values - values
      checkFidelity - check to see if the cast preserves the value.
      Returns:
      cast array.
    • castDouble

      public static double[] castDouble(ShortVector values)
      Casts an array to a double array.
      Parameters:
      values - values
      Returns:
      cast array.
    • castDouble

      public static double[] castDouble(ShortVector values, boolean checkFidelity)
      Casts an array to a double array.
      Parameters:
      values - values
      checkFidelity - check to see if the cast preserves the value.
      Returns:
      cast array.
    • castInt

      public static int castInt(int value)
      Casts a value to an int.
      Parameters:
      value - value
      Returns:
      cast value.
    • castInt

      public static int[] castInt(int... values)
      Casts an array to an int array.
      Parameters:
      values - values
      Returns:
      cast array.
    • castInt

      public static int[] castInt(int[] values, boolean checkFidelity)
      Casts an array to an int array.
      Parameters:
      values - values
      checkFidelity - check to see if the cast preserves the value.
      Returns:
      cast array.
    • castInt

      public static int[] castInt(IntVector values)
      Casts an array to an int array.
      Parameters:
      values - values
      Returns:
      cast array.
    • castInt

      public static int[] castInt(IntVector values, boolean checkFidelity)
      Casts an array to an int array.
      Parameters:
      values - values
      checkFidelity - check to see if the cast preserves the value.
      Returns:
      cast array.
    • castLong

      public static long castLong(int value)
      Casts a value to a long.
      Parameters:
      value - value
      Returns:
      cast value.
    • castLong

      public static long[] castLong(int... values)
      Casts an array to a long array.
      Parameters:
      values - values
      Returns:
      cast array.
    • castLong

      public static long[] castLong(int[] values, boolean checkFidelity)
      Casts an array to a long array.
      Parameters:
      values - values
      checkFidelity - check to see if the cast preserves the value.
      Returns:
      cast array.
    • castLong

      public static long[] castLong(IntVector values)
      Casts an array to a long array.
      Parameters:
      values - values
      Returns:
      cast array.
    • castLong

      public static long[] castLong(IntVector values, boolean checkFidelity)
      Casts an array to a long array.
      Parameters:
      values - values
      checkFidelity - check to see if the cast preserves the value.
      Returns:
      cast array.
    • castDouble

      public static double castDouble(int value)
      Casts a value to a double.
      Parameters:
      value - value
      Returns:
      cast value.
    • castDouble

      public static double[] castDouble(int... values)
      Casts an array to a double array.
      Parameters:
      values - values
      Returns:
      cast array.
    • castDouble

      public static double[] castDouble(int[] values, boolean checkFidelity)
      Casts an array to a double array.
      Parameters:
      values - values
      checkFidelity - check to see if the cast preserves the value.
      Returns:
      cast array.
    • castDouble

      public static double[] castDouble(IntVector values)
      Casts an array to a double array.
      Parameters:
      values - values
      Returns:
      cast array.
    • castDouble

      public static double[] castDouble(IntVector values, boolean checkFidelity)
      Casts an array to a double array.
      Parameters:
      values - values
      checkFidelity - check to see if the cast preserves the value.
      Returns:
      cast array.
    • castInt

      public static int castInt(long value)
      Casts a value to an int.
      Parameters:
      value - value
      Returns:
      cast value.
    • castInt

      public static int[] castInt(long... values)
      Casts an array to an int array.
      Parameters:
      values - values
      Returns:
      cast array.
    • castInt

      public static int[] castInt(long[] values, boolean checkFidelity)
      Casts an array to an int array.
      Parameters:
      values - values
      checkFidelity - check to see if the cast preserves the value.
      Returns:
      cast array.
    • castInt

      public static int[] castInt(LongVector values)
      Casts an array to an int array.
      Parameters:
      values - values
      Returns:
      cast array.
    • castInt

      public static int[] castInt(LongVector values, boolean checkFidelity)
      Casts an array to an int array.
      Parameters:
      values - values
      checkFidelity - check to see if the cast preserves the value.
      Returns:
      cast array.
    • castLong

      public static long castLong(long value)
      Casts a value to a long.
      Parameters:
      value - value
      Returns:
      cast value.
    • castLong

      public static long[] castLong(long... values)
      Casts an array to a long array.
      Parameters:
      values - values
      Returns:
      cast array.
    • castLong

      public static long[] castLong(long[] values, boolean checkFidelity)
      Casts an array to a long array.
      Parameters:
      values - values
      checkFidelity - check to see if the cast preserves the value.
      Returns:
      cast array.
    • castLong

      public static long[] castLong(LongVector values)
      Casts an array to a long array.
      Parameters:
      values - values
      Returns:
      cast array.
    • castLong

      public static long[] castLong(LongVector values, boolean checkFidelity)
      Casts an array to a long array.
      Parameters:
      values - values
      checkFidelity - check to see if the cast preserves the value.
      Returns:
      cast array.
    • castDouble

      public static double castDouble(long value)
      Casts a value to a double.
      Parameters:
      value - value
      Returns:
      cast value.
    • castDouble

      public static double[] castDouble(long... values)
      Casts an array to a double array.
      Parameters:
      values - values
      Returns:
      cast array.
    • castDouble

      public static double[] castDouble(long[] values, boolean checkFidelity)
      Casts an array to a double array.
      Parameters:
      values - values
      checkFidelity - check to see if the cast preserves the value.
      Returns:
      cast array.
    • castDouble

      public static double[] castDouble(LongVector values)
      Casts an array to a double array.
      Parameters:
      values - values
      Returns:
      cast array.
    • castDouble

      public static double[] castDouble(LongVector values, boolean checkFidelity)
      Casts an array to a double array.
      Parameters:
      values - values
      checkFidelity - check to see if the cast preserves the value.
      Returns:
      cast array.
    • castDouble

      public static double castDouble(float value)
      Casts a value to a double.
      Parameters:
      value - value
      Returns:
      cast value.
    • castDouble

      public static double[] castDouble(float... values)
      Casts an array to a double array.
      Parameters:
      values - values
      Returns:
      cast array.
    • castDouble

      public static double[] castDouble(float[] values, boolean checkFidelity)
      Casts an array to a double array.
      Parameters:
      values - values
      checkFidelity - check to see if the cast preserves the value.
      Returns:
      cast array.
    • castDouble

      public static double[] castDouble(FloatVector values)
      Casts an array to a double array.
      Parameters:
      values - values
      Returns:
      cast array.
    • castDouble

      public static double[] castDouble(FloatVector values, boolean checkFidelity)
      Casts an array to a double array.
      Parameters:
      values - values
      checkFidelity - check to see if the cast preserves the value.
      Returns:
      cast array.
    • castDouble

      public static double castDouble(double value)
      Casts a value to a double.
      Parameters:
      value - value
      Returns:
      cast value.
    • castDouble

      public static double[] castDouble(double... values)
      Casts an array to a double array.
      Parameters:
      values - values
      Returns:
      cast array.
    • castDouble

      public static double[] castDouble(double[] values, boolean checkFidelity)
      Casts an array to a double array.
      Parameters:
      values - values
      checkFidelity - check to see if the cast preserves the value.
      Returns:
      cast array.
    • castDouble

      public static double[] castDouble(DoubleVector values)
      Casts an array to a double array.
      Parameters:
      values - values
      Returns:
      cast array.
    • castDouble

      public static double[] castDouble(DoubleVector values, boolean checkFidelity)
      Casts an array to a double array.
      Parameters:
      values - values
      checkFidelity - check to see if the cast preserves the value.
      Returns:
      cast array.