Moving Objects

CMIS 1.0 CMIS 1.1

Moving Between Folders

OpenCMIS (Java)

Folder sourceFolder = ...
Folder targetFolder = ...
Document doc = ...

doc.move(sourceFolder, targetFolder);

PortCMIS (C#)

IFolder sourceFolder = ...
IFolder targetFolder = ...
IDocument doc = ...

doc.Move(sourceFolder, targetFolder);

Adding and Removing from Folder

Adding to Folder

OpenCMIS (Java)

Folder folder = ...
Document doc = ...

doc.addToFolder(folder, true); // add all versions to folder

PortCMIS (C#)

IFolder folder = ...
IDocument doc = ...

doc.AddToFolder(folder, true); // add all versions to folder

Removing from Folder

OpenCMIS (Java)

Folder folder = ...
Document doc = ...

doc.removeFromFolder(folder);

PortCMIS (C#)

IFolder folder = ...
IDocument doc = ...

doc.RemoveFromFolder(folder);