@Extensible @NotMutable @ThreadSafety(level=COMPLETELY_THREADSAFE) public class IntermediateResponse extends java.lang.Object implements java.io.Serializable, LDAPResponse
IntermediateResponseListener
must be provided for the associated
request. If an intermediate response message is returned for a request that
does not have a registered IntermediateResponseListener
, then it will
be silently discarded.Modifier and Type | Field and Description |
---|---|
protected static byte |
TYPE_INTERMEDIATE_RESPONSE_OID
The BER type for the intermediate response OID element.
|
protected static byte |
TYPE_INTERMEDIATE_RESPONSE_VALUE
The BER type for the intermediate response value element.
|
Modifier | Constructor and Description |
---|---|
protected |
IntermediateResponse(IntermediateResponse intermediateResponse)
Creates a new intermediate response with the information from the provided
intermediate response.
|
|
IntermediateResponse(int messageID,
java.lang.String oid,
ASN1OctetString value)
Creates a new intermediate response with the provided information.
|
|
IntermediateResponse(int messageID,
java.lang.String oid,
ASN1OctetString value,
Control[] controls)
Creates a new intermediate response with the provided information.
|
|
IntermediateResponse(java.lang.String oid,
ASN1OctetString value)
Creates a new intermediate response with the provided information.
|
|
IntermediateResponse(java.lang.String oid,
ASN1OctetString value,
Control[] controls)
Creates a new intermediate response with the provided information.
|
Modifier and Type | Method and Description |
---|---|
Control |
getControl(java.lang.String oid)
Retrieves the control with the specified OID.
|
Control[] |
getControls()
Retrieves the set of controls returned with this intermediate response.
|
java.lang.String |
getIntermediateResponseName()
Retrieves the user-friendly name for the intermediate response, if
available.
|
int |
getMessageID()
Retrieves the message ID for the LDAP message containing this response.
|
java.lang.String |
getOID()
Retrieves the OID for this intermediate response, if any.
|
ASN1OctetString |
getValue()
Retrieves the encoded value for this intermediate response, if any.
|
java.lang.String |
toString()
Retrieves a string representation of this intermediate response.
|
void |
toString(java.lang.StringBuilder buffer)
Appends a string representation of this intermediate response to the
provided buffer.
|
java.lang.String |
valueToString()
Retrieves a human-readable string representation for the contents of the
value for this intermediate response, if appropriate.
|
protected static final byte TYPE_INTERMEDIATE_RESPONSE_OID
protected static final byte TYPE_INTERMEDIATE_RESPONSE_VALUE
public IntermediateResponse(@Nullable java.lang.String oid, @Nullable ASN1OctetString value)
oid
- The OID for this intermediate response. It may be
null
if there is no OID.value
- The value for this intermediate response. It may be
null
if there is no value.public IntermediateResponse(int messageID, @Nullable java.lang.String oid, @Nullable ASN1OctetString value)
messageID
- The message ID for the LDAP message containing this
intermediate response.oid
- The OID for this intermediate response. It may be
null
if there is no OID.value
- The value for this intermediate response. It may be
null
if there is no value.public IntermediateResponse(@Nullable java.lang.String oid, @Nullable ASN1OctetString value, @Nullable Control[] controls)
oid
- The OID for this intermediate response. It may be
null
if there is no OID.value
- The value for this intermediate response. It may be
null
if there is no value.controls
- The set of controls for this intermediate response.public IntermediateResponse(int messageID, @Nullable java.lang.String oid, @Nullable ASN1OctetString value, @Nullable Control[] controls)
messageID
- The message ID for the LDAP message containing this
intermediate response.oid
- The OID for this intermediate response. It may be
null
if there is no OID.value
- The value for this intermediate response. It may be
null
if there is no value.controls
- The set of controls for this intermediate response.protected IntermediateResponse(@NotNull IntermediateResponse intermediateResponse)
intermediateResponse
- The intermediate response that should be used
to create this new intermediate response.public int getMessageID()
getMessageID
in interface LDAPResponse
@Nullable public final java.lang.String getOID()
null
if there
is no OID for this response.@Nullable public final ASN1OctetString getValue()
null
if there is no value for this response.@NotNull public final Control[] getControls()
get
method in the response control class.@Nullable public final Control getControl(@NotNull java.lang.String oid)
oid
- The OID of the control to retrieve.null
if there is no
such control for this intermediate response.@Nullable public java.lang.String getIntermediateResponseName()
null
will be returned.null
if neither a user-friendly name
nor a response OID are available.@Nullable public java.lang.String valueToString()
null
if there is
no value or no string representation is available.@NotNull public final java.lang.String toString()
toString
in class java.lang.Object
public void toString(@NotNull java.lang.StringBuilder buffer)
toString
in interface LDAPResponse
buffer
- The buffer to which the string representation should be
appended.