Package de.xima.fc.entities
Class ClientAuthenticator
- java.lang.Object
-
- de.xima.cmn.dao.model.AEntity<Long>
-
- de.xima.fc.entities.AbstractEntity
-
- de.xima.fc.entities.AbstractLockableEntity
-
- de.xima.fc.entities.ALockableEntity
-
- de.xima.fc.entities.AAuthenticator<ClientAuthenticatorFile>
-
- de.xima.fc.entities.ClientAuthenticator
-
- All Implemented Interfaces:
de.xima.cmn.dao.interfaces.IEntity<Long>
,de.xima.cmn.dao.interfaces.ILockableEntity<Long>
,ILocalizationProviding<ClientAuthenticator,ClientAuthenticatorLocalization>
,IAuthenticator<ClientAuthenticatorFile>
,IDescriptionProviding
,ILockingVersionProviding
,IMandantDependent
,INameProviding
,ITransferable
,ITransferableEntity
,ITransferableLockableEntity
,IUUIDEntity
,Serializable
,Comparable<de.xima.cmn.dao.interfaces.IEntity<Long>>
@Entity public class ClientAuthenticator extends AAuthenticator<ClientAuthenticatorFile> implements IMandantDependent, ILocalizationProviding<ClientAuthenticator,ClientAuthenticatorLocalization>
Entity model for user authenticators inMandant
scope- Author:
- XIMA MEDIA GmbH
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description static String
ATTR_DEFAULT_LOCALE
static String
ATTR_LOCALIZATIONS
static String
ATTR_MANDANT
static String
COL_CLIENTID
static String
COL_DEFAULT_LOCALE
-
Fields inherited from class de.xima.fc.entities.AAuthenticator
ATTR_CALLBACK_URL_TYPE, ATTR_CALLBACK_UUID, ATTR_CONFIG_STATE, ATTR_TYPE, attributes, COL_CALLBACK_URL_TYPE, COL_UUID, fileMap
-
Fields inherited from class de.xima.fc.entities.AbstractLockableEntity
COL_LOCKINGVERSION, lockingVersion
-
Fields inherited from class de.xima.fc.entities.AbstractEntity
COL_ID, id
-
Fields inherited from interface de.xima.fc.entities.interfaces.IDescriptionProviding
ATTR_BESCHREIBUNG, ATTR_DESCRIPTION, COL_DESCRIPTION
-
Fields inherited from interface de.xima.fc.entities.interfaces.IMandantDependent
ATTR_CLIENT, COL_CLIENT_ID
-
Fields inherited from interface de.xima.fc.entities.interfaces.INameProviding
ATTR_NAME, COL_NAME
-
Fields inherited from interface de.xima.fc.entities.interfaces.ITransferableEntity
IMPORT_ID, INVALID_ID
-
Fields inherited from interface de.xima.fc.entities.interfaces.IUUIDEntity
ATTR_UUID, INVALID_UUID, INVALID_UUID_OBJECT, NULL_SAFE_UUID_TYPE, NULLABLE_UUID_TYPE, TYPE_NAME_UUID
-
-
Constructor Summary
Constructors Constructor Description ClientAuthenticator()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Map<String,String>
getAttributes()
Locale
getDefaultLocale()
String
getDisplayName(Locale locale)
Get the display name of the authenticator for the given locale.Map<String,ClientAuthenticatorFile>
getFileMap()
Long
getId()
String
getIdentifier()
List<ClientAuthenticatorLocalization>
getLocalizations()
Gets all localization associated with this authenticator.Locale
getLocalizationsDefaultLocale()
Gets the default locale for this providing object.Mandant
getMandant()
ClientAuthenticatorLocalization
newLocalization()
Creates a new localization object.void
onLoad()
ClientAuthenticatorFile
putFile(String key, ClientAuthenticatorFile file)
void
setDefaultLocale(Locale defaultLocale)
void
setLocalizations(List<ClientAuthenticatorLocalization> localizations)
Sets all localization associated with this authenticator.void
setMandant(Mandant mandant)
-
Methods inherited from class de.xima.fc.entities.AAuthenticator
getAttributeValue, getAttributeValue, getAttributeValueList, getAttributeValueMap, getBeschreibung, getCallbackUrlType, getCallbackUUID, getCallbackUUIDString, getConfigState, getDescription, getLoginButtonTitle, getName, getType, getUUID, getUUIDObject, putAttribute, putAttributes, putAttributes, removeAttribute, removeFile, setAttributes, setCallbackUrlType, setCallbackUUID, setCallbackUUIDString, setConfigState, setDescription, setFileMap, setLoginButtonTitle, setName, setType, setUUID, setUUIDObject, toString
-
Methods inherited from class de.xima.fc.entities.AbstractLockableEntity
entityHasChanged, getLockingVersion, setLockingVersion
-
Methods inherited from class de.xima.fc.entities.AbstractEntity
asIntValue, isPersisted, setId, setId
-
Methods inherited from class de.xima.cmn.dao.model.AEntity
compareTo, equals, getDBTableName, hashCode
-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface java.lang.Comparable
compareTo
-
Methods inherited from interface de.xima.fc.entities.interfaces.i18n.ILocalizationProviding
getKeys, getLocales, getLocalization, getLocalizationData, setLocalization
-
-
-
-
Field Detail
-
ATTR_MANDANT
public static final String ATTR_MANDANT
- See Also:
- Constant Field Values
-
ATTR_LOCALIZATIONS
public static final String ATTR_LOCALIZATIONS
- See Also:
- Constant Field Values
-
ATTR_DEFAULT_LOCALE
public static final String ATTR_DEFAULT_LOCALE
- See Also:
- Constant Field Values
-
COL_CLIENTID
public static final String COL_CLIENTID
- See Also:
- Constant Field Values
-
COL_DEFAULT_LOCALE
public static final String COL_DEFAULT_LOCALE
- See Also:
- Constant Field Values
-
-
Method Detail
-
getIdentifier
public String getIdentifier()
- Specified by:
getIdentifier
in interfaceIAuthenticator<ClientAuthenticatorFile>
- Returns:
- a unique key identifying this authenticator within the system, which is used in
IAuthenticatorConfig
s
-
getMandant
public Mandant getMandant()
- Specified by:
getMandant
in interfaceIMandantDependent
-
setMandant
public void setMandant(Mandant mandant)
- Specified by:
setMandant
in interfaceIMandantDependent
-
getDefaultLocale
public Locale getDefaultLocale()
-
setDefaultLocale
public void setDefaultLocale(Locale defaultLocale)
-
getLocalizationsDefaultLocale
public Locale getLocalizationsDefaultLocale()
Description copied from interface:ILocalizationProviding
Gets the default locale for this providing object.- Specified by:
getLocalizationsDefaultLocale
in interfaceILocalizationProviding<ClientAuthenticator,ClientAuthenticatorLocalization>
- Returns:
- the default locale for this providing object
-
getLocalizations
public List<ClientAuthenticatorLocalization> getLocalizations()
Gets all localization associated with this authenticator. An authenticator may contain a localized display name.- Specified by:
getLocalizations
in interfaceILocalizationProviding<ClientAuthenticator,ClientAuthenticatorLocalization>
- Returns:
- All localization associated with this authenticator.
-
setLocalizations
public void setLocalizations(List<ClientAuthenticatorLocalization> localizations)
Sets all localization associated with this authenticator. An authenticator may contain a localized display name.- Parameters:
localizations
- All localization associated with this authenticator.
-
newLocalization
public ClientAuthenticatorLocalization newLocalization()
Description copied from interface:ILocalizationProviding
Creates a new localization object.- Specified by:
newLocalization
in interfaceILocalizationProviding<ClientAuthenticator,ClientAuthenticatorLocalization>
- Returns:
- a new localization object
-
getDisplayName
public String getDisplayName(Locale locale)
Get the display name of the authenticator for the given locale. If no localization is available for the given locale, the name of the authenticator is returned.- Parameters:
locale
- The locale for which the display name should be returned.
-
onLoad
public void onLoad()
-
getAttributes
public Map<String,String> getAttributes()
- Specified by:
getAttributes
in interfaceIAuthenticator<ClientAuthenticatorFile>
- Returns:
- A map of all key-value pairs as configured by the user for this authenticator. Please note that the value may be a JSON object, depending on the key.
-
getFileMap
public Map<String,ClientAuthenticatorFile> getFileMap()
- Specified by:
getFileMap
in interfaceIAuthenticator<ClientAuthenticatorFile>
- Returns:
- A map of files the user uploaded when they configured this authenticator, such as SSL certificates or configuration files.
-
putFile
public ClientAuthenticatorFile putFile(String key, ClientAuthenticatorFile file)
Description copied from class:AAuthenticator
- Specified by:
putFile
in interfaceIAuthenticator<ClientAuthenticatorFile>
- Overrides:
putFile
in classAAuthenticator<ClientAuthenticatorFile>
- Parameters:
key
-String
to store file underfile
- the file to put into file map- Returns:
- the file previously stored for the given key or
null
if there wasn't any
-
-