Class ScopeAdapter

java.lang.Object
org.keycloak.authorization.model.AbstractAuthorizationModel
org.keycloak.authorization.jpa.store.ScopeAdapter
All Implemented Interfaces:
Scope, JpaModel<ScopeEntity>

public class ScopeAdapter extends AbstractAuthorizationModel implements Scope, JpaModel<ScopeEntity>
Version:
$Revision: 1 $
Author:
Bill Burke
  • Constructor Details

    • ScopeAdapter

      public ScopeAdapter(ScopeEntity entity, jakarta.persistence.EntityManager em, StoreFactory storeFactory)
  • Method Details

    • getEntity

      public ScopeEntity getEntity()
      Specified by:
      getEntity in interface JpaModel<ScopeEntity>
    • getId

      public String getId()
      Description copied from interface: Scope
      Returns the unique identifier for this instance.
      Specified by:
      getId in interface Scope
      Returns:
      the unique identifier for this instance
    • getName

      public String getName()
      Description copied from interface: Scope
      Returns the name of this scope.
      Specified by:
      getName in interface Scope
      Returns:
      the name of this scope
    • setName

      public void setName(String name)
      Description copied from interface: Scope
      Sets a name for this scope. The name must be unique.
      Specified by:
      setName in interface Scope
      Parameters:
      name - the name of this scope
    • getDisplayName

      public String getDisplayName()
      Description copied from interface: Scope
      Returns the end user friendly name for this scope. If not defined, value for Scope.getName() is returned.
      Specified by:
      getDisplayName in interface Scope
      Returns:
      the friendly name for this scope
    • setDisplayName

      public void setDisplayName(String name)
      Description copied from interface: Scope
      Sets an end user friendly name for this scope.
      Specified by:
      setDisplayName in interface Scope
      Parameters:
      name - the name of this scope
    • getIconUri

      public String getIconUri()
      Description copied from interface: Scope
      Returns an icon URI for this scope.
      Specified by:
      getIconUri in interface Scope
      Returns:
      a uri for an icon
    • setIconUri

      public void setIconUri(String iconUri)
      Description copied from interface: Scope
      Sets an icon URI for this scope.
      Specified by:
      setIconUri in interface Scope
    • getResourceServer

      public ResourceServer getResourceServer()
      Description copied from interface: Scope
      Returns the ResourceServer instance to where this scope belongs to.
      Specified by:
      getResourceServer in interface Scope
      Returns:
    • toEntity

      public static ScopeEntity toEntity(jakarta.persistence.EntityManager em, Scope scope)
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object