- Type Parameters:
T- type of entity
public interface EntityWriter<T>
Writer of entity into bytes.
-
Method Summary
Modifier and TypeMethodDescriptionvoidwrite(GenericType<T> type, T object, OutputStream outputStream, Headers requestHeaders, WritableHeaders<?> responseHeaders) Write server response entity and close the stream.voidwrite(GenericType<T> type, T object, OutputStream outputStream, WritableHeaders<?> headers) Write client request entity and close the stream.
-
Method Details
-
write
void write(GenericType<T> type, T object, OutputStream outputStream, Headers requestHeaders, WritableHeaders<?> responseHeaders) Write server response entity and close the stream.- Parameters:
type- type of entityobject- object to writeoutputStream- output stream to write torequestHeaders- request headersresponseHeaders- response headers
-
write
Write client request entity and close the stream.- Parameters:
type- type of entityobject- object to writeoutputStream- output stream to write toheaders- request headers
-