Package org.apache.tapestry5.http.internal

# Class TypeCoercerHttpRequestBodyConverter

java.lang.Object
org.apache.tapestry5.http.internal.TypeCoercerHttpRequestBodyConverter

All Implemented Interfaces:
  `HttpRequestBodyConverter`

public final class TypeCoercerHttpRequestBodyConverter extends Object implements HttpRequestBodyConverter

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `TypeCoercerHttpRequestBodyConverter(TypeCoercer typeCoercer)`

- ## Method Summary

  Modifier and Type
  Method
  Description
  `<T> T`
  `convert(javax.servlet.http.HttpServletRequest request, Class<T> type)`
  Converts the body of this request.

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

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

- ## Constructor Details

  - ### TypeCoercerHttpRequestBodyConverter

    public TypeCoercerHttpRequestBodyConverter(TypeCoercer typeCoercer)

- ## Method Details

  - ### convert

    public <T> T convert(javax.servlet.http.HttpServletRequest request, Class<T> type)
    Description copied from interface: `HttpRequestBodyConverter`
    Converts the body of this request. If this implementation cannot handle this request, probably by not handling its content type, it should return `null`. In addition, if the request body is empty, this method should also return `null`.
    Specified by:
      `convert` in interface `HttpRequestBodyConverter`
    Parameters:
      `request` - an HttpServletRequest.
      `type` - the target type.
    Returns:
      an object of the target type or `null`.