Class ParameterCheck
java.lang.Object
org.alfresco.rest.rm.community.util.ParameterCheck
Utility class for checking parameters
- Since:
- 2.6
- Author:
- Tuna Aksoy
-
Method Summary
Modifier and TypeMethodDescriptionstatic voidmandatoryObject(String paramName, Object object) Checks if a givenObjectis null or notstatic voidmandatoryString(String paramName, String paramValue) Checks if a givenStringis blank or not, i.e.
-
Method Details
-
mandatoryString
public static void mandatoryString(String paramName, String paramValue) throws IllegalArgumentException Checks if a givenStringis blank or not, i.e. notnull, "" or " ".- Parameters:
paramName- The name of the parameter to checkparamValue- The value of the parameter to check- Throws:
IllegalArgumentException- Throws an exception if the given value is blank
-
mandatoryObject
Checks if a givenObjectis null or not- Parameters:
paramName- The name of the parameter to checkobject- The value of the parameter to check- Throws:
IllegalArgumentException- Throws an exception if the given value is null
-