Here you can find the source of intFromByteArray(final byte[] buf, final int offset)
public static final int intFromByteArray(final byte[] buf, final int offset)
//package com.java2s; //License from project: Apache License public class Main { public static final int intFromByteArray(final byte[] buf, final int offset) { int v = 0; v |= ((((int) buf[offset + 0]) & 0xFF) << 24); v |= ((((int) buf[offset + 1]) & 0xFF) << 16); v |= ((((int) buf[offset + 2]) & 0xFF) << 8); v |= ((((int) buf[offset + 3]) & 0xFF) << 0); return v; }//w w w . j a v a 2s . c om }