OpenCMIS/dotcmis: How to find whether a server has a particular capability?

168 Views Asked by At

Using OpenCMIS (or dotcmis), after getting a Repository object from a repository, how to check whether it has a particular capability?

For instance, whether CapabilityChanges is set to all.

2

There are 2 best solutions below

0
On BEST ANSWER

This is a bit nicer:

if ( repository.Capabilities.ChangesCapabilities == CapabilityChanges.All ) { ... }
0
On

There is probably a more elegant way to do it, but now I am using this:

if ( repository.Capabilities.ChangesCapabilities.GetCmisValue().Equals("all") )
  { ... }