public final class Result extends Object
Result
of a JWT validation.Modifier and Type | Method and Description |
---|---|
static Result |
failure(Violation violation)
Returns a
Result representing validation failure. |
Violation |
getViolation()
Return the Violation if it is present,
null otherwise. |
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.Violation
.public static Result failure(Violation violation)
Result
representing validation failure.violation
- The Violation responsible 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 Violation getViolation()
null
otherwise.null
otherwise.Copyright 2011-2017 ForgeRock AS.