Java tutorial
//package com.java2s; public class Main { public static <T> void paramCheck(T t) { if (t == null) { throw new NullPointerException("param is null"); } } }