public static void assertNotNull ( final Object object , final String message ) { if ( object == null ) { throw new NullPointerException ( message == null ? "Object is null" : message ) ; } }
Check that an object is null and throw NullPointerException in the case .