Package org.alfresco.util
Class ParameterCheck
- java.lang.Object
-
- org.alfresco.util.ParameterCheck
-
public final class ParameterCheck extends java.lang.Object
Utility class to perform various common parameter checks- Author:
- gavinc
-
-
Constructor Summary
Constructors Constructor Description ParameterCheck()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static void
mandatory(java.lang.String strParamName, java.lang.Object object)
Checks that the parameter with the given name has content i.e.static void
mandatoryCollection(java.lang.String strParamName, java.util.Collection coll)
Checks that the collection parameter contains at least one item.static void
mandatoryString(java.lang.String strParamName, java.lang.String strParamValue)
Checks that the string parameter with the given name has content i.e.
-
-
-
Method Detail
-
mandatory
public static final void mandatory(java.lang.String strParamName, java.lang.Object object)
Checks that the parameter with the given name has content i.e. it is not null- Parameters:
strParamName
- Name of parameter to checkobject
- Value of the parameter to check
-
mandatoryString
public static final void mandatoryString(java.lang.String strParamName, java.lang.String strParamValue)
Checks that the string parameter with the given name has content i.e. it is not null and not zero length- Parameters:
strParamName
- Name of parameter to checkstrParamValue
- Value of the parameter to check
-
mandatoryCollection
public static final void mandatoryCollection(java.lang.String strParamName, java.util.Collection coll)
Checks that the collection parameter contains at least one item.- Parameters:
strParamName
- Name of parameter to checkcoll
- collection to check
-
-