Class TextPlainMessageSerializer

    • Constructor Detail

      • TextPlainMessageSerializer

        public TextPlainMessageSerializer()
    • Method Detail

      • serializeResponseAsBinary

        public io.netty.buffer.ByteBuf serializeResponseAsBinary​(ResponseMessage responseMessage,
                                                                 io.netty.buffer.ByteBufAllocator allocator)
        Description copied from interface: MessageSerializer
        Serialize a ResponseMessage to a Netty ByteBuf.
        Parameters:
        responseMessage - The response message to serialize to bytes.
        allocator - The Netty allocator for the ByteBuf to return back.
      • writeHeader

        public io.netty.buffer.ByteBuf writeHeader​(ResponseMessage responseMessage,
                                                   io.netty.buffer.ByteBufAllocator allocator)
      • writeChunk

        public io.netty.buffer.ByteBuf writeChunk​(Object aggregate,
                                                  io.netty.buffer.ByteBufAllocator allocator)
      • writeFooter

        public io.netty.buffer.ByteBuf writeFooter​(ResponseMessage responseMessage,
                                                   io.netty.buffer.ByteBufAllocator allocator)
      • writeErrorFooter

        public io.netty.buffer.ByteBuf writeErrorFooter​(ResponseMessage responseMessage,
                                                        io.netty.buffer.ByteBufAllocator allocator)
      • readChunk

        public ResponseMessage readChunk​(io.netty.buffer.ByteBuf byteBuf,
                                         boolean isFirstChunk)
      • serializeRequestAsBinary

        public io.netty.buffer.ByteBuf serializeRequestAsBinary​(RequestMessage requestMessage,
                                                                io.netty.buffer.ByteBufAllocator allocator)
        Description copied from interface: MessageSerializer
        Serialize a ResponseMessage to a Netty ByteBuf.
        Parameters:
        requestMessage - The request message to serialize to bytes.
        allocator - The Netty allocator for the ByteBuf to return back.
      • mimeTypesSupported

        public String[] mimeTypesSupported()
        Description copied from interface: MessageSerializer
        The list of mime types that the serializer supports. They should be ordered in preferred ordered where the greatest fidelity match is first.