Class EmptyReaderStrategy

    • Constructor Detail

      • EmptyReaderStrategy

        public EmptyReaderStrategy()
    • Method Detail

      • canRead

        public boolean canRead​(@Nullable
                               Class<?> type,
                               @Nullable
                               String contentType)
        Description copied from interface: ReaderStrategy
        Whether the given object type is supported by this reader.
        Specified by:
        canRead in interface ReaderStrategy<Void>
        Parameters:
        type - the type of object to check
        contentType - the content type for the read
        Returns:
        true if readable, false otherwise
      • read

        public Mono<Void> read​(Mono<ByteBuf> content,
                               Class<Void> responseType)
        Description copied from interface: ReaderStrategy
        Read from the input message and encode to a single object.
        Specified by:
        read in interface ReaderStrategy<Void>
        Parameters:
        content - the response contents
        responseType - the type of object in the response which must have been previously checked via ReaderStrategy.canRead(Class, String)
        Returns:
        a Mono for the resolved response, according to the given response type