org.jrdf.util.param
Class ParameterUtil

java.lang.Object
  extended by org.jrdf.util.param.ParameterUtil

public final class ParameterUtil
extends Object

Utility for checking parameters to methods.


Method Summary
static void checkNotEmptyString(String name, String param)
          Checks if param is null or the empty string and throws an exception if it is.
static void checkNotNull(Object... params)
          Checks if params are null or any elements are null.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

checkNotEmptyString

public static void checkNotEmptyString(String name,
                                       String param)
                                throws IllegalArgumentException
Checks if param is null or the empty string and throws an exception if it is.

Parameters:
name - The name of the parameter to check.
param - The parameter to check.
Throws:
IllegalArgumentException - If param is null or the empty string.

checkNotNull

public static void checkNotNull(Object... params)
Checks if params are null or any elements are null.

Parameters:
params - The parameter to check.
Throws:
IllegalArgumentException - If params is null or any elements are null.