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. |
errorMessage
Optional
- Type: java.lang.String
results
Optional
- 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. |
errorMessage
Required
public java.lang.String getErrorMessage();
- Type: java.lang.String
isSuccess
Required
public java.lang.Boolean getIsSuccess();
- Type: java.lang.Boolean
results
Required
public ValidationResults getResults();
- Type: ValidationResults