encoder = charset.newEncoder();
CodingErrorAction malformedCharAction = HttpProtocolParams.getMalformedInputAction(params);
CodingErrorAction unmappableCharAction = HttpProtocolParams.getUnmappableInputAction(params);
decoder.onMalformedInput(malformedCharAction);
decoder.onUnmappableCharacter(unmappableCharAction);
encoder.onMalformedInput(malformedCharAction);
encoder.onUnmappableCharacter(unmappableCharAction);
}
this.inbuf = new SessionInputBufferImpl(buffersize, linebuffersize, decoder, allocator);
this.outbuf = new SessionOutputBufferImpl(buffersize, linebuffersize, encoder, allocator);