Here you can find the source of arrayBounds(int arrayLength, int offset, int length)
public static void arrayBounds(int arrayLength, int offset, int length)
//package com.java2s; //License from project: Apache License public class Main { public static void arrayBounds(int arrayLength, int offset, int length) { if (offset < 0 || length < 0 || length > arrayLength - offset) { throw new IndexOutOfBoundsException( "array.length=" + arrayLength + ", offset=" + offset + ", length=" + length); }/* ww w .j a va 2 s . c o m*/ } }