@SuppressWarnings("OverloadedVarargsMethod") static <T>T checkNotNull(final T reference,@NonNls final String errorMessage,@NonNls final Object... args){
  if (reference == null) {
    throw new NullPointerException(String.format(errorMessage,args));
  }
  return reference;
}

@ SuppressWarnings ( "OverloadedVarargsMethod" ) static < T > T checkNotNull ( final T reference , @ NonNls final String errorMessage , @ NonNls final Object ... args ) { if ( reference == null ) { throw new NullPointerException ( String . format ( errorMessage , args ) ) ; } return reference ; }
ensures that an object reference passed as a parameter to the calling method is not null .
