public final class ArgUtil extends Object
ArgUtil
Misc. utilities for rudimentary argument validation| Constructor and Description |
|---|
ArgUtil() |
| Modifier and Type | Method and Description |
|---|---|
static void |
assertNotNull(Class nonNullClass,
Object nonNullObject,
Object thisObject)
notNull
|
static void |
assertNotNull(Class nonNullClass,
Object nonNullObject,
Object thisObject,
String methodName) |
static void |
assertPropertyNotNull(Object nonNullObject,
Object thisObject,
String methodName,
String property) |
static void |
notNull(Object[] args,
String[] argNames,
String methodName) |
public static void notNull(Object[] args, String[] argNames, String methodName)
args - array of arguments to validate as not nulargNames - array of arguments names, idexes should match with args.methodName - Name of method we are validating arguments for.IllegalArgumentException - If ANY of the arguments are nullpublic static final void assertNotNull(Class nonNullClass, Object nonNullObject, Object thisObject) throws IllegalArgumentException
notNull
nonNullObject - thisObject - IllegalArgumentExceptionpublic static final void assertNotNull(Class nonNullClass, Object nonNullObject, Object thisObject, String methodName) throws IllegalArgumentException
IllegalArgumentExceptionpublic static final void assertPropertyNotNull(Object nonNullObject, Object thisObject, String methodName, String property) throws IllegalArgumentException
IllegalArgumentExceptionCopyright © 1999–2015 The Apache Software Foundation. All rights reserved.