cancel
Showing results for 
Search instead for 
Did you mean: 

Problem accessing to folder children's

jmv
Champ in-the-making
Champ in-the-making
when I run this code:
CmisObject obj = session.getObjectByPath("Company Home/Sites/MySite");
Folder f= (Folder) obj;
ItemIterable<CmisObject> l = f.getChildren();
for (CmisObject o : l){
   System.out.println(o.getName() + "is from type " + o.getType());
}
I cant see all the folders or files that are into the folder that contains my site!
I need to access to all the links of the site "MySite" and I can't do that!
It's any reason for my code don't work? is any other way to get all the links from the site?

thanks,
Regards
1 REPLY 1

jpotts
World-Class Innovator
World-Class Innovator
If you are looking for all of the link objects in a given site, they live in a folder called "links". From a CMIS perspective, all link objects are instances of "D:lnk:link". The properties of the link you are probably interested in are:
  • lnk:title

  • lnk:description

  • lnk:url
You can ask the link object for its name, but it will be something relatively uninteresting, like "link-1325004638927-4565".

Jeff