Package org.keycloak.models.map.common
Class AbstractMapProviderFactory<T extends Provider,V extends AbstractEntity,M>
- java.lang.Object
- 
- org.keycloak.models.map.common.AbstractMapProviderFactory<T,V,M>
 
- 
- All Implemented Interfaces:
- AmphibianProviderFactory<T>,- ComponentFactory<T,T>,- ConfiguredProvider,- EnvironmentDependentProviderFactory,- ProviderFactory<T>
 - Direct Known Subclasses:
- MapClientProviderFactory,- MapClientScopeProviderFactory,- MapGlobalLockProviderFactory,- MapGroupProviderFactory,- MapPublicKeyStorageProviderFactory,- MapRealmProviderFactory,- MapRoleProviderFactory,- MapRootAuthenticationSessionProviderFactory,- MapSingleUseObjectProviderFactory,- MapUserLoginFailureProviderFactory,- MapUserProviderFactory,- MapUserSessionProviderFactory
 
 public abstract class AbstractMapProviderFactory<T extends Provider,V extends AbstractEntity,M> extends Object implements AmphibianProviderFactory<T>, EnvironmentDependentProviderFactory - Author:
- hmlnarik
 
- 
- 
Nested Class SummaryNested Classes Modifier and Type Class Description static classAbstractMapProviderFactory.MapProviderObjectType
 - 
Field SummaryFields Modifier and Type Field Description static StringCONFIG_STORAGEprotected org.jboss.logging.LoggerLOGprotected Class<M>modelTypestatic StringPROVIDER_IDstatic AtomicIntegeruniqueCounter
 - 
Constructor SummaryConstructors Modifier Constructor Description protectedAbstractMapProviderFactory(Class<M> modelType, Class<T> providerType)
 - 
Method SummaryAll Methods Static Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description Tcreate(KeycloakSession session)Returns instance of a provider.abstract TcreateNew(KeycloakSession session)Creates new instance of a provider.StringgetId()MapStorage<V,M>getMapStorage(KeycloakSession session)static ProviderFactory<MapStorageProvider>getProviderFactoryOrComponentFactory(KeycloakSession session, Config.Scope storageConfigScope)voidinit(Config.Scope config)Only called once when the factory is first created.booleanisSupported()voidpostInit(KeycloakSessionFactory factory)Called after all provider factories have been initialized- 
Methods inherited from class java.lang.Objectclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 - 
Methods inherited from interface org.keycloak.component.AmphibianProviderFactoryclose, create, getConfigProperties, onUpdate, preRemove
 - 
Methods inherited from interface org.keycloak.component.ComponentFactorygetCommonProviderConfigProperties, getTypeMetadata, onCreate, validateConfiguration
 - 
Methods inherited from interface org.keycloak.provider.ConfiguredProvidergetConfig, getHelpText
 - 
Methods inherited from interface org.keycloak.provider.EnvironmentDependentProviderFactoryisSupported
 - 
Methods inherited from interface org.keycloak.provider.ProviderFactorygetConfigMetadata, order
 
- 
 
- 
- 
- 
Field Detail- 
PROVIDER_IDpublic static final String PROVIDER_ID - See Also:
- Constant Field Values
 
 - 
CONFIG_STORAGEpublic static final String CONFIG_STORAGE - See Also:
- Constant Field Values
 
 - 
LOGprotected final org.jboss.logging.Logger LOG 
 - 
uniqueCounterpublic static final AtomicInteger uniqueCounter 
 
- 
 - 
Method Detail- 
createNewpublic abstract T createNew(KeycloakSession session) Creates new instance of a provider.- Parameters:
- session-
- Returns:
- See description.
 
 - 
createpublic T create(KeycloakSession session) Returns instance of a provider. If the instance is already created within the session (it's found in session attributes), it's returned from there, otherwise new instance is created (and stored among the session attributes).- Specified by:
- createin interface- AmphibianProviderFactory<T extends Provider>
- Specified by:
- createin interface- ComponentFactory<T extends Provider,V extends AbstractEntity>
- Specified by:
- createin interface- ProviderFactory<T extends Provider>
- Parameters:
- session-
- Returns:
- See description.
 
 - 
getIdpublic String getId() - Specified by:
- getIdin interface- ProviderFactory<T extends Provider>
 
 - 
getMapStoragepublic MapStorage<V,M> getMapStorage(KeycloakSession session) 
 - 
getProviderFactoryOrComponentFactorypublic static ProviderFactory<MapStorageProvider> getProviderFactoryOrComponentFactory(KeycloakSession session, Config.Scope storageConfigScope) 
 - 
postInitpublic void postInit(KeycloakSessionFactory factory) Description copied from interface:ProviderFactoryCalled after all provider factories have been initialized- Specified by:
- postInitin interface- ProviderFactory<T extends Provider>
 
 - 
initpublic void init(Config.Scope config) Description copied from interface:ProviderFactoryOnly called once when the factory is first created. This config is pulled from keycloak_server.json- Specified by:
- initin interface- ProviderFactory<T extends Provider>
 
 - 
isSupportedpublic boolean isSupported() - Specified by:
- isSupportedin interface- EnvironmentDependentProviderFactory
- Returns:
- trueif the provider is supported and should be available,- falseotherwise
 
 
- 
 
-