Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.apache.tapestry5.ioc.internal
Interface TypeCoercerProxy

All Known Implementing Classes:
  TypeCoercerProxyImpl

    public interface TypeCoercerProxy

A simplified version of `TypeCoercer` used to defer the instantiation of the actual TypeCoercer service until necessary.

Since:
  5.3

Method Summary
`
`<S,T> T`
` | `coerce(S input, java.lang.Class<T> targetType)` Returns input cast to targetType if input is an instance of target type, otherwise delegates to `TypeCoercer.coerce(Object, Class)`.

Method Detail

### coerce

    <S,T> T coerce(S input,
                   java.lang.Class<T> targetType)

  Returns input cast to targetType if input is an instance of target type, otherwise delegates to `TypeCoercer.coerce(Object, Class)`.

  Type Parameters:
    `S` -
    `T` -
  Parameters:
    `input` - value to be coerced
    `targetType` - desired type of value
  Returns:
    the value, coerced
  Throws:
    `java.lang.RuntimeException` - if the input can not be coerced

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2003-2012 The Apache Software Foundation.