Android examples for java.nio:ByteBuffer
convert Byte Array To Int Array using ByteBuffer
//package com.java2s; import java.nio.ByteBuffer; public class Main { public static void convertByteArrayToIntArray(byte[] in, int[] out) { ByteBuffer byteb = ByteBuffer.wrap(in); for (int i = 0; i < out.length; ++i) { out[i] = byteb.getInt();//w w w.j a v a 2 s . c o m } } }