Package org.joda.time.convert
Interface IntervalConverter
- All Superinterfaces:
Converter
IntervalConverter defines how an object is converted to an interval.
- Since:
- 1.0
- Author:
- Brian S O'Neill, Stephen Colebourne
-
Method Summary
Modifier and TypeMethodDescriptionbooleanisReadableInterval(Object object, Chronology chrono) Checks if the input is a ReadableInterval.voidsetInto(ReadWritableInterval writableInterval, Object object, Chronology chrono) Extracts interval endpoint values from an object of this converter's type, and sets them into the given ReadWritableInterval.Methods inherited from interface org.joda.time.convert.Converter
getSupportedType
-
Method Details
-
isReadableInterval
Checks if the input is a ReadableInterval.If it is, then the calling code should cast and copy the fields directly.
- Parameters:
object- the object to convert, must not be nullchrono- the chronology to use, may be null- Returns:
- true if the input is a ReadableInterval
- Throws:
ClassCastException- if the object is invalid
-
setInto
Extracts interval endpoint values from an object of this converter's type, and sets them into the given ReadWritableInterval.- Parameters:
writableInterval- interval to get modified, not nullobject- the object to convert, must not be nullchrono- the chronology to use, may be null- Throws:
ClassCastException- if the object is invalid
-