package org.jrivets.util;

public final class CheckUtils extends StaticSingleton {

    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);
        } 
    }
    
}

@@ -376,10 +376,703 @@
  %7D%0A    %0A
+    public static void notNull(Object o1) %7B%0A        if (o1 == null) %7B%0A            throw new NullPointerException();%0A        %7D%0A    %7D%0A    %0A    public static void notNull(Object o1, Object o2) %7B%0A        if (o1 == null %7C%7C o2 == null) %7B%0A            throw new NullPointerException();%0A        %7D%0A    %7D%0A    %0A    public static void notNull(Object o1, Object o2, Object o3) %7B%0A        if (o1 == null %7C%7C o2 == null %7C%7C o3 == null) %7B%0A            throw new NullPointerException();%0A        %7D%0A    %7D%0A    %0A    public static void notNull(Object o1, Object o2, Object o3, Object o4) %7B%0A        if (o1 == null %7C%7C o2 == null %7C%7C o3 == null %7C%7C o4 == null) %7B%0A            throw new NullPointerException();%0A        %7D%0A    %7D%0A
 %7D%0A

check for nulls