public class LdapResultDsml extends Object implements DsmlDecorator<LdapResult>, LdapResult
| Constructor and Description |
|---|
LdapResultDsml(LdapApiService codec,
LdapResult result,
Message message)
Creates a new instance of LdapResultDsml.
|
| Modifier and Type | Method and Description |
|---|---|
void |
addReferral(LdapUrl referral)
Add a referral
|
LdapResult |
getDecorated()
Gets the Message this DsmlDecorator decorates.
|
String |
getDiagnosticMessage()
Gets the descriptive diagnostic message associated with the error code.
|
Dn |
getMatchedDn()
Get the matched Dn
|
Referral |
getReferral()
Gets the Referral associated with this LdapResult if the resultCode
property is set to the REFERRAL ResultCodeEnum.
|
List<String> |
getReferrals()
Get the referrals
|
ResultCodeEnum |
getResultCode()
Get the result code
|
boolean |
isDefaultSuccess()
Tells if the LdapResult is a success, with no added information.
|
boolean |
isReferral()
Gets whether or not this result represents a Referral.
|
void |
setDiagnosticMessage(String diagnosticMessage)
Sets the descriptive diagnostic message associated with the error code.
|
void |
setMatchedDn(Dn matchedDn)
Set the Matched Dn
|
void |
setReferral(Referral referral)
Sets the Referral associated with this LdapResult if the resultCode
property is set to the REFERRAL ResultCodeEnum.
|
void |
setResultCode(ResultCodeEnum resultCode)
Set the result code
|
org.dom4j.Element |
toDsml(org.dom4j.Element root)
Converts the request/reponse to its XML representation in the DSMLv2 format
|
public LdapResultDsml(LdapApiService codec, LdapResult result, Message message)
result - the LdapResult to decoratemessage - the associated messagethe - ldap codec servicepublic org.dom4j.Element toDsml(org.dom4j.Element root)
toDsml in interface DsmlDecorator<LdapResult>root - the root dom4j Elementpublic String getDiagnosticMessage()
getDiagnosticMessage in interface LdapResultpublic void setDiagnosticMessage(String diagnosticMessage)
setDiagnosticMessage in interface LdapResultdiagnosticMessage - the descriptive diagnostic message.public Dn getMatchedDn()
getMatchedDn in interface LdapResultpublic void setMatchedDn(Dn matchedDn)
setMatchedDn in interface LdapResultmatchedDn - The matchedDn to set.LdapResult.getMatchedDn()public void addReferral(LdapUrl referral)
referral - The referral to add.public ResultCodeEnum getResultCode()
getResultCode in interface LdapResultpublic void setResultCode(ResultCodeEnum resultCode)
setResultCode in interface LdapResultresultCode - The resultCode to set.public LdapResult getDecorated()
getDecorated in interface DsmlDecorator<LdapResult>public boolean isReferral()
isReferral in interface LdapResultpublic Referral getReferral()
getReferral in interface LdapResultpublic void setReferral(Referral referral)
setReferral in interface LdapResultreferral - optional referral on REFERRAL errors.public boolean isDefaultSuccess()
isDefaultSuccess in interface LdapResultCopyright © 2021. All rights reserved.