Class SaperionClientFactoryImpl
- java.lang.Object
-
- com.lexmark.saperion.client.implementation.SaperionClientFactoryImpl
-
- All Implemented Interfaces:
SaperionClientFactory
public class SaperionClientFactoryImpl extends java.lang.Object implements SaperionClientFactory
This is the default implementation ofSaperionClientFactory
.- Author:
- jschwarz
-
-
Constructor Summary
Constructors Constructor Description SaperionClientFactoryImpl(Connector connector)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description SaperionClient
changePassword(java.lang.String userName, java.lang.String oldPassword, java.lang.String newPassword, com.lexmark.saperion.LicenseEnumeration licenseType, java.lang.String tenant)
This method creates a new saperion client with a new session in the context of the given user credentials.SaperionClient
newClient(java.lang.String token, com.lexmark.saperion.LicenseEnumeration licenseType, java.lang.String tenant)
This method creates a new saperion client with a new session in the context of the given user credentials.SaperionClient
newClient(java.lang.String userName, java.lang.String password, com.lexmark.saperion.LicenseEnumeration licenseType)
This method creates a new saperion client with a new session in the context of the given user credentials.SaperionClient
newClient(java.lang.String userName, java.lang.String password, com.lexmark.saperion.LicenseEnumeration licenseType, java.lang.String tenant)
This method creates a new saperion client with a new session in the context of the given user credentials.SaperionClient
newClient(java.lang.String userName, java.lang.String password, com.lexmark.saperion.LicenseEnumeration licenseType, java.lang.String tenant, java.lang.String impersonatedUser)
This method creates a new saperion client with a new session in the context of the given user credentials.
-
-
-
Constructor Detail
-
SaperionClientFactoryImpl
public SaperionClientFactoryImpl(Connector connector)
-
-
Method Detail
-
newClient
public SaperionClient newClient(java.lang.String userName, java.lang.String password, com.lexmark.saperion.LicenseEnumeration licenseType, java.lang.String tenant) throws com.lexmark.saperion.exceptions.EcmException
Description copied from interface:SaperionClientFactory
This method creates a new saperion client with a new session in the context of the given user credentials.- Specified by:
newClient
in interfaceSaperionClientFactory
- Parameters:
userName
- the name of the userpassword
- the password of the userlicenseType
- the saperion license to use for the sessiontenant
- the name of the tenant- Returns:
- a client in the context of the given credentials
- Throws:
com.lexmark.saperion.exceptions.EcmException
-
newClient
public SaperionClient newClient(java.lang.String userName, java.lang.String password, com.lexmark.saperion.LicenseEnumeration licenseType) throws com.lexmark.saperion.exceptions.EcmException
Description copied from interface:SaperionClientFactory
This method creates a new saperion client with a new session in the context of the given user credentials. On multi-tenant-systems, useSaperionClientFactory.newClient(String, String, LicenseEnumeration, String)
instead.- Specified by:
newClient
in interfaceSaperionClientFactory
- Parameters:
userName
- the name of the userpassword
- the password of the userlicenseType
- the saperion license to use for the session- Returns:
- a client in the context of the given credentials
- Throws:
com.lexmark.saperion.exceptions.EcmException
-
newClient
public SaperionClient newClient(java.lang.String userName, java.lang.String password, com.lexmark.saperion.LicenseEnumeration licenseType, java.lang.String tenant, java.lang.String impersonatedUser) throws com.lexmark.saperion.exceptions.EcmException
Description copied from interface:SaperionClientFactory
This method creates a new saperion client with a new session in the context of the given user credentials.- Specified by:
newClient
in interfaceSaperionClientFactory
- Parameters:
userName
- the name of the userpassword
- the password of the userlicenseType
- the saperion license to use for the sessiontenant
- the name of the tenantimpersonatedUser
- the name of the impersonated user- Returns:
- a client in the context of the given credentials
- Throws:
com.lexmark.saperion.exceptions.EcmException
-
newClient
public SaperionClient newClient(java.lang.String token, com.lexmark.saperion.LicenseEnumeration licenseType, java.lang.String tenant) throws com.lexmark.saperion.exceptions.EcmException
Description copied from interface:SaperionClientFactory
This method creates a new saperion client with a new session in the context of the given user credentials.- Specified by:
newClient
in interfaceSaperionClientFactory
- Parameters:
token
- a token retrieved from an authorization servicelicenseType
- the saperion license to use for the sessiontenant
- the name of the tenant- Returns:
- a client in the context of the given credentials
- Throws:
com.lexmark.saperion.exceptions.EcmException
-
changePassword
public SaperionClient changePassword(java.lang.String userName, java.lang.String oldPassword, java.lang.String newPassword, com.lexmark.saperion.LicenseEnumeration licenseType, java.lang.String tenant) throws com.lexmark.saperion.exceptions.EcmException
Description copied from interface:SaperionClientFactory
This method creates a new saperion client with a new session in the context of the given user credentials. It also changes the users password. This is the only possibility a user whose password is expired has to log in and change his password.- Specified by:
changePassword
in interfaceSaperionClientFactory
- Parameters:
userName
- the name of the useroldPassword
- the current (possibly expired) password of the usernewPassword
- the new password of the userlicenseType
- the saperion license to use for the sessiontenant
- the name of the tenant- Returns:
- a client in the context of the given credentials
- Throws:
com.lexmark.saperion.exceptions.EcmException
-
-