com.wewebu.ow.server.ecmimpl.cmis
Class OwCMISCredentials

java.lang.Object
  extended by com.wewebu.ow.server.ecmimpl.OwAbstractCredentials
      extended by com.wewebu.ow.server.ecmimpl.cmis.OwCMISCredentials
All Implemented Interfaces:
com.wewebu.ow.server.ecm.OwCredentials
Direct Known Subclasses:
OwCMISLDAPCredentials

public class OwCMISCredentials
extends com.wewebu.ow.server.ecmimpl.OwAbstractCredentials

Credentials implementation. Containing all references to the CMIS services, which are also initialized in this class.Credentials implementation.
Containing all references to the CMIS services, which are also initialized in this class.

Alfresco Workdesk
Copyright (c) Alfresco Software, Inc.
All rights reserved.

For licensing information read the license.txt file or
go to: http://wiki.alfresco.com


Field Summary
static String AUTH_LDAP
          LDAP authentication, bypassing CMIS and connecting to the LDAP system of the CMIS repository
static String AUTH_NONE
          Basic authentication of CMIS, only user name and password
static String CONF_NODE_WSDL_ACL
          Configuration node name for ACL-Service URL
static String CONF_NODE_WSDL_DISCOVERY
          Configuration node name for DiscoveryService (search service) URL
static String CONF_NODE_WSDL_MULTIFILING
          Configuration node name for MultifilingService URL
static String CONF_NODE_WSDL_NAVIGATION
          Configuration node name for NavigationService URL
static String CONF_NODE_WSDL_OBJECT
          Configuration node name for ObjectService URL
static String CONF_NODE_WSDL_POLICY
          Configuration node name for PolicyService URL
static String CONF_NODE_WSDL_RELATIONSHIP
          Configuration node name for RelationshipService URL
static String CONF_NODE_WSDL_REPOSITORY
          Configuration node name for RepositoryService URL
static String CONF_NODE_WSDL_VERSIONING
          Configuration node name for VersioningService URL
 
Constructor Summary
OwCMISCredentials(com.wewebu.ow.server.util.OwXMLUtil configuration_p, String username_p, String password_p, OwCMISSecurityHandlerInterface securityhandler_p, com.wewebu.ow.server.mandator.OwMandator mandator_p)
          create credentials
 
Method Summary
protected  SOAPHandler<SOAPMessageContext> createContentHandler()
          Create a handler which will be assigned as the content handler.
protected  OwCMISUserInfo createUserInfo(String userName_p)
          (overridable)
 org.oasis_open.docs.ns.cmis.ws._200908.ACLServicePort getACLServicePort()
           
 org.oasis_open.docs.ns.cmis.ws._200908.ACLServicePort getACLServicePort(URL wsdlLocation_p)
          Get the ACL service port, for applying and requesting policies from objects.
protected  SOAPHandler<SOAPMessageContext> getContentHandler()
          Get a SOAPHandler which will be add as first handler into the handler chain.
 org.oasis_open.docs.ns.cmis.ws._200908.DiscoveryServicePort getDiscoveryServicePort()
           
 org.oasis_open.docs.ns.cmis.ws._200908.DiscoveryServicePort getDiscoveryServicePort(URL url_p)
          Get the CMIS service which handles the searches against the CMIS back-end system.
 String getLoginName()
          Deprecated. since 4.0.0.0 use OwAbstractCredentials.getAuthInfo(String) instead
 String getLoginPassword()
          Deprecated. since 4.0.0.0 use OwAbstractCredentials.getAuthInfo(String) instead
 com.wewebu.ow.server.mandator.OwMandator getMandator()
           
 org.oasis_open.docs.ns.cmis.ws._200908.MultiFilingServicePort getMultiFilingservicePort()
           
 org.oasis_open.docs.ns.cmis.ws._200908.MultiFilingServicePort getMultiFilingservicePort(URL wsdlLocation_p)
          Get the Service for multiple filing of documents, in different folders.
 org.oasis_open.docs.ns.cmis.ws._200908.NavigationServicePort getNavigationServicePort()
           
 org.oasis_open.docs.ns.cmis.ws._200908.NavigationServicePort getNavigationServicePort(URL wsdlLocation_p)
          Get the CMIS service which handles the browsing and/or traversing through the file structure of the CMIS back-end system.
 org.oasis_open.docs.ns.cmis.ws._200908.ObjectServicePort getObjectServicePort()
           
 org.oasis_open.docs.ns.cmis.ws._200908.ObjectServicePort getObjectServicePort(URL wsdlLocation_p)
          Get the CMIS object service, which handle create, copy and update objects, and also retrieving objects by ID or path.
 org.oasis_open.docs.ns.cmis.ws._200908.PolicyServicePort getPolicyServicePort()
           
 org.oasis_open.docs.ns.cmis.ws._200908.PolicyServicePort getPolicyServicePort(URL wsdlLocation_p)
          Get the policy service port, for applying and requesting policies from objects.
 org.oasis_open.docs.ns.cmis.ws._200908.RelationshipServicePort getRelationshipServicePort()
           
 org.oasis_open.docs.ns.cmis.ws._200908.RelationshipServicePort getRelationshipServicePort(URL wsdlLocation_p)
          Get CMIS relationship service port, for handling of document relationships.
 org.oasis_open.docs.ns.cmis.ws._200908.RepositoryServicePort getRepositoryServicePort()
           
 org.oasis_open.docs.ns.cmis.ws._200908.RepositoryServicePort getRepositoryServicePort(URL wsdlLocation_p)
          Get the CMIS repository service, which is used to retrieve additional Information about repositories, or existent object class definitions.
 OwCMISSecurityHandlerInterface getSecurityHandler()
          Get the class which is used as WebService Security Handler
 String getSecurityToken(com.wewebu.ow.server.ecm.OwResource resource_p)
           
