Class GetChangelogBatchExtendedResult

  • All Implemented Interfaces:
    LDAPResponse, java.io.Serializable

    @NotMutable
    @ThreadSafety(level=COMPLETELY_THREADSAFE)
    public final class GetChangelogBatchExtendedResult
    extends ExtendedResult
    This class provides an extended result that may be used to obtain information about the results of processing a get changelog batch extended request.
    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.

    The changelog batch result value is encoded as follows:
       ChangelogBatchResult ::= SEQUENCE {
            resumeToken                   [0] OCTET STRING OPTIONAL,
            moreChangesAvailable          [1] BOOLEAN,
            changesAlreadyPurged          [2] BOOLEAN DEFAULT FALSE,
            additionalInfo                [3] OCTET STRING OPTIONAL,
            estimatedChangesRemaining     [4] INTEGER (0 .. MAXINT) OPTIONAL,
            ... }
     


    See the documentation for the GetChangelogBatchExtendedRequest class for an example demonstrating its use.
    See Also:
    Serialized Form
    • Constructor Detail

      • GetChangelogBatchExtendedResult

        public GetChangelogBatchExtendedResult​(@NotNull
                                               LDAPResult r)
        Creates a new get changelog batch extended result with only the generic LDAP result information and no extended value.
        Parameters:
        r - An LDAP result with general details of the response. It must not be null.
      • GetChangelogBatchExtendedResult

        public GetChangelogBatchExtendedResult​(@NotNull
                                               LDAPResult r,
                                               int entryCount,
                                               @Nullable
                                               ASN1OctetString resumeToken,
                                               boolean moreChangesAvailable,
                                               boolean changesAlreadyPurged,
                                               @Nullable
                                               java.lang.String additionalInfo)
        Creates a new get changelog batch extended result with the provided information.
        Parameters:
        r - An LDAP result with general details of the response. It must not be null.
        entryCount - The number of entries returned. It may be less than zero to indicate that the number of entries is unknown.
        resumeToken - A token which may be used to resume retrieving changes at the point immediately after the last change returned. It may be null only if this result represents an error that prevented the operation from being successfully processed.
        moreChangesAvailable - Indicates whether there may be more changes immediately available to retrieve from the server.
        changesAlreadyPurged - Indicates whether the server may have already purged changes after the starting point referenced by the associated request.
        additionalInfo - A message with additional information about the status of the processing. It may be null if no additional message is available.
      • GetChangelogBatchExtendedResult

        public GetChangelogBatchExtendedResult​(@NotNull
                                               LDAPResult r,
                                               int entryCount,
                                               @Nullable
                                               ASN1OctetString resumeToken,
                                               boolean moreChangesAvailable,
                                               int estimatedChangesRemaining,
                                               boolean changesAlreadyPurged,
                                               @Nullable
                                               java.lang.String additionalInfo)
        Creates a new get changelog batch extended result with the provided information.
        Parameters:
        r - An LDAP result with general details of the response. It must not be null.
        entryCount - The number of entries returned. It may be less than zero to indicate that the number of entries is unknown.
        resumeToken - A token which may be used to resume retrieving changes at the point immediately after the last change returned. It may be null only if this result represents an error that prevented the operation from being successfully processed.
        moreChangesAvailable - Indicates whether there may be more changes immediately available to retrieve from the server.
        estimatedChangesRemaining - An estimate of the number of changes remaining to be retrieved. A value less than zero will be interpreted as "unknown".
        changesAlreadyPurged - Indicates whether the server may have already purged changes after the starting point referenced by the associated request.
        additionalInfo - A message with additional information about the status of the processing. It may be null if no additional message is available.
      • GetChangelogBatchExtendedResult

        public GetChangelogBatchExtendedResult​(@NotNull
                                               ExtendedResult extendedResult,
                                               int entryCount)
                                        throws LDAPException
        Creates a new get changelog batch extended result with the provided information.
        Parameters:
        extendedResult - A generic extended result to be parsed as a get changelog batch extended result. It must not be null.
        entryCount - The number of entries returned to the client. It may be less than zero to indicate that the entry count is unknown.
        Throws:
        LDAPException - If the provided extended result cannot be parsed as a get changelog batch result.
      • GetChangelogBatchExtendedResult

        public GetChangelogBatchExtendedResult​(@NotNull
                                               ExtendedResult extendedResult,
                                               @NotNull
                                               java.util.List<ChangelogEntryIntermediateResponse> entryList)
                                        throws LDAPException
        Creates a new get changelog batch extended result with the provided information.
        Parameters:
        extendedResult - A generic extended result to be parsed as a get changelog batch extended result. It must not be null.
        entryList - A list of the entries returned to the client. It may be empty to indicate that no entries were returned, but it must not be null.
        Throws:
        LDAPException - If the provided extended result cannot be parsed as a get changelog batch result.
    • Method Detail

      • getResumeToken

        @Nullable
        public ASN1OctetString getResumeToken()
        Retrieves a token that may be used to resume the process of retrieving changes at the point after the last change received. It may be null if this result represents an error that prevented the operation from being processed successfully.
        Returns:
        A token that may be used to resume the process of retrieving changes at the point after the last change received, or null if none is available.
      • moreChangesAvailable

        public boolean moreChangesAvailable()
        Indicates whether the server indicated that more changes may be immediately available without waiting. The value of this argument is only meaningful if ExtendedResult.hasValue() returns true.
        Returns:
        true if the server indicated that more changes may be immediately available without waiting, or false if not.
      • getEstimatedChangesRemaining

        public int getEstimatedChangesRemaining()
        Retrieves an estimate of the number of changes that may be immediately available to be retrieved from the server, if available.
        Returns:
        An estimate of the number of changes that may be immediately available to be retrieved from the server, or -1 if that information is not available.
      • changesAlreadyPurged

        public boolean changesAlreadyPurged()
        Indicates whether the server indicated that it may have already purged one or more changes after the starting point for the associated request and therefore the results returned may be missing changes. The value of this argument is only meaningful if ExtendedResult.hasValue() returns true.
        Returns:
        true if the server indicated that it may have already purged one or more changes after the starting point, or false if not.
      • getAdditionalInfo

        @Nullable
        public java.lang.String getAdditionalInfo()
        Retrieves a message with additional information about the processing that occurred, if available.
        Returns:
        A message with additional information about the processing that occurred, or null if none is available.
      • getEntryCount

        public int getEntryCount()
        Retrieves the number of entries returned by the server in the course of processing the extended operation. A value of -1 indicates that the entry count is not known.
        Returns:
        The number of entries returned by the server in the course of processing the extended operation, 0 if no entries were returned, or -1 if the entry count is not known.
      • getChangelogEntries

        @Nullable
        public java.util.List<ChangelogEntryIntermediateResponsegetChangelogEntries()
        Retrieves a list containing the entries that were returned by the server in the course of processing the extended operation, if available. An entry list will not be available if a custom ChangelogEntryListener was used for the request, and it may not be available if an error was encountered during processing.
        Returns:
        A list containing the entries that were returned by the server in the course of processing the extended operation, or null if an entry list is not available.
      • getExtendedResultName

        @NotNull
        public java.lang.String getExtendedResultName()
        Retrieves the user-friendly name for the extended result, if available. If no user-friendly name has been defined, but a response OID is available, then that will be returned. If neither a user-friendly name nor a response OID are available, then null will be returned.
        Overrides:
        getExtendedResultName in class ExtendedResult
        Returns:
        The user-friendly name for this extended request, the response OID if a user-friendly name is not available but a response OID is, or null if neither a user-friendly name nor a response OID are available.
      • toString

        public void toString​(@NotNull
                             java.lang.StringBuilder buffer)
        Appends a string representation of this extended response to the provided buffer.
        Specified by:
        toString in interface LDAPResponse
        Overrides:
        toString in class ExtendedResult
        Parameters:
        buffer - The buffer to which a string representation of this extended response will be appended.