|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.atlassian.validation.Success
public final class Success
Basic implementation of a successful validation result that takes an instance of the value object to be returned as the valid instance.
Constructor Summary | |
---|---|
Success(String value)
|
Method Summary | |
---|---|
String |
get()
If valid returns the value in string form. |
String |
getErrorMessage()
If validation failed, the reason is found here in plain text. |
String |
getErrorMessageHtml()
If validation failed, the reason is found here in html. |
boolean |
isValid()
Whether the validation succeeded. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public Success(String value)
Method Detail |
---|
public boolean isValid()
Validator.Result
isValid
in interface Validator.Result
public String getErrorMessage()
Validator.Result
getErrorMessage
in interface Validator.Result
public String getErrorMessageHtml()
Validator.Result
getErrorMessageHtml
in interface Validator.Result
public String get() throws IllegalStateException
Validator.Result
get
in interface Validator.Result
IllegalStateException
- if the result is not valid.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |