AnsweredAssumed Answered

Custom service, using alfresco java api

Question asked by frankb on Feb 23, 2011
Latest reply on Mar 2, 2011 by

Im currently creating a custom service which returns the data as a nested list, which can be used in Sencha Touch.
I'm struggling to find out two things.

1: How can I find the "iconURL" and retrieve it?
serviceRegistry.getNodeService().getProperty(file.getNodeRef(), ApplicationModel.PROP_ICON)
returns null. When I run :
there is a attribute called "alf:icon", but I cant figure out the way to get access to these attributes with the java api.

2: How can I find the "downloadURL" of the files which i'm processing? I would like to provide a URL to a file, so that when users click on a file the download of the file will start.

How can I achieve these 2 things with the Java api?
There are some services which returns these attributes, but I cant figure out how to do it myself in my custom service.

Thanks in advance,