org.apache.mina.filter.codec.textline
Class TextLineEncoder
- ProtocolEncoder
public class TextLineEncoder
A
ProtocolEncoder
which encodes a string into a text line
which ends with the delimiter.
TextLineEncoder
public TextLineEncoder()
TextLineEncoder
public TextLineEncoder(Charset charset)
TextLineEncoder
public TextLineEncoder(Charset charset,
LineDelimiter delimiter)
dispose
public void dispose()
throws Exception
getMaxLineLength
public int getMaxLineLength()
Returns the allowed maximum size of the encoded line.
If the size of the encoded line exceeds this value, the encoder
will throw a IllegalArgumentException
. The default value
is Integer.MAX_VALUE
.
setMaxLineLength
public void setMaxLineLength(int maxLineLength)
Sets the allowed maximum size of the encoded line.
If the size of the encoded line exceeds this value, the encoder
will throw a IllegalArgumentException
. The default value
is Integer.MAX_VALUE
.