cancel
Showing results for 
Search instead for 
Did you mean: 

retrieve list of approvers programmatically

Former Member
0 Kudos

I've developed a repository service that dynamically resets the permissions of a document created in KM based on the creator of the document. I'd also like to base the new permissions on who is listed as approvers in the approval workflow of the folder. What code would I use to retrieve a list of all approvers of the KM folder the document's created in?

Thanks in advance for any help!

- Fallon

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi Fallon,

I can't provide an actual code sample, but I have a direction.

<b>IStatemanagementUtilsResource</b>:

http://media.sdn.sap.com/html/submitted_docs/nw_kmc/javadoc/com/sapportals/wcm/repository/service/st...

<b>IStepList</b>:

http://media.sdn.sap.com/html/submitted_docs/nw_kmc/javadoc/com/sapportals/wcm/repository/service/st...

I didn't find how to get an actual instance of one of them, though.

Perhaps decompiling the jar files mentioned in the top of those pages can offer some more insight.

Hope that helps,

Yoav.

Answers (1)

Answers (1)

Former Member
0 Kudos

Hello Yoav

Thanks so much for your help! Thanks to the hints you provided, I was able to discover how to create the IStepList object:

IRepositoryServiceFactory repServiceFactory = ResourceFactory.getInstance().getServiceFactory();

IStatemanagementManager statemanagementService = (IStatemanagementManager) repServiceFactory.getRepositoryService(myResource, "StatemanagementRepositoryService");

IStepList stepList = statemanagementService.getStatemanagementResource(myResource).getUtils().readApproverList();

The stepList is always empty, but that seems to be related to a different issue I'm running into. Will be posting a new topic for that.

Thanks again for your help,

Fallon