Package ej.hoka.http.encoding
Class IdentityTransferEncoding
- java.lang.Object
-
- ej.hoka.http.encoding.IdentityTransferEncoding
-
- All Implemented Interfaces:
TransferEncoding
public final class IdentityTransferEncoding extends java.lang.Object implements TransferEncoding
Identity transfer coding handler.
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.StringgetId()Returns an internal ID of this encoding handler.static IdentityTransferEncodinggetInstance()Returns an instance ofIdentityTransferEncoding.java.io.InputStreamopen(HttpRequest request, java.io.InputStream input)Creates a new instance ofIdentityMessageBodyInputStreamto read the message body of the HTTP request.java.io.OutputStreamopen(HttpResponse response, java.io.OutputStream output)Creates anIdentityMessageBodyOutputStreamto write the message body of the HTTP response.
-
-
-
Method Detail
-
getInstance
public static IdentityTransferEncoding getInstance()
Returns an instance ofIdentityTransferEncoding.- Returns:
- an instance of
IdentityTransferEncoding
-
getId
public java.lang.String getId()
Returns an internal ID of this encoding handler.- Specified by:
getIdin interfaceTransferEncoding- Returns:
- null
-
open
public java.io.InputStream open(HttpRequest request, java.io.InputStream input) throws java.io.IOException
Creates a new instance ofIdentityMessageBodyInputStreamto read the message body of the HTTP request.- Specified by:
openin interfaceTransferEncoding- Parameters:
request- the HTTP request object.input- the input stream to read the message body of the HTTP request.- Returns:
IdentityMessageBodyOutputStream.- Throws:
java.io.IOException- if an I/O error occurs.- See Also:
IdentityMessageBodyInputStream
-
open
public java.io.OutputStream open(HttpResponse response, java.io.OutputStream output) throws java.io.IOException
Creates anIdentityMessageBodyOutputStreamto write the message body of the HTTP response.- Specified by:
openin interfaceTransferEncoding- Parameters:
response- theHttpResponseoutput- theOutputStreamto write the message body of the HTTP response- Returns:
IdentityMessageBodyOutputStream- Throws:
java.io.IOException- when I/O error occurs- See Also:
IdentityMessageBodyOutputStream
-
-