Modifier and Type | Method and Description |
---|---|
Promise<Result,NeverThrowsException> |
asPromise()
Returns a new completed promise wrapping this result.
|
static Result |
failure(String description)
Returns a
Result representing validation failure. |
String |
getDescription()
Returns the failure description (
null if this is a success). |
boolean |
isFailure()
Returns
true if this Result is a failure, false otherwise. |
boolean |
isSuccess()
Returns
true if this Result is a success, false otherwise. |
static Result |
success()
Returns a
Result representing validation success. |
public static Result success()
Result
representing validation success.public static Result failure(String description)
Result
representing validation failure.description
- The description of this failure, not null
.public boolean isSuccess()
true
if this Result is a success, false
otherwise.true
if this Result is a success, false
otherwise.public boolean isFailure()
true
if this Result is a failure, false
otherwise.true
if this Result is a failure, false
otherwise.public String getDescription()
null
if this is a success).null
if this is a success).public Promise<Result,NeverThrowsException> asPromise()
Copyright 2011-2017 ForgeRock AS.