org.qi4j.library.rest.client

## Class ResponseReaderDelegator

- java.lang.Object
- - org.qi4j.library.rest.client.ResponseReaderDelegator

- All Implemented Interfaces:
    Initializable, ResponseReader

      public class ResponseReaderDelegator
      extends Object
      implements ResponseReader, Initializable

  Delegates to a list of potential readers. Register readers on startup.

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `ResponseReaderDelegator()`

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `void` | `initialize()` Initialize the fragment
    `Object` | `readResponse(org.restlet.Response response, Class<?> resultType)`
    `void` | `registerResponseReader(ResponseReader reader)`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

    - #### ResponseReaderDelegator

          public ResponseReaderDelegator()

  - ### Method Detail

    - #### initialize

          public void initialize()
                          throws InitializationException

      Description copied from interface: `Initializable`
      Initialize the fragment
      Specified by:
        `initialize` in interface `Initializable`
      Throws:
        `InitializationException` - if something went wrong

    - #### registerResponseReader

          public void registerResponseReader(ResponseReader reader)

    - #### readResponse

          public Object readResponse(org.restlet.Response response,
                            Class<?> resultType)

      Specified by:
        `readResponse` in interface `ResponseReader`