public final class LdapMessage extends Object
ProtocolOp
with LDAP specific message information.Modifier and Type | Method and Description |
---|---|
int |
getMessageId()
Returns the message-id.
|
ProtocolOp |
getProtocolOp()
Returns the protocol-op contained in this message.
|
byte |
getProtocolOpType()
Returns the protocol-op type.
|
static LdapMessage |
newLdapMessage(int messageId,
byte protocolOpType,
ProtocolOp protocolOp)
Creates a new
ProtocolOp containing a fully decoded LDAP message. |
static LdapMessage |
newRequestMessage(int messageId,
Request request)
Builds and returns an
LdapMessage containing a Request . |
static LdapMessage |
newResponseMessage(int messageId,
BindResult response)
Builds and returns an
LdapMessage containing a BindResult . |
static LdapMessage |
newResponseMessage(int messageId,
CompareResult response)
Builds and returns an
LdapMessage containing a CompareResult . |
static LdapMessage |
newResponseMessage(int messageId,
ExtendedResult response)
Builds and returns an
LdapMessage containing a ExtendedResult . |
static LdapMessage |
newResponseMessage(int messageId,
IntermediateResponse response)
Builds and returns an
LdapMessage containing a IntermediateResponse . |
static LdapMessage |
newResponseMessage(int messageId,
Request forRequest,
Response response)
Builds and returns an
LdapMessage containing a Response . |
static LdapMessage |
newResponseMessage(int messageId,
SearchResultEntry response)
Builds and returns an
LdapMessage containing a SearchResultEntry . |
static LdapMessage |
newResponseMessage(int messageId,
SearchResultReference response)
Builds and returns an
LdapMessage containing a SearchResultReference . |
static LdapMessage |
newSearchResultDoneMessage(int messageId,
Result result)
Builds and returns an
LdapMessage for a search result done operation type. |
public static LdapMessage newLdapMessage(int messageId, byte protocolOpType, ProtocolOp protocolOp)
ProtocolOp
containing a fully decoded LDAP message.messageId
- Unique identifier of this messageprotocolOpType
- Type of protocol-op contained in this messageprotocolOp
- The fully decoded ProtocolOp
LdapMessage
public static LdapMessage newRequestMessage(int messageId, Request request)
LdapMessage
containing a Request
.
LdapMessage.newLdapMessage(int, byte, ProtocolOp)
by inferring the protocolOpType
from the actual type of request
.messageId
- Identifier of this messagerequest
- The fully decoded Request
LdapMessage
public static LdapMessage newResponseMessage(int messageId, Request forRequest, Response response)
LdapMessage
containing a Response
.
LdapMessage.newLdapMessage(int, byte, ProtocolOp)
by inferring the protocolOpType
from the actual type of request
this response
respond to.messageId
- Identifier of this messageforRequest
- The Request
the response
is responding to.response
- The response which will be contained in the returned messageLdapMessage
public static LdapMessage newResponseMessage(int messageId, SearchResultEntry response)
LdapMessage
containing a SearchResultEntry
.
LdapMessage.newLdapMessage(int, byte, ProtocolOp)
by inferring the protocolOpType
.messageId
- Identifier of this messageresponse
- The response which will be contained in the returned messageLdapMessage
public static LdapMessage newResponseMessage(int messageId, SearchResultReference response)
LdapMessage
containing a SearchResultReference
.
LdapMessage.newLdapMessage(int, byte, ProtocolOp)
by inferring the protocolOpType
.messageId
- Identifier of this messageresponse
- The response which will be contained in the returned messageLdapMessage
public static LdapMessage newResponseMessage(int messageId, IntermediateResponse response)
LdapMessage
containing a IntermediateResponse
.
LdapMessage.newLdapMessage(int, byte, ProtocolOp)
by inferring the protocolOpType
.messageId
- Identifier of this messageresponse
- The response which will be contained in the returned messageLdapMessage
public static LdapMessage newResponseMessage(int messageId, BindResult response)
LdapMessage
containing a BindResult
.
LdapMessage.newLdapMessage(int, byte, ProtocolOp)
by inferring the protocolOpType
.messageId
- Identifier of this messageresponse
- The response which will be contained in the returned messageLdapMessage
public static LdapMessage newResponseMessage(int messageId, ExtendedResult response)
LdapMessage
containing a ExtendedResult
.
LdapMessage.newLdapMessage(int, byte, ProtocolOp)
by inferring the protocolOpType
.messageId
- Identifier of this messageresponse
- The response which will be contained in the returned messageLdapMessage
public static LdapMessage newResponseMessage(int messageId, CompareResult response)
LdapMessage
containing a CompareResult
.
LdapMessage.newLdapMessage(int, byte, ProtocolOp)
by inferring the protocolOpType
.messageId
- Identifier of this messageresponse
- The response which will be contained in the returned messageLdapMessage
public static LdapMessage newSearchResultDoneMessage(int messageId, Result result)
LdapMessage
for a search result done operation type.
LdapMessage.newLdapMessage(int, byte, ProtocolOp)
by removing the protocolOpType
parameter when it can be inferred from the actual type of protocolOp
.messageId
- Unique identifier of this messageresult
- The search result done resultLdapMessage
public int getMessageId()
public byte getProtocolOpType()
public ProtocolOp getProtocolOp()
ProtocolOp
Copyright © 2010-2018, ForgeRock All Rights Reserved.