Java tutorial
//package com.java2s; public class Main { public static byte[] getCopyByteArray(byte[] src, int start, int length) { byte[] dest = new byte[length]; System.arraycopy(src, start, dest, 0, length); return dest; } }