Package org.jboss.shrinkwrap.impl.base
Class Validate
java.lang.Object
org.jboss.shrinkwrap.impl.base.Validate
Validate
Validation utility
- Version:
- $Revision: $
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic voidChecks that object is not null, throws exception if it is.static voidnotNullAndNoNullValues(Object[] objects, String message) Checks that the specified array is not null or contain any null values.static voidnotNullOrEmpty(String string, String message) Checks that the specified String is not null or empty, throws exception if it is.
-
Constructor Details
-
Validate
private Validate()
-
-
Method Details
-
notNull
Checks that object is not null, throws exception if it is.- Parameters:
obj- The object to checkmessage- The exception message- Throws:
IllegalArgumentException- Thrown if obj is null
-
notNullOrEmpty
Checks that the specified String is not null or empty, throws exception if it is.- Parameters:
string- The object to checkmessage- The exception message- Throws:
IllegalArgumentException- Thrown if obj is null
-
notNullAndNoNullValues
Checks that the specified array is not null or contain any null values.- Parameters:
objects- The object to checkmessage- The exception message
-