cancel
Showing results for 
Search instead for 
Did you mean: 

Access to sites with CMIS

kyles
Champ in-the-making
Champ in-the-making
Hello all,

I am trying configure a way for a server to post content to a site for users to examine. I could not find any direct documentation in my googling. Am I on the right track or how should I accomplish this.

Thanks
3 REPLIES 3

angelborroy
Community Manager Community Manager
Community Manager
You can try accessing Sites node by path

<java>
CmisObject sites = session.getObjectByPath("/Sites");
Folder sitesFolder = (Folder) sites;
for (CmisObject site : sitesFolder.getChildren()) {
   if (site.getBaseType().getLocalName().equals("folder")) {
      Folder siteFolder = (Folder) site;
      for (CmisObject container : siteFolder.getChildren()) {
         if (container.getName().equals("documentLibrary")) {
            Folder documentLibraryFolder = (Folder) container;
            docLibFolders.put(site.getName(), documentLibraryFolder);
         }
      }
   }
}
</java>
Hyland Developer Evangelist

kyles
Champ in-the-making
Champ in-the-making
Angel, can you include a completed path for reference? Thank you for your reply!

angelborroy
Community Manager Community Manager
Community Manager
No more path is needed. Sites is a root node on CMIS
Hyland Developer Evangelist