Class SearchResponseDsml
- java.lang.Object
-
- org.apache.directory.api.dsmlv2.AbstractDsmlMessageDecorator<E>
-
- org.apache.directory.api.dsmlv2.response.AbstractResponseDsml<Response>
-
- org.apache.directory.api.dsmlv2.response.SearchResponseDsml
-
- All Implemented Interfaces:
DsmlDecorator<Response>
,Message
,Response
public class SearchResponseDsml extends AbstractResponseDsml<Response>
This class represents the Search Response Dsml Container. It is used to store Search Responses (Search Result Entry, Search Result Reference and SearchResultDone).- Author:
- Apache Directory Project
-
-
Constructor Summary
Constructors Constructor Description SearchResponseDsml(LdapApiService codec)
Creates a new getDecoratedMessage() of SearchResponseDsml.SearchResponseDsml(LdapApiService codec, Message response)
Creates a new getDecoratedMessage() of SearchResponseDsml.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
addResponse(DsmlDecorator<? extends Response> response)
Adds a response.boolean
removeResponse(DsmlDecorator<? extends Response> response)
Removes a response.org.dom4j.Element
toDsml(org.dom4j.Element root)
Converts the request/reponse to its XML representation in the DSMLv2 format-
Methods inherited from class org.apache.directory.api.dsmlv2.AbstractDsmlMessageDecorator
addAllControls, addControl, get, getCodecService, getControl, getControls, getCurrentControl, getDecorated, getMessageId, getType, hasControl, put, removeControl, setMessageId
-
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.apache.directory.api.ldap.model.message.Message
addAllControls, addControl, get, getControl, getControls, getMessageId, getType, hasControl, put, removeControl, setMessageId
-
-
-
-
Constructor Detail
-
SearchResponseDsml
public SearchResponseDsml(LdapApiService codec)
Creates a new getDecoratedMessage() of SearchResponseDsml.- Parameters:
codec
- The LDAP Service to use
-
SearchResponseDsml
public SearchResponseDsml(LdapApiService codec, Message response)
Creates a new getDecoratedMessage() of SearchResponseDsml.- Parameters:
codec
- The LDAP Service to useresponse
- the LDAP response message to decorate
-
-
Method Detail
-
addResponse
public boolean addResponse(DsmlDecorator<? extends Response> response)
Adds a response.- Parameters:
response
- the response to add- Returns:
- true (as per the general contract of the Collection.add method).
-
removeResponse
public boolean removeResponse(DsmlDecorator<? extends Response> response)
Removes a response.- Parameters:
response
- the response to remove- Returns:
- true if this list contained the specified element.
-
toDsml
public org.dom4j.Element toDsml(org.dom4j.Element root)
Converts the request/reponse to its XML representation in the DSMLv2 format- Parameters:
root
- the root dom4j Element- Returns:
- the dom4j Element corresponding to the entry.
-
-