2

I have one external web application through that i connected to alfresco repository using CMIS.

I am already able to upload document in to repository or able to download n view document.

Now my requirement is, I have to Update Specific Documents Properties.

So can any one please provide sample code or steps to update document properties Using CMIS.

Thanks in Advance...

Deepak Talape
  • 997
  • 1
  • 9
  • 35

1 Answers1

4

try this worked fine for me

Session session = getSession(serverUrl, username, password);
Document targetFile = (Document) session.getObject(path);
Map<String, Object> properties = new HashMap<>();
properties.put(PropertyIds.NAME, name);
targetFile.updateProperties(properties);

In my example you only have to replace name with whatever you want

Hope that helped you

Yagami Light
  • 1,756
  • 4
  • 19
  • 39