public class DurationInput extends ParseAbstractInput<Duration> implements FormatHintInput
Duration
in HH:mm::ss format.ElapsedSecondInput
![]() |
![]() |
validators
Constructor and Description |
---|
DurationInput() |
DurationInput(long resolution)
Constructor with custom resolution
|
Modifier and Type | Method and Description |
---|---|
Duration |
convert(java.lang.Object v)
Perform any supported type conversions to to generate a value of the
target type
|
java.lang.String |
getFormatHint() |
java.lang.String |
getString(Duration val)
get a String representation of an Object that is compatible with the way
the input is parsed
|
Duration |
parseValue(java.lang.String v)
Parse a String into the correct type for this input.
|
accept, getBoxWidth, getMaxResultLength, getSingle, setBoxWidth, setMaxResultLength, setSingle
getValue, setKey, setValue
addValidator, getKey, getPrettyString, getString, removeValidator, validate, validateInner
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getString, parse
addValidator, getKey, getPrettyString, getValue, isEmpty, removeValidator, setKey, setValue, validate
public DurationInput()
public DurationInput(long resolution)
resolution
- default resolution when converting from numberspublic Duration parseValue(java.lang.String v) throws ParseException
ParseInput
Input.getString(Object)
method.parseValue
in interface ParseInput<Duration>
ParseException
public java.lang.String getString(Duration val)
BaseInput
public java.lang.String getFormatHint()
getFormatHint
in interface FormatHintInput