Class PermissionTicketAdapter
java.lang.Object
org.keycloak.authorization.jpa.store.PermissionTicketAdapter
- All Implemented Interfaces:
PermissionTicket
,JpaModel<PermissionTicketEntity>
public class PermissionTicketAdapter
extends Object
implements PermissionTicket, JpaModel<PermissionTicketEntity>
- Version:
- $Revision: 1 $
- Author:
- Bill Burke
-
Nested Class Summary
Nested classes/interfaces inherited from interface org.keycloak.authorization.model.PermissionTicket
PermissionTicket.FilterOption, PermissionTicket.SearchableFields
-
Constructor Summary
ConstructorDescriptionPermissionTicketAdapter
(PermissionTicketEntity entity, jakarta.persistence.EntityManager entityManager, StoreFactory storeFactory) -
Method Summary
Modifier and TypeMethodDescriptionboolean
getId()
Returns the unique identifier for this instance.getOwner()
Returns the resource's owner, which is usually an identifier that uniquely identifies the resource's owner.Returns theResource
associated with this instanceReturns theResourceServer
where this policy belongs to.getScope()
Returns theScope
associated with this instanceint
hashCode()
boolean
void
setGrantedTimestamp
(Long millis) void
static PermissionTicketEntity
toEntity
(jakarta.persistence.EntityManager em, PermissionTicket permission)
-
Constructor Details
-
PermissionTicketAdapter
public PermissionTicketAdapter(PermissionTicketEntity entity, jakarta.persistence.EntityManager entityManager, StoreFactory storeFactory)
-
-
Method Details
-
getEntity
- Specified by:
getEntity
in interfaceJpaModel<PermissionTicketEntity>
-
getId
Description copied from interface:PermissionTicket
Returns the unique identifier for this instance.- Specified by:
getId
in interfacePermissionTicket
- Returns:
- the unique identifier for this instance
-
getOwner
Description copied from interface:PermissionTicket
Returns the resource's owner, which is usually an identifier that uniquely identifies the resource's owner.- Specified by:
getOwner
in interfacePermissionTicket
- Returns:
- the owner of this resource
-
getRequester
- Specified by:
getRequester
in interfacePermissionTicket
-
isGranted
public boolean isGranted()- Specified by:
isGranted
in interfacePermissionTicket
-
getCreatedTimestamp
- Specified by:
getCreatedTimestamp
in interfacePermissionTicket
-
getGrantedTimestamp
- Specified by:
getGrantedTimestamp
in interfacePermissionTicket
-
setGrantedTimestamp
- Specified by:
setGrantedTimestamp
in interfacePermissionTicket
-
getResourceServer
Description copied from interface:PermissionTicket
Returns theResourceServer
where this policy belongs to.- Specified by:
getResourceServer
in interfacePermissionTicket
- Returns:
- a resource server
-
getPolicy
- Specified by:
getPolicy
in interfacePermissionTicket
-
setPolicy
- Specified by:
setPolicy
in interfacePermissionTicket
-
getResource
Description copied from interface:PermissionTicket
Returns theResource
associated with this instance- Specified by:
getResource
in interfacePermissionTicket
- Returns:
- the
Resource
associated with this instance
-
getScope
Description copied from interface:PermissionTicket
Returns theScope
associated with this instance- Specified by:
getScope
in interfacePermissionTicket
- Returns:
- the
Scope
associated with this instance
-
equals
-
hashCode
public int hashCode() -
toEntity
public static PermissionTicketEntity toEntity(jakarta.persistence.EntityManager em, PermissionTicket permission)
-