Package org.keycloak.broker.oidc.mappers
Class UsernameTemplateMapper
- java.lang.Object
- 
- org.keycloak.broker.provider.AbstractIdentityProviderMapper
- 
- org.keycloak.broker.oidc.mappers.AbstractClaimMapper
- 
- org.keycloak.broker.oidc.mappers.UsernameTemplateMapper
 
 
 
- 
- All Implemented Interfaces:
- IdentityProviderMapper,- ConfiguredProvider,- Provider,- ProviderFactory<IdentityProviderMapper>
 
 public class UsernameTemplateMapper extends AbstractClaimMapper - Version:
- $Revision: 1 $
- Author:
- Bill Burke
 
- 
- 
Field SummaryFields Modifier and Type Field Description static String[]COMPATIBLE_PROVIDERSstatic StringPROVIDER_IDstatic StringTEMPLATE- 
Fields inherited from class org.keycloak.broker.oidc.mappers.AbstractClaimMapperCLAIM, CLAIM_VALUE
 - 
Fields inherited from interface org.keycloak.broker.provider.IdentityProviderMapperANY_PROVIDER, DEFAULT_IDENTITY_PROVIDER_MAPPER_SYNC_MODES
 
- 
 - 
Constructor SummaryConstructors Constructor Description UsernameTemplateMapper()
 - 
Method Summary- 
Methods inherited from class org.keycloak.broker.oidc.mappers.AbstractClaimMappergetClaimValue, getClaimValue, getClaimValue, hasClaimValue, valueEquals
 - 
Methods inherited from class org.keycloak.broker.provider.AbstractIdentityProviderMapperclose, create, importNewUser, init, postInit
 - 
Methods inherited from class java.lang.Objectclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 - 
Methods inherited from interface org.keycloak.provider.ConfiguredProvidergetConfig
 - 
Methods inherited from interface org.keycloak.provider.ProviderFactorygetConfigMetadata, order
 
- 
 
- 
- 
- 
Field Detail- 
COMPATIBLE_PROVIDERSpublic static final String[] COMPATIBLE_PROVIDERS 
 - 
TEMPLATEpublic static final String TEMPLATE - See Also:
- Constant Field Values
 
 - 
PROVIDER_IDpublic static final String PROVIDER_ID - See Also:
- Constant Field Values
 
 
- 
 - 
Method Detail- 
supportsSyncModepublic boolean supportsSyncMode(IdentityProviderSyncMode syncMode) 
 - 
getConfigPropertiespublic List<ProviderConfigProperty> getConfigProperties() 
 - 
getIdpublic String getId() 
 - 
getCompatibleProviderspublic String[] getCompatibleProviders() 
 - 
getDisplayCategorypublic String getDisplayCategory() 
 - 
getDisplayTypepublic String getDisplayType() 
 - 
updateBrokeredUserLegacypublic void updateBrokeredUserLegacy(KeycloakSession session, RealmModel realm, UserModel user, IdentityProviderMapperModel mapperModel, BrokeredIdentityContext context) Description copied from interface:IdentityProviderMapperCalled when this user has logged in before and has already been imported. Legacy behaviour. When updating the mapper to correctly update brokered users in all sync modes, move the old behavior into this method.- Specified by:
- updateBrokeredUserLegacyin interface- IdentityProviderMapper
- Overrides:
- updateBrokeredUserLegacyin class- AbstractIdentityProviderMapper
 
 - 
updateBrokeredUserpublic void updateBrokeredUser(KeycloakSession session, RealmModel realm, UserModel user, IdentityProviderMapperModel mapperModel, BrokeredIdentityContext context) Description copied from interface:IdentityProviderMapperCalled when this user has logged in before and has already been imported.- Specified by:
- updateBrokeredUserin interface- IdentityProviderMapper
- Overrides:
- updateBrokeredUserin class- AbstractIdentityProviderMapper
 
 - 
preprocessFederatedIdentitypublic void preprocessFederatedIdentity(KeycloakSession session, RealmModel realm, IdentityProviderMapperModel mapperModel, BrokeredIdentityContext context) Description copied from interface:IdentityProviderMapperCalled to determine what keycloak username and email to use to process the login request from the external IDP. It's called before "FirstBrokerLogin" flow, so can be used to map attributes to BrokeredIdentityContext ( BrokeredIdentityContext.setUserAttribute ), which will be available on "Review Profile" page and in authenticators during FirstBrokerLogin flow- Specified by:
- preprocessFederatedIdentityin interface- IdentityProviderMapper
- Overrides:
- preprocessFederatedIdentityin class- AbstractIdentityProviderMapper
 
 - 
getHelpTextpublic String getHelpText() 
 
- 
 
-