protected  URL getServiceURL(String confNode_p)
          Get the URL from configuration, and cache it for further request.
 OwCMISUserInfo getUserInfo()
           
 org.oasis_open.docs.ns.cmis.ws._200908.VersioningServicePort getVersionServicePort()
           
 org.oasis_open.docs.ns.cmis.ws._200908.VersioningServicePort getVersionServicePort(URL wsdlLocation_p)
          Get the service port for handling versions functionality of CMIS repository.
 void invalidate()
           
 boolean isContainerBasedAuthenticated()
           
protected  void removeHandler(BindingProvider bp_p)
          Remove all handler which were added with the current class to the given BindingProvider
 void setMandator(com.wewebu.ow.server.mandator.OwMandator madator_p)
           
 
Methods inherited from class com.wewebu.ow.server.ecmimpl.OwAbstractCredentials
getAuthInfo, setAuthInfo
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

CONF_NODE_WSDL_REPOSITORY

public static final String CONF_NODE_WSDL_REPOSITORY
Configuration node name for RepositoryService URL

See Also:
Constant Field Values

CONF_NODE_WSDL_NAVIGATION

public static final String CONF_NODE_WSDL_NAVIGATION
Configuration node name for NavigationService URL

See Also:
Constant Field Values

CONF_NODE_WSDL_OBJECT

public static final String CONF_NODE_WSDL_OBJECT
Configuration node name for ObjectService URL

See Also:
Constant Field Values

CONF_NODE_WSDL_MULTIFILING

public static final String CONF_NODE_WSDL_MULTIFILING
Configuration node name for MultifilingService URL

See Also:
Constant Field Values

CONF_NODE_WSDL_DISCOVERY

public static final String CONF_NODE_WSDL_DISCOVERY
Configuration node name for DiscoveryService (search service) URL

See Also:
Constant Field Values

CONF_NODE_WSDL_VERSIONING

public static final String CONF_NODE_WSDL_VERSIONING
Configuration node name for VersioningService URL

See Also:
Constant Field Values

CONF_NODE_WSDL_RELATIONSHIP

public static final String CONF_NODE_WSDL_RELATIONSHIP
Configuration node name for RelationshipService URL

See Also:
Constant Field Values

CONF_NODE_WSDL_POLICY

public static final String CONF_NODE_WSDL_POLICY
Configuration node name for PolicyService URL

See Also:
Constant Field Values

CONF_NODE_WSDL_ACL

public static final String CONF_NODE_WSDL_ACL
Configuration node name for ACL-Service URL

See Also:
Constant Field Values

AUTH_NONE

public static final String AUTH_NONE
Basic authentication of CMIS, only user name and password

See Also:
Constant Field Values

AUTH_LDAP

public static final String AUTH_LDAP
LDAP authentication, bypassing CMIS and connecting to the LDAP system of the CMIS repository

See Also:
Constant Field Values
Constructor Detail

OwCMISCredentials

public OwCMISCredentials(com.wewebu.ow.server.util.OwXMLUtil configuration_p,
                         String username_p,
                         String password_p,
                         OwCMISSecurityHandlerInterface securityhandler_p,
                         com.wewebu.ow.server.mandator.OwMandator mandator_p)
                  throws com.wewebu.ow.server.exceptions.OwException
create credentials

