Uploaded image for project: 'Nuxeo Java Client'
  1. Nuxeo Java Client
  2. JAVACLIENT-131

Listing directories is not a handled use case

    XMLWordPrintable

    Details

    • Type: Improvement
    • Status: Resolved
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 2.5
    • Fix Version/s: 3.0.0
    • Component/s: API

      Description

      The REST APIs allow to list Directories using the following URL:
      http://localhost:8080/nuxeo/api/v1/directory/

      Using the Java client, this is not possible:

      Directory directory = nuxeoClient.getDirectoryManager().fetchDirectory("");
      for (DirectoryEntry entry : directory.getDirectoryEntries()) {
        System.out.println("object -> " + entry.getDirectoryName());
        System.out.println("name -> " + entry.getProperties());
      }
      

      This returns the correct number of objects but null names and properties because the returned objects are not DirectoryEntries, there are Directories.

      A workaround is to manually parse the JSON response but this could be cleaner by handling the use case inside the Java Client.

        Attachments

          Activity

            People

            • Votes:
              1 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: