Class MapClientScopeAdapter
- java.lang.Object
-
- org.keycloak.models.map.clientscope.AbstractClientScopeModel<MapClientScopeEntity>
-
- org.keycloak.models.map.clientscope.MapClientScopeAdapter
-
- All Implemented Interfaces:
ClientScopeModel,OrderedModel,ProtocolMapperContainerModel,ScopeContainerModel
public class MapClientScopeAdapter extends AbstractClientScopeModel<MapClientScopeEntity> implements ClientScopeModel
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface org.keycloak.models.ClientScopeModel
ClientScopeModel.ClientScopeRemovedEvent, ClientScopeModel.SearchableFields
-
Nested classes/interfaces inherited from interface org.keycloak.models.OrderedModel
OrderedModel.OrderedModelComparator<OM extends OrderedModel>
-
-
Field Summary
-
Fields inherited from class org.keycloak.models.map.clientscope.AbstractClientScopeModel
entity, realm, session
-
Fields inherited from interface org.keycloak.models.ClientScopeModel
CONSENT_SCREEN_TEXT, DISPLAY_ON_CONSENT_SCREEN, DYNAMIC_SCOPE_REGEXP, GUI_ORDER, INCLUDE_IN_TOKEN_SCOPE, IS_DYNAMIC_SCOPE
-
-
Constructor Summary
Constructors Constructor Description MapClientScopeAdapter(KeycloakSession session, RealmModel realm, MapClientScopeEntity entity)
-
Method Summary
-
Methods inherited from class org.keycloak.models.map.clientscope.AbstractClientScopeModel
equals, hashCode
-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface org.keycloak.models.ClientScopeModel
getConsentScreenText, getDynamicScopeRegexp, getGuiOrder, isDisplayOnConsentScreen, isDynamicScope, isIncludeInTokenScope, setConsentScreenText, setDisplayOnConsentScreen, setGuiOrder, setIncludeInTokenScope, setIsDynamicScope
-
Methods inherited from interface org.keycloak.models.ScopeContainerModel
hasDirectScope
-
-
-
-
Constructor Detail
-
MapClientScopeAdapter
public MapClientScopeAdapter(KeycloakSession session, RealmModel realm, MapClientScopeEntity entity)
-
-
Method Detail
-
getId
public String getId()
- Specified by:
getIdin interfaceClientScopeModel
-
getName
public String getName()
- Specified by:
getNamein interfaceClientScopeModel
-
setName
public void setName(String name)
- Specified by:
setNamein interfaceClientScopeModel
-
getDescription
public String getDescription()
- Specified by:
getDescriptionin interfaceClientScopeModel
-
setDescription
public void setDescription(String description)
- Specified by:
setDescriptionin interfaceClientScopeModel
-
getProtocol
public String getProtocol()
- Specified by:
getProtocolin interfaceClientScopeModel
-
setProtocol
public void setProtocol(String protocol)
- Specified by:
setProtocolin interfaceClientScopeModel
-
getRealm
public RealmModel getRealm()
- Specified by:
getRealmin interfaceClientScopeModel
-
setAttribute
public void setAttribute(String name, String value)
- Specified by:
setAttributein interfaceClientScopeModel
-
removeAttribute
public void removeAttribute(String name)
- Specified by:
removeAttributein interfaceClientScopeModel
-
getAttribute
public String getAttribute(String name)
- Specified by:
getAttributein interfaceClientScopeModel
-
getAttributes
public Map<String,String> getAttributes()
- Specified by:
getAttributesin interfaceClientScopeModel
-
getProtocolMappersStream
public Stream<ProtocolMapperModel> getProtocolMappersStream()
Description copied from interface:ProtocolMapperContainerModelReturns protocol mappers as a stream.- Specified by:
getProtocolMappersStreamin interfaceProtocolMapperContainerModel- Returns:
- Stream of protocol mapper. Never returns
null.
-
addProtocolMapper
public ProtocolMapperModel addProtocolMapper(ProtocolMapperModel model)
- Specified by:
addProtocolMapperin interfaceProtocolMapperContainerModel
-
removeProtocolMapper
public void removeProtocolMapper(ProtocolMapperModel mapping)
- Specified by:
removeProtocolMapperin interfaceProtocolMapperContainerModel
-
updateProtocolMapper
public void updateProtocolMapper(ProtocolMapperModel mapping)
- Specified by:
updateProtocolMapperin interfaceProtocolMapperContainerModel
-
getProtocolMapperById
public ProtocolMapperModel getProtocolMapperById(String id)
- Specified by:
getProtocolMapperByIdin interfaceProtocolMapperContainerModel
-
getProtocolMapperByName
public ProtocolMapperModel getProtocolMapperByName(String protocol, String name)
- Specified by:
getProtocolMapperByNamein interfaceProtocolMapperContainerModel
-
getScopeMappingsStream
public Stream<RoleModel> getScopeMappingsStream()
Scopes mappings- Specified by:
getScopeMappingsStreamin interfaceScopeContainerModel- Returns:
- Stream of
RoleModel. Never returnsnull.
-
getRealmScopeMappingsStream
public Stream<RoleModel> getRealmScopeMappingsStream()
Description copied from interface:ScopeContainerModelFrom the scope mappings returned byScopeContainerModel.getScopeMappingsStream()returns only those that belong to the realm that owns this scope container.- Specified by:
getRealmScopeMappingsStreamin interfaceScopeContainerModel- Returns:
- stream of
RoleModel. Never returnsnull.
-
addScopeMapping
public void addScopeMapping(RoleModel role)
- Specified by:
addScopeMappingin interfaceScopeContainerModel
-
deleteScopeMapping
public void deleteScopeMapping(RoleModel role)
- Specified by:
deleteScopeMappingin interfaceScopeContainerModel
-
hasScope
public boolean hasScope(RoleModel role)
Description copied from interface:ScopeContainerModelReturnstrue, if this object has the given role directly or indirectly in its scope,falseotherwise.- Specified by:
hasScopein interfaceScopeContainerModel- Parameters:
role- the role- Returns:
- see description
- See Also:
if you want to check if this object has the given role directly in its scope
-
-