org.apache.directory.shared.ldap.codec.decorators
Class DeleteResponseDecorator
java.lang.Object
org.apache.directory.shared.ldap.codec.decorators.MessageDecorator<M>
org.apache.directory.shared.ldap.codec.decorators.ResponseDecorator<DeleteResponse>
org.apache.directory.shared.ldap.codec.decorators.DeleteResponseDecorator
- All Implemented Interfaces:
- Decorator<DeleteResponse>, DeleteResponse, Message, Response, ResultResponse
public class DeleteResponseDecorator
- extends ResponseDecorator<DeleteResponse>
- implements DeleteResponse
A decorator for the DeleteRequest message
- Author:
- Apache Directory Project
| Fields inherited from interface org.apache.directory.shared.ldap.model.message.DeleteResponse |
TYPE |
| Methods inherited from class org.apache.directory.shared.ldap.codec.decorators.MessageDecorator |
addAllControls, addControl, get, getCodecService, getControl, getControls, getControlsLength, getCurrentControl, getDecorated, getDecorator, getMessageId, getMessageLength, getType, hasControl, put, removeControl, setControlsLength, setMessageId, setMessageLength, toString |
| Methods inherited from interface org.apache.directory.shared.ldap.model.message.Message |
addAllControls, addControl, get, getControl, getControls, getMessageId, getType, hasControl, put, removeControl, setMessageId |
DeleteResponseDecorator
public DeleteResponseDecorator(LdapCodecService codec,
DeleteResponse decoratedMessage)
- Makes a DeleteResponse a MessageDecorator.
- Parameters:
decoratedMessage - the decorated DeleteResponse
setDeleteResponseLength
public void setDeleteResponseLength(int deleteResponseLength)
- Stores the encoded length for the DeleteResponse
- Parameters:
deleteResponseLength - The encoded length
getDeleteResponseLength
public int getDeleteResponseLength()
- Returns:
- The encoded DeleteResponse's length
computeLength
public int computeLength()
- Compute the DelResponse length
DelResponse :
0x6B L1
|
+--> LdapResult
L1 = Length(LdapResult)
Length(DelResponse) = Length(0x6B) + Length(L1) + L1
- Specified by:
computeLength in interface Decorator<DeleteResponse>
- Returns:
- The object's computed length
encode
public ByteBuffer encode(ByteBuffer buffer)
throws EncoderException
- Encode the DelResponse message to a PDU.
- Specified by:
encode in interface Decorator<DeleteResponse>
- Parameters:
buffer - The buffer where to put the PDU
- Returns:
- The PDU.
- Throws:
EncoderException - if the buffer can't be encoded
Copyright © 2003-2011 The Apache Software Foundation. All Rights Reserved.