Here you can find the source of subarray(byte[] b, int ofs, int len)
public static byte[] subarray(byte[] b, int ofs, int len)
//package com.java2s; //License from project: Apache License public class Main { public static byte[] subarray(byte[] b, int ofs, int len) { byte[] out = new byte[len]; System.arraycopy(b, ofs, out, 0, len); return out; }/*from ww w. j a va2 s .c om*/ }