Interface TypedMessageBodyReader<T>

Type Parameters:
T - The type
All Superinterfaces:
MessageBodyReader<T>
All Known Subinterfaces:
TypedMessageBodyHandler<T>
All Known Implementing Classes:
StringBodyReader, TextPlainObjectBodyReader, WritableBodyWriter

public interface TypedMessageBodyReader<T> extends MessageBodyReader<T>
A body reader MessageBodyReader with a type argument.
Since:
4.6
  • Method Summary

    Modifier and Type
    Method
    Description
    @NonNull io.micronaut.core.type.Argument<T>
     
    default boolean
    isReadable(io.micronaut.core.type.Argument<T> type, MediaType mediaType)
    Is the type readable.

    Methods inherited from interface io.micronaut.http.body.MessageBodyReader

    read, read
  • Method Details

    • getType

      @NonNull @NonNull io.micronaut.core.type.Argument<T> getType()
      Returns:
      The body type.
    • isReadable

      default boolean isReadable(io.micronaut.core.type.Argument<T> type, MediaType mediaType)
      Description copied from interface: MessageBodyReader
      Is the type readable.
      Specified by:
      isReadable in interface MessageBodyReader<T>
      Parameters:
      type - The type
      mediaType - The media type, can be null
      Returns:
      True if is readable