public class InputValidator extends Object
| Constructor and Description |
|---|
InputValidator() |
| Modifier and Type | Method and Description |
|---|---|
static void |
validateGUIDNotNull(String className,
String methodName,
String guid,
String guidParameter)
Throw an exception if the supplied guid is null
|
static void |
validateNameNotNull(String className,
String methodName,
String name,
String nameParameter)
Throw an exception if the supplied userId is null
|
static void |
validateOMASServerURLNotNull(String className,
String methodName,
String omasServerURL)
Throw an exception if a org.odpi.openmetadata.accessservices.subjectarea.server URL has not been supplied on the constructor.
|
static Status |
validateStatusAndCheckNotDeleted(String className,
String methodName,
String statusName)
Validate the supplied string can be converted to a Status and return that status.
|
static void |
validateUserIdNotNull(String className,
String methodName,
String userId)
Throw an exception if the supplied userId is null
|
public static void validateOMASServerURLNotNull(String className, String methodName, String omasServerURL) throws InvalidParameterException
className - - name of the class making the call.methodName - - name of the method making the call.omasServerURL - - omas server url.InvalidParameterException - - the org.odpi.openmetadata.accessservices.subjectarea.server URL is not setpublic static void validateUserIdNotNull(String className, String methodName, String userId) throws InvalidParameterException
className - name of the classmethodName - name of the method making the call.userId - user name to validateInvalidParameterException - the userId is nullpublic static Status validateStatusAndCheckNotDeleted(String className, String methodName, String statusName) throws InvalidParameterException
className - - name of the class making the call.methodName - - name of the method making the call.statusName - - the String name to convert to a StatusInvalidParameterException - invalid statuspublic static void validateGUIDNotNull(String className, String methodName, String guid, String guidParameter) throws InvalidParameterException
className - - name of the class making the call.methodName - - name of the method making the call.guid - - unique identifier to validateguidParameter - - name of the parameter that passed the guidInvalidParameterException - - the guid is nullpublic static void validateNameNotNull(String className, String methodName, String name, String nameParameter) throws InvalidParameterException
className - - name of the class making the call.methodName - - name of the method making the call.name - - unique name to validatenameParameter - - name of the parameter that passed the name.InvalidParameterException - - the guid is nullCopyright © 2017–2018 ODPi. All rights reserved.