Parameters:
username_p - String log on name
password_p - String or null
securityhandler_p - OwCMISSecurityHandlerInterface
mandator_p - OwMandator
Throws:
com.wewebu.ow.server.exceptions.OwException
Method Detail

getMandator

public com.wewebu.ow.server.mandator.OwMandator getMandator()

setMandator

public void setMandator(com.wewebu.ow.server.mandator.OwMandator madator_p)

getObjectServicePort

public org.oasis_open.docs.ns.cmis.ws._200908.ObjectServicePort getObjectServicePort()
                                                                              throws com.wewebu.ow.server.exceptions.OwException
Throws:
com.wewebu.ow.server.exceptions.OwException

getObjectServicePort

public org.oasis_open.docs.ns.cmis.ws._200908.ObjectServicePort getObjectServicePort(URL wsdlLocation_p)
Get the CMIS object service, which handle create, copy and update objects, and also retrieving objects by ID or path.

Parameters:
wsdlLocation_p - URL to create the service port if not connected
Returns:
ObjectServicePort

getServiceURL

protected URL getServiceURL(String confNode_p)
                     throws com.wewebu.ow.server.exceptions.OwException
Get the URL from configuration, and cache it for further request.

Parameters:
confNode_p - String one of CONF_NODE_WSDL_...
Returns:
URL for the specified configuration node
Throws:
com.wewebu.ow.server.exceptions.OwException - if URL in configuration node is malformed

getRepositoryServicePort

public org.oasis_open.docs.ns.cmis.ws._200908.RepositoryServicePort getRepositoryServicePort()
                                                                                      throws com.wewebu.ow.server.exceptions.OwConfigurationException
Throws:
com.wewebu.ow.server.exceptions.OwConfigurationException

getRepositoryServicePort

public org.oasis_open.docs.ns.cmis.ws._200908.RepositoryServicePort getRepositoryServicePort(URL wsdlLocation_p)
Get the CMIS repository service, which is used to retrieve additional Information about repositories, or existent object class definitions.

Parameters:
wsdlLocation_p - URL of the WSDL to create service port
Returns:
RepositoryServicePort

getNavigationServicePort

public org.oasis_open.docs.ns.cmis.ws._200908.NavigationServicePort getNavigationServicePort()
                                                                                      throws com.wewebu.ow.server.exceptions.OwException
Throws:
com.wewebu.ow.server.exceptions.OwException

getNavigationServicePort

public org.oasis_open.docs.ns.cmis.ws._200908.NavigationServicePort getNavigationServicePort(URL wsdlLocation_p)
Get the CMIS service which handles the browsing and/or traversing through the file structure of the CMIS back-end system.

Parameters:
wsdlLocation_p - URL to create a service port if still not connected
Returns:
NavigationServicePort

getDiscoveryServicePort

public org.oasis_open.docs.ns.cmis.ws._200908.DiscoveryServicePort getDiscoveryServicePort()
                                                                                    throws com.wewebu.ow.server.exceptions.OwException
Throws:
com.wewebu.ow.server.exceptions.OwException

getDiscoveryServicePort

public org.oasis_open.docs.ns.cmis.ws._200908.DiscoveryServicePort getDiscoveryServicePort(URL url_p)
Get the CMIS service which handles the searches against the CMIS back-end system.

Parameters:
url_p - URL to create a service port if not connected
Returns:
DiscoverServicePort

getMultiFilingservicePort

public org.oasis_open.docs.ns.cmis.ws._200908.MultiFilingServicePort getMultiFilingservicePort()
                                                                                        throws com.wewebu.ow.server.exceptions.OwException
Throws:
com.wewebu.ow.server.exceptions.OwException

getMultiFilingservicePort

public org.oasis_open.docs.ns.cmis.ws._200908.MultiFilingServicePort getMultiFilingservicePort(URL wsdlLocation_p)
Get the Service for multiple filing of documents, in different folders.

Before calling this method, the capability of the repository should be checked

Parameters:
wsdlLocation_p - URL location of WSDL for MultiFilingService
Returns:
MultiFilingServicePort

getVersionServicePort

public org.oasis_open.docs.ns.cmis.ws._200908.VersioningServicePort getVersionServicePort()
                                                                                   throws com.wewebu.ow.server.exceptions.OwException
Throws:
com.wewebu.ow.server.exceptions.OwException

getVersionServicePort

public org.oasis_open.docs.ns.cmis.ws._200908.VersioningServicePort getVersionServicePort(URL wsdlLocation_p)
Get the service port for handling versions functionality of CMIS repository.

Before calling this method, the capability of the repository should be checked for versioning.

Parameters:
wsdlLocation_p - URL location of WSDL for creation of service port if not connected
Returns:
VersioningServicePort

