private int convertBinaryFloatToInt(byte[] data){
  if (data == null || data.length != 4)   return 0x0;
  int value;
  if ((0x80 & data[0]) == 0x80) {
    value=((0x7f & data[0]) << 24 | (0xff & data[1]) << 16 | (0xff & data[2]) << 8 | (0xff & data[3]));
  }
 else {
    value=~(((0xff & data[0]) << 24 | (0xff & data[1]) << 16 | (0xff & data[2]) << 8 | (0xff & data[3])));
  }
  return value;
}

private int convertBinaryFloatToInt ( byte [ ] data ) { if ( data == null || data . length != 4 ) return 0x0 ; int value ; if ( ( 0x80 & data [ 0 ] ) == 0x80 ) { value = ( ( 0x7f & data [ 0 ] ) << 24 | ( 0xff & data [ 1 ] ) << 16 | ( 0xff & data [ 2 ] ) << 8 | ( 0xff & data [ 3 ] ) ) ; } else { value = ~ ( ( ( 0xff & data [ 0 ] ) << 24 | ( 0xff & data [ 1 ] ) << 16 | ( 0xff & data [ 2 ] ) << 8 | ( 0xff & data [ 3 ] ) ) ) ; } return value ; }
converts the byte array into a 32 bit integer , which is ieee 754 compliant . conversion is done as follows : if the first bit is 1 , this will be interpreted as a positive number , just replacing this first bit by 0 ( which indicates a positive number in ieee754 ) . if the first bit is 0 , then the result will be the ones complement of the byte array .
