Here you can find the source of fromInt(byte[] buffer, int pos, int i)
public static int fromInt(byte[] buffer, int pos, int i)
//package com.java2s; //License from project: Apache License public class Main { public static int fromInt(byte[] buffer, int pos, int i) { buffer[pos] = (byte) (i >> 24); buffer[pos + 1] = (byte) ((i >> 16) & 255); buffer[pos + 2] = (byte) ((i >> 8) & 255); buffer[pos + 3] = (byte) (i & 255); return pos + 4; }//from www .j a va 2 s.c o m }