Java tutorial
//package com.java2s; //License from project: Apache License public class Main { public static void notNull(Object object, String error) { if (object == null) throw new RuntimeException(error); } }