Package eu.europeana.apikey.config
Class KeycloakProperties
java.lang.Object
eu.europeana.apikey.config.KeycloakProperties
@Component
@PropertySource("classpath:apikey.properties") @PropertySource(value="classpath:apikey.user.properties",ignoreResourceNotFound=true)
@ConfigurationProperties(prefix="keycloak")
public class KeycloakProperties
extends Object
Central location where all (or most) configuration settings are loaded.
-
Constructor Summary
ConstructorsConstructorDescriptionInstantiates a new Keycloak properties.KeycloakProperties(String authServerUrl, String realm, boolean useResourceRoleMappings, String realmPublicKey) Instantiates a new Keycloak properties. -
Method Summary
Modifier and TypeMethodDescriptionGets auth server url.Gets master public key.getRealm()Gets realm.Gets realm public key.booleanIs use resource role mappings boolean.voidsetAuthServerUrl(String authServerUrl) Sets auth server url.voidsetMasterPublicKey(String masterPublicKey) Sets master public key.voidSets realm.voidsetRealmPublicKey(String realmPublicKey) Sets realm public key.voidsetUseResourceRoleMappings(boolean useResourceRoleMappings) Sets use resource role mappings.
-
Constructor Details
-
KeycloakProperties
public KeycloakProperties()Instantiates a new Keycloak properties. -
KeycloakProperties
public KeycloakProperties(String authServerUrl, String realm, boolean useResourceRoleMappings, String realmPublicKey) Instantiates a new Keycloak properties.- Parameters:
authServerUrl- the auth server urlrealm- the realmuseResourceRoleMappings- the use resource role mappingsrealmPublicKey- the realm public key
-
-
Method Details
-
getAuthServerUrl
Gets auth server url.- Returns:
- the auth server url
-
setAuthServerUrl
Sets auth server url.- Parameters:
authServerUrl- the auth server url
-
getRealm
Gets realm.- Returns:
- the realm
-
setRealm
Sets realm.- Parameters:
realm- the realm
-
isUseResourceRoleMappings
public boolean isUseResourceRoleMappings()Is use resource role mappings boolean.- Returns:
- the boolean
-
setUseResourceRoleMappings
public void setUseResourceRoleMappings(boolean useResourceRoleMappings) Sets use resource role mappings.- Parameters:
useResourceRoleMappings- the use resource role mappings
-
getRealmPublicKey
Gets realm public key.- Returns:
- the realm public key
-
setRealmPublicKey
Sets realm public key.- Parameters:
realmPublicKey- the realm public key
-
getMasterPublicKey
Gets master public key.- Returns:
- the master public key
-
setMasterPublicKey
Sets master public key.- Parameters:
masterPublicKey- the master public key
-