*/
public ByteBuffer encode( ByteBuffer buffer ) throws EncoderException
{
if ( buffer == null )
{
throw new EncoderException( I18n.err( I18n.ERR_04023 ) );
}
try
{
// The result code
buffer.put( UniversalTag.ENUMERATED.getValue() );
buffer.put( ( byte ) 1 );
buffer.put( ( byte ) getResultCode().getValue() );
}
catch ( BufferOverflowException boe )
{
throw new EncoderException( I18n.err( I18n.ERR_04005 ) );
}
// The matchedDN
Value.encode( buffer, getMatchedDnBytes() );