Package org.keycloak.component
Class JsonConfigComponentModel
- java.lang.Object
-
- org.keycloak.component.ComponentModel
-
- org.keycloak.component.JsonConfigComponentModel
-
- All Implemented Interfaces:
Serializable
public class JsonConfigComponentModel extends ComponentModel
Component model backed by JSON configuration. Useful for providers, which rely on JSON configuration rather than on ComponentModel, which is directly persisted as entity in the DB (store).- Author:
- Marek Posolda
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description JsonConfigComponentModel(Class<? extends Provider> providerType, String realmId, String providerId, com.fasterxml.jackson.databind.JsonNode configNode)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description String
get(String key)
boolean
get(String key, boolean defaultValue)
int
get(String key, int defaultValue)
long
get(String key, long defaultValue)
String
get(String key, String defaultValue)
String
getId()
String
getName()
String
getProviderId()
String
getProviderType()
-
Methods inherited from class org.keycloak.component.ComponentModel
contains, getConfig, getNote, getParentId, getSubType, hasNote, put, put, put, put, removeNote, setConfig, setId, setName, setNote, setParentId, setProviderId, setProviderType, setSubType
-
-
-
-
Constructor Detail
-
JsonConfigComponentModel
public JsonConfigComponentModel(Class<? extends Provider> providerType, String realmId, String providerId, com.fasterxml.jackson.databind.JsonNode configNode)
- Parameters:
providerType
-realmId
-providerId
-configNode
- JSON configuration of this provider. For example if node corresponds to JSON like "{\"foo\":\"bar\"}", then component configuration is supposed to have one configuration option "foo" with value "bar"
-
-
Method Detail
-
getProviderType
public String getProviderType()
- Overrides:
getProviderType
in classComponentModel
-
getProviderId
public String getProviderId()
- Overrides:
getProviderId
in classComponentModel
-
getName
public String getName()
- Overrides:
getName
in classComponentModel
-
getId
public String getId()
- Overrides:
getId
in classComponentModel
-
get
public boolean get(String key, boolean defaultValue)
- Overrides:
get
in classComponentModel
-
get
public long get(String key, long defaultValue)
- Overrides:
get
in classComponentModel
-
get
public int get(String key, int defaultValue)
- Overrides:
get
in classComponentModel
-
get
public String get(String key, String defaultValue)
- Overrides:
get
in classComponentModel
-
get
public String get(String key)
- Overrides:
get
in classComponentModel
-
-