public class ConvertResult extends Object
DefaultTypeConverter
but may be
generally useful for implementing custom TypeConverter
implementations or extending the DefaultTypeConverterModifier and Type | Field and Description |
---|---|
static ConvertResult |
FAILURE
Special constant instance used to indicate failure
|
Constructor and Description |
---|
ConvertResult(Object value)
Creates a new conversion result that indicates success
|
ConvertResult(Throwable cause) |
Modifier and Type | Method and Description |
---|---|
Throwable |
getCause()
Gets the cause if available
|
Object |
getConvertedValue()
The converted value
|
boolean |
hasCause()
Gets whether a cause is available
|
boolean |
wasSuccessfull()
Whether the conversion was successful
|
public static final ConvertResult FAILURE
public ConvertResult(Object value)
value
- Converted valuepublic ConvertResult(Throwable cause)
public boolean wasSuccessfull()
public Object getConvertedValue()
public boolean hasCause()
public Throwable getCause()
null
if none availableCopyright © 2012–2017. All rights reserved.