public class SafeProtocol extends Object implements TcpProtocol
| Constructor and Description |
|---|
SafeProtocol() |
| Modifier and Type | Method and Description |
|---|---|
ResponseOutputStream |
createResponse(Socket socket)
This lets protocols encode a response stream.
|
Object |
read(InputStream is)
Reads the input stream and returns a whole message.
|
void |
setMaxMessageLength(int maxMessageLength) |
void |
write(OutputStream os,
Object data)
Write the specified message to the output stream.
|
public static final String COOKIE
public Object read(InputStream is) throws IOException
TcpProtocolread in interface TcpProtocolis - the input streamIOException - if an exception occurspublic void write(OutputStream os, Object data) throws IOException
TcpProtocolwrite in interface TcpProtocolos - the output stream to write todata - the data to writeIOException - if an exception occurspublic ResponseOutputStream createResponse(Socket socket) throws IOException
TcpProtocolcreateResponse in interface TcpProtocolsocket - The destination to write toIOExceptionpublic void setMaxMessageLength(int maxMessageLength)
Copyright © 2003-2012 MuleSource, Inc.. All Rights Reserved.