谁能告诉我使用 DotCMIS dll 在露天查看所有工作区的步骤是什么?
问问题
1719 次
1 回答
3
在 CMIS 中没有工作空间的概念。我猜你的意思是你想列出存储库。为此,如官方示例所示,您可以执行以下操作:
//
// AtomPub version
//
Dictionary<string, string> parameters = new Dictionary<string, string>();
parameters[SessionParameter.BindingType] = BindingType.AtomPub;
parameters[SessionParameter.AtomPubUrl] = "http://your.host.name/alfresco/service/cmis";
parameters[SessionParameter.User] = "admin";
parameters[SessionParameter.Password] = "admin";
SessionFactory factory = SessionFactory.NewInstance();
IList<IRepository> repos = factory.GetRepositories(parameters);
//
// WebServices version
//
Dictionary<string, string> parameters = new Dictionary<string, string>();
parameters[SessionParameter.BindingType] = BindingType.WebServices;
parameters[SessionParameter.WebServicesRepositoryService] = "http://your.host.name/alfresco/cmis/RepositoryService?wsdl";
parameters[SessionParameter.WebServicesAclService] = "http://your.host.name/alfresco/cmis/AclService?wsdl";
parameters[SessionParameter.WebServicesDiscoveryService] = "http://your.host.name/alfresco/cmis/DiscoveryService?wsdl";
parameters[SessionParameter.WebServicesMultifilingService] = "http://your.host.name/alfresco/cmis/MultifilingService?wsdl";
parameters[SessionParameter.WebServicesNavigationService] = "http://your.host.name/alfresco/cmis/NavigationService?wsdl";
parameters[SessionParameter.WebServicesObjectService] = "http://your.host.name/alfresco/cmis/ObjectService?wsdl";
parameters[SessionParameter.WebServicesPolicyService] = "http://your.host.name/alfresco/cmis/PolicyService?wsdl";
parameters[SessionParameter.WebServicesRelationshipService] = "http://your.host.name/alfresco/cmis/RelationshipService?wsdl";
parameters[SessionParameter.WebServicesVersioningService] = "http://your.host.name/alfresco/cmis/VersioningService?wsdl";
parameters[SessionParameter.User] = "admin";
parameters[SessionParameter.Password] = "admin";
SessionFactory factory = SessionFactory.NewInstance();
IList<IRepository> repos = factory.GetRepositories(parameters);
于 2012-04-23T09:06:38.040 回答