public static int toInt(byte[] bytes, int offset) {
    return toInt(bytes, offset, SIZEOF_INT);
  }
Converts a byte array to an int value
@param bytes  byte array
@param offset offset into array
@return the int value
hbase-common/src/main/java/org/apache/hadoop/hbase/util/Bytes.java