Here you can find the source of readFloat(ByteBuffer buffer)
public static float readFloat(ByteBuffer buffer)
//package com.java2s; //License from project: LGPL import java.nio.ByteBuffer; public class Main { public static float readFloat(ByteBuffer buffer) { return Float.intBitsToFloat(readInt(buffer)); }/*w w w . ja v a 2s . c o m*/ public static int readInt(ByteBuffer buffer) { int i = buffer.get() & 0xff; i |= (buffer.get() & 0xff) << 8; i |= (buffer.get() & 0xff) << 16; i |= (buffer.get() & 0xff) << 24; return i; } }