@NotMutable @ThreadSafety(level=COMPLETELY_THREADSAFE) public final class PasswordPolicyStateExtendedResult extends ExtendedResult
PasswordPolicyStateExtendedRequest
class for an example that
demonstrates the use of the password policy state extended operation.
NOTE: This class, and other classes within the
com.unboundid.ldap.sdk.unboundidds
package structure, are only
supported for use against Ping Identity, UnboundID, and
Nokia/Alcatel-Lucent 8661 server products. These classes provide support
for proprietary functionality or for external specifications that are not
considered stable or mature enough to be guaranteed to work in an
interoperable way with other types of LDAP servers.
PasswordPolicyStateExtendedRequest
class.NO_CONTROLS
Constructor and Description |
---|
PasswordPolicyStateExtendedResult(ExtendedResult extendedResult)
Creates a new password policy state extended result from the provided
extended result.
|
PasswordPolicyStateExtendedResult(int messageID,
ResultCode resultCode,
java.lang.String diagnosticMessage,
java.lang.String matchedDN,
java.lang.String[] referralURLs,
java.lang.String userDN,
PasswordPolicyStateOperation[] operations,
Control[] responseControls)
Creates a new password policy state extended result with the provided
information.
|
Modifier and Type | Method and Description |
---|---|
boolean |
getBooleanValue(int opType)
Retrieves the value of the specified password policy state operation as a
boolean.
|
java.lang.String |
getExtendedResultName()
Retrieves the user-friendly name for the extended result, if available.
|
java.util.Date |
getGeneralizedTimeValue(int opType)
Retrieves the value for the specified password policy state operation as a
Date in generalized time format. |
java.util.Date[] |
getGeneralizedTimeValues(int opType)
Retrieves the set of values for the specified password policy state
operation as
Date s in generalized time format. |
int |
getIntValue(int opType)
Retrieves the value of the specified password policy state operation as an
integer.
|
PasswordPolicyStateOperation |
getOperation(int opType)
Retrieves the specified password policy state operation from the response.
|
java.lang.Iterable<PasswordPolicyStateOperation> |
getOperations()
Retrieves the set of password policy operations included in the response.
|
java.lang.String |
getStringValue(int opType)
Retrieves the value for the specified password policy state operation as a
string.
|
java.lang.String[] |
getStringValues(int opType)
Retrieves the set of string values for the specified password policy state
operation.
|
java.lang.String |
getUserDN()
Retrieves the user DN included in the response.
|
void |
toString(java.lang.StringBuilder buffer)
Appends a string representation of this extended result to the provided
buffer.
|
getOID, getValue, hasValue, toString
getDiagnosticMessage, getMatchedDN, getMessageID, getOperationType, getReferralURLs, getResponseControl, getResponseControls, getResultCode, getResultString, hasResponseControl, hasResponseControl
public PasswordPolicyStateExtendedResult(@NotNull ExtendedResult extendedResult) throws LDAPException
extendedResult
- The extended result to be decoded as a password
policy state extended result. It must not be
null
.LDAPException
- If the provided extended result cannot be decoded
as a password policy state extended result.public PasswordPolicyStateExtendedResult(int messageID, @NotNull ResultCode resultCode, @Nullable java.lang.String diagnosticMessage, @Nullable java.lang.String matchedDN, @Nullable java.lang.String[] referralURLs, @Nullable java.lang.String userDN, @Nullable PasswordPolicyStateOperation[] operations, @Nullable Control[] responseControls)
messageID
- The message ID for the LDAP message that is
associated with this LDAP result.resultCode
- The result code from the response.diagnosticMessage
- The diagnostic message from the response, if
available.matchedDN
- The matched DN from the response, if available.referralURLs
- The set of referral URLs from the response, if
available.userDN
- The user DN from the response.operations
- The set of operations from the response, mapped
from operation type to the corresponding
operation data.responseControls
- The set of controls from the response, if
available.@Nullable public java.lang.String getUserDN()
null
if the user
DN is not available (e.g., if this is an error response).@NotNull public java.lang.Iterable<PasswordPolicyStateOperation> getOperations()
@Nullable public PasswordPolicyStateOperation getOperation(int opType)
opType
- The operation type for the password policy state operation
to retrieve.null
if
no such operation was included in the response.@Nullable public java.lang.String getStringValue(int opType)
opType
- The operation type for the password policy state operation
to retrieve.null
if the specified operation was not included in the
response or did not have any values.@Nullable public java.lang.String[] getStringValues(int opType)
opType
- The operation type for the password policy state operation
to retrieve.null
if the specified operation was not
included in the response.public boolean getBooleanValue(int opType) throws java.util.NoSuchElementException, java.lang.IllegalStateException
opType
- The operation type for the password policy state operation
to retrieve.java.util.NoSuchElementException
- If the specified operation was not
included in the response.java.lang.IllegalStateException
- If the specified password policy state
operation does not have exactly one value,
or if the value cannot be parsed as a
boolean value.public int getIntValue(int opType) throws java.util.NoSuchElementException, java.lang.IllegalStateException
opType
- The operation type for the password policy state operation
to retrieve.java.util.NoSuchElementException
- If the specified operation was not
included in the response.java.lang.IllegalStateException
- If the value of the specified password
policy state operation cannot be parsed as
an integer value.@Nullable public java.util.Date getGeneralizedTimeValue(int opType) throws java.text.ParseException
Date
in generalized time format.opType
- The operation type for the password policy state operation
to retrieve.Date
, or null
if the specified operation was not
included in the response or did not have any values.java.text.ParseException
- If the value cannot be parsed as a date in
generalized time format.@Nullable public java.util.Date[] getGeneralizedTimeValues(int opType) throws java.text.ParseException
Date
s in generalized time format.opType
- The operation type for the password policy state operation
to retrieve.Date
s.java.text.ParseException
- If any of the values cannot be parsed as a date in
generalized time format.@NotNull public java.lang.String getExtendedResultName()
null
will be returned.getExtendedResultName
in class ExtendedResult
null
if neither a user-friendly name nor a response OID
are available.public void toString(@NotNull java.lang.StringBuilder buffer)
toString
in interface LDAPResponse
toString
in class ExtendedResult
buffer
- The buffer to which a string representation of this
extended result will be appended.