public class DblType extends BaseValueType<Double>
Double type.
This class is threadsafe and uses a singleton pattern to prevent multiple instances, since all users can safely share the same instance.
clazzType| Modifier and Type | Method and Description |
|---|---|
Double |
cast(Object o)
Attempt to cast the passed object to the generic type T.
|
static DblType |
get()
Deprecated.
since 0.4.1. Use
instance() instead |
static DblType |
instance() |
Double |
parse(String sourceValue)
Parses a String to a
Double. |
getDestinationType, isParsable, toString@Deprecated public static DblType get()
instance() insteadDblType()public Double parse(String sourceValue) throws ParsingException
Double. The String should already be trimmed.
Parsing is done via Double.parseDouble(String).
sourceValue - The source string, which should already be trimmed and may be nullParsingException - if unparsable.public Double cast(Object o) throws RuntimeException
ValueTypeRuntimeExceptionCopyright © 2021. All rights reserved.