getRelationshipServicePort

public org.oasis_open.docs.ns.cmis.ws._200908.RelationshipServicePort getRelationshipServicePort()
                                                                                          throws com.wewebu.ow.server.exceptions.OwException
Throws:
com.wewebu.ow.server.exceptions.OwException

getRelationshipServicePort

public org.oasis_open.docs.ns.cmis.ws._200908.RelationshipServicePort getRelationshipServicePort(URL wsdlLocation_p)
Get CMIS relationship service port, for handling of document relationships.

The relationship capability should be checked before calling this method

Parameters:
wsdlLocation_p -
Returns:
RelationshipServicePort

getPolicyServicePort

public org.oasis_open.docs.ns.cmis.ws._200908.PolicyServicePort getPolicyServicePort()
                                                                              throws com.wewebu.ow.server.exceptions.OwException
Throws:
com.wewebu.ow.server.exceptions.OwException

getPolicyServicePort

public org.oasis_open.docs.ns.cmis.ws._200908.PolicyServicePort getPolicyServicePort(URL wsdlLocation_p)
Get the policy service port, for applying and requesting policies from objects.

Parameters:
wsdlLocation_p - URL location of WSDL for policy service
Returns:
PolicyServicePort

getACLServicePort

public org.oasis_open.docs.ns.cmis.ws._200908.ACLServicePort getACLServicePort()
                                                                        throws com.wewebu.ow.server.exceptions.OwException
Throws:
com.wewebu.ow.server.exceptions.OwException

getACLServicePort

public org.oasis_open.docs.ns.cmis.ws._200908.ACLServicePort getACLServicePort(URL wsdlLocation_p)
Get the ACL service port, for applying and requesting policies from objects.

Parameters:
wsdlLocation_p - URL location of WSDL for the ACL service
Returns:
ACLServicePort
Since:
3.2.0.0

getSecurityHandler

public OwCMISSecurityHandlerInterface getSecurityHandler()
Get the class which is used as WebService Security Handler

Returns:
OwCMISSecurityHandler

getSecurityToken

public String getSecurityToken(com.wewebu.ow.server.ecm.OwResource resource_p)
Specified by:
getSecurityToken in interface com.wewebu.ow.server.ecm.OwCredentials
Overrides:
getSecurityToken in class com.wewebu.ow.server.ecmimpl.OwAbstractCredentials

createUserInfo

protected OwCMISUserInfo createUserInfo(String userName_p)
(overridable)

Parameters:
userName_p -
Returns:
an new OwCMISUserInfo for the given user

getUserInfo

public OwCMISUserInfo getUserInfo()
                           throws com.wewebu.ow.server.exceptions.OwException
Throws:
com.wewebu.ow.server.exceptions.OwException

invalidate

public void invalidate()
                throws com.wewebu.ow.server.exceptions.OwException
Throws:
com.wewebu.ow.server.exceptions.OwException

isContainerBasedAuthenticated

public boolean isContainerBasedAuthenticated()
                                      throws com.wewebu.ow.server.exceptions.OwException
Specified by:
isContainerBasedAuthenticated in interface com.wewebu.ow.server.ecm.OwCredentials
Overrides:
isContainerBasedAuthenticated in class com.wewebu.ow.server.ecmimpl.OwAbstractCredentials
Throws:
com.wewebu.ow.server.exceptions.OwException

removeHandler

protected void removeHandler(BindingProvider bp_p)
Remove all handler which were added with the current class to the given BindingProvider

Parameters:
bp_p - BindingProvider
Since:
3.1.0.0

getContentHandler

protected SOAPHandler<SOAPMessageContext> getContentHandler()
Get a SOAPHandler which will be add as first handler into the handler chain.

The first handler should be responsible for the content handling

.

Returns:
SOAPHandler
Since:
3.1.0.0

createContentHandler

protected SOAPHandler<SOAPMessageContext> createContentHandler()
Create a handler which will be assigned as the content handler.

Per default it will create an instance of the OwCMISContentHandler.

Returns:
SOAPHandler
Since:
3.1.0.0

getLoginName

public String getLoginName()
Deprecated. since 4.0.0.0 use OwAbstractCredentials.getAuthInfo(String) instead

Getter for the login name, which was used for authentication against repository.

Returns:
String login name
Since:
3.2.0.0

getLoginPassword

public String getLoginPassword()
Deprecated. since 4.0.0.0 use OwAbstractCredentials.getAuthInfo(String) instead

Getter for the password, which was used to authenticate against repository.

Returns:
String password
Since:
3.2.0.0


Copyright © 2013 Alfresco Business Solutions. All Rights Reserved.