Package org.jboss.resteasy.core

## Class MessageBodyParameterInjector

- java.lang.Object
- - org.jboss.resteasy.core.MessageBodyParameterInjector

- All Implemented Interfaces:
    `JaxrsInterceptorRegistryListener`, `ValueInjector`

      public class MessageBodyParameterInjector
      extends Object
      implements ValueInjector, JaxrsInterceptorRegistryListener

  Version:
    $Revision: 1 $
  Author:
    Bill Burke

- - ### Constructor Summary

    Constructors
    Constructor | Description
    --- | ---
    `MessageBodyParameterInjector​(Class declaringClass, AccessibleObject target, Class type, Type genericType, Annotation[] annotations, ResteasyProviderFactory factory)` |

  - ### Method Summary

    All Methods Static Methods Instance Methods Concrete Methods
    Modifier and Type | Method | Description
    --- | --- | ---
    `static int` | `bodyCount()` |
    `static void` | `clearBodies()` |
    `static Object` | `getBody()` |
    `protected javax.ws.rs.ext.ReaderInterceptor[]` | `getReaderInterceptors()` |
    `Object` | `inject​(boolean unwrapAsync)` | Inject outside the context of an HTTP request.
    `Object` | `inject​(HttpRequest request, HttpResponse response, boolean unwrapAsync)` | Inject inside the context of an HTTP request.
    `boolean` | `isFormData​(Class<?> type, Type genericType, Annotation[] annotations, javax.ws.rs.core.MediaType mediaType)` |
    `static Object` | `popBody()` |
    `static void` | `pushBody​(Object o)` |
    `void` | `registryUpdated​(JaxrsInterceptorRegistry registry, JaxrsInterceptorRegistry.InterceptorFactory factory)` |

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

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

- - ### Constructor Detail

    - #### MessageBodyParameterInjector

          public MessageBodyParameterInjector​(Class declaringClass,
                                              AccessibleObject target,
                                              Class type,
                                              Type genericType,
                                              Annotation[] annotations,
                                              ResteasyProviderFactory factory)

  - ### Method Detail

    - #### pushBody

          public static void pushBody​(Object o)

    - #### getBody

          public static Object getBody()

    - #### popBody

          public static Object popBody()

    - #### bodyCount

          public static int bodyCount()

    - #### clearBodies

          public static void clearBodies()

    - #### registryUpdated

          public void registryUpdated​(JaxrsInterceptorRegistry registry,
                                      JaxrsInterceptorRegistry.InterceptorFactory factory)

      Specified by:
        `registryUpdated` in interface `JaxrsInterceptorRegistryListener`

    - #### getReaderInterceptors

          protected javax.ws.rs.ext.ReaderInterceptor[] getReaderInterceptors()

    - #### isFormData

          public boolean isFormData​(Class<?> type,
                                    Type genericType,
                                    Annotation[] annotations,
                                    javax.ws.rs.core.MediaType mediaType)

    - #### inject

          public Object inject​(HttpRequest request,
                               HttpResponse response,
                               boolean unwrapAsync)

      Description copied from interface: `ValueInjector`
      Inject inside the context of an HTTP request.
      Specified by:
        `inject` in interface `ValueInjector`
      Parameters:
        `request` - http request
        `response` - http response
        `unwrapAsync` - unwrap async
      Returns:
        object

    - #### inject

          public Object inject​(boolean unwrapAsync)

      Description copied from interface: `ValueInjector`
      Inject outside the context of an HTTP request. For instance, a singleton may have proxiable and injectable jax-rs objects like Request, UriInfo, or HttpHeaders.
      Specified by:
        `inject` in interface `ValueInjector`
      Parameters:
        `unwrapAsync` - unwrap async
      Returns:
        object