List of utility methods to do Float to
int | floatToSortableInt(float val) Converts a float value to a sortable signed int .
return sortableFloatBits(Float.floatToIntBits(val)); |
int | floatToSortableInt(float value) Converts a float value to a sortable int. int bits = Float.floatToIntBits(value); return bits ^ (bits >> 31) & Integer.MAX_VALUE; |
String | floatToTime(float aTimeDuration) float To Time long iPart = (long) aTimeDuration; double fPart = aTimeDuration - iPart; String hours = String.valueOf(iPart); String minutes = String.valueOf((long) (fPart * 60)); if (hours.length() == 1) { hours = "0" + hours; if (minutes.length() == 1) { ... |
short | single2short(float f) Converts a Single value to a Short value. return (short) (((long) f << 48) >> 48); |
short | single2short(float f) singleshort return (short) (((long) f << 48) >> 48); |