Package com.bc.ceres.binio.util
Class NumberUtils
- java.lang.Object
-
- com.bc.ceres.binio.util.NumberUtils
-
public class NumberUtils extends Object
Utility class.
-
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static NumbergetNumericMember(CompoundData compoundData, int memberIndex)Returns the numeric value of a compound member, which is of aSimpleType.static Class<? extends Number>getNumericMemberType(CompoundType compoundData, int memberIndex)Returns the numeric type of a compound member, which is of aSimpleType.
-
-
-
Method Detail
-
getNumericMember
public static Number getNumericMember(CompoundData compoundData, int memberIndex) throws IOException
Returns the numeric value of a compound member, which is of aSimpleType.- Parameters:
compoundData- the compound.memberIndex- the index of the compound member of interest.- Returns:
- the numeric value of the compound member of interest, or
nullif the compound member is not of aSimpleType. - Throws:
IOException- if an I/O error occurred.
-
getNumericMemberType
public static Class<? extends Number> getNumericMemberType(CompoundType compoundData, int memberIndex)
Returns the numeric type of a compound member, which is of aSimpleType.- Parameters:
compoundData- the compound.memberIndex- the index of the compound member of interest.- Returns:
- the numeric type of the compound member of interest, or
nullif the compound member is not of aSimpleType.
-
-