ValidationResult
Representation of validation results.
Models a tree of validation errors so that we have as much information as possible about the failure that occurred.
Initializers
import com.aliyun.ros.cdk.core.ValidationResult;
new ValidationResult();,new ValidationResult(java.lang.String errorMessage);,new ValidationResult(java.lang.String errorMessage, ValidationResults results);
| Name | Type | Description |
|---|---|---|
errorMessage |
java.lang.String |
No description. |
results |
ValidationResults |
No description. |
errorMessageOptional
- Type: java.lang.String
resultsOptional
- Type: ValidationResults
Methods
| Name | Description |
|---|---|
assertSuccess |
Turn a failed validation into an exception. |
errorTree |
Return a string rendering of the tree of validation failures. |
prefix |
Wrap this result with an error message, if it concerns an error. |
assertSuccess
public void assertSuccess()
Turn a failed validation into an exception.
errorTree
public java.lang.String errorTree()
Return a string rendering of the tree of validation failures.
prefix
public ValidationResult prefix(java.lang.String message)
Wrap this result with an error message, if it concerns an error.
- Type: java.lang.String
Properties
| Name | Type | Description |
|---|---|---|
errorMessage |
java.lang.String |
No description. |
isSuccess |
java.lang.Boolean |
No description. |
results |
ValidationResults |
No description. |
errorMessageRequired
public java.lang.String getErrorMessage();
- Type: java.lang.String
isSuccessRequired
public java.lang.Boolean getIsSuccess();
- Type: java.lang.Boolean
resultsRequired
public ValidationResults getResults();
- Type: ValidationResults