cancel
Showing results for 
Search instead for 
Did you mean: 

How to browse folder contents.

msariman
Champ in-the-making
Champ in-the-making
Does anyone know how to get the folder content and iterate.

I can get the stores,

RepositoryServiceSoapBindingStub repositoryService = WebServiceFactory.getRepositoryService();
ContentServiceSoapBindingStub contentService = WebServiceFactory.getContentService();
Store[] stores = repositoryService.getStores();
for (Store store : stores)
{
     …..

But how do I get the content of the folder and iterate?

Thank You in advance
2 REPLIES 2

jean3167
Champ in-the-making
Champ in-the-making
May be a third party tool may do the job.
you should make a search on goolge for tool like print directory on the web.

raphaelc
Champ in-the-making
Champ in-the-making
You can use the "queryChildren" method from RepositoryService.


Reference myFolder = new Reference(store, myUuid, null); // You can specify the path instead of the uuid if you prefer

RepositoryServiceSoapBindingStub repositoryService = WebServiceFactory.getRepositoryService();
QueryResult queryResult = repositoryService.queryChildren(myFolder);
ResultSet resultSet = queryResult.getResultSet();

ResultSetRow[] rows = resultSet.getRows();
for(ResultSetRow row : rows) {
   // Every "row" is pointing to a file
    …
}