Skip to content

ndi.cloud.api.documents.listDatasetDocumentsAll

 LISTDATASETDOCUMENTSALL User-facing wrapper to list ALL documents in a dataset.

    [B, ANSWER, APIRESPONSE, APIURL] = ndi.cloud.api.documents.listDatasetDocumentsAll(CLOUDDATASETID, 'pageSize', PS)

    Retrieves a complete list of all document summaries from a dataset by
    automatically handling pagination.

    Inputs:
        cloudDatasetID  - The ID of the dataset.
    Name-Value Inputs:
        pageSize        - (Optional) The number of results to fetch per API call.
                          Default is 1000.
        checkForUpdates - (Optional) If true, the function will check for new
                          documents that were added while it was running and
                          will attempt to retrieve them before returning.
                          Default is false.
        waitForUpdates  - (Optional) The time in seconds to wait before
                          re-checking the document count for updates.
                          Default is 5.
        maximumNumberUpdateReads - (Optional) The maximum number of times the
                          function will re-poll for updates to prevent an
                          infinite loop. Default is 100.

    Outputs:
        b            - True if the call succeeded, false otherwise.
        answer       - A struct array of document summaries on success, or an
                       error struct on failure, with the following fields:
                           id        - The document's ID on the cloud system.
                           ndiId     - The NDI document ID.
                           name      - The 'base.name' field, if it exists.
                           className - The NDI document's class name.
        apiResponse  - The full matlab.net.http.ResponseMessage object from the LAST successful page call.
        apiURL       - The URL that was called for the LAST successful page.

    Example:
        [success, all_docs] = ndi.cloud.api.documents.listDatasetDocumentsAll('d-12345');

    See also: ndi.cloud.api.implementation.documents.ListDatasetDocumentsAll, ndi.cloud.api.documents.listDatasetDocuments