cynosurex.legacy
Class VAX_Float

java.lang.Object
  extended by cynosurex.legacy.VAX_Float
All Implemented Interfaces:
cynosurex.internal.AuthorCommon, cynosurex.internal.CommonInterface, cynosurex.internal.CompanyCommon

public class VAX_Float
extends java.lang.Object
implements cynosurex.internal.CommonInterface

This class includes static methods to read and convert various VAX float format. This class cannot be instantiated.


Field Summary
 
Fields inherited from interface cynosurex.internal.CommonInterface
copyright, copyrightYears, notice, program, version
 
Fields inherited from interface cynosurex.internal.AuthorCommon
author, copyrightSymbol, noticeMsg, rights
 
Fields inherited from interface cynosurex.internal.CompanyCommon
company, email, website
 
Method Summary
static double D_float_to_double(byte[] d_float)
          This static method takes in a VAX D-Float and returns a Java double-precision floating point.
static float F_float_to_float(byte[] f_float)
          This static method takes in a VAX F-Float and returns a Java 32-bit floating point.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

F_float_to_float

public static float F_float_to_float(byte[] f_float)
This static method takes in a VAX F-Float and returns a Java 32-bit floating point. This method throws IndexOutOfBoundsException if the length of the array is not 4 bytes (32 bits). It also throws ReservedOperandException if the biased exponent is 0 and the sign bit is 1.

Parameters:
f_float - VAX F-Float bits

D_float_to_double

public static double D_float_to_double(byte[] d_float)
This static method takes in a VAX D-Float and returns a Java double-precision floating point. This method throws IndexOutOfBoundsException if the length of the array is not 8 bytes (64 bits). It also throws ReservedOperandException if the biased exponent is 0 and the sign bit is 1.

Parameters:
d_float - VAX D-Float bits