Package org.cyclos.utils.coercion
Interface Coercer<ToType>
-
- All Known Implementing Classes:
AbstractCoercer,BigDecimalCoercer,BigIntegerCoercer,BooleanCoercer,ByteCoercer,DoubleCoercer,FloatCoercer,IntegerCoercer,LongCoercer,NumberCoercer,ShortCoercer,StringCoercer
public interface Coercer<ToType>Coerces instances of arbitrary types into a specific type
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description ToTypecoerce(Object input)Convert the given object into the coercer type.Class<ToType>getToType()Returns the type this coercer handles
-
-
-
Method Detail
-
coerce
ToType coerce(Object input) throws CoercionException
Convert the given object into the coercer type. The input is assumed to be non-null.- Throws:
CoercionException
-
-