AccessTokenServiceInterface
extends
DbServiceInterface
in
Database service interface for access tokens.
Tags
Table of Contents
- getByIdAndType() : AccessTokenEntityInterface|null
- Retrieve an object from the database based on id and type; create a new row if no existing match is found.
- getNonce() : string|null
- Retrieve an OpenID nonce for a user
- persistEntity() : void
- Persist an entity.
- storeNonce() : void
- Add or replace an OpenID nonce for a user
Methods
getByIdAndType()
Retrieve an object from the database based on id and type; create a new row if no existing match is found.
public
getByIdAndType(string $id, string $type[, bool $create = true ]) : AccessTokenEntityInterface|null
Parameters
- $id : string
-
Token ID
- $type : string
-
Token type
- $create : bool = true
-
Should we create rows that don't already exist?
Return values
AccessTokenEntityInterface|null —getNonce()
Retrieve an OpenID nonce for a user
public
getNonce(int $userId) : string|null
Parameters
- $userId : int
-
User ID
Return values
string|null —persistEntity()
Persist an entity.
public
persistEntity(EntityInterface $entity) : void
Parameters
- $entity : EntityInterface
-
Entity to persist.
Return values
void —storeNonce()
Add or replace an OpenID nonce for a user
public
storeNonce(int $userId, string|null $nonce) : void
Parameters
- $userId : int
-
User ID
- $nonce : string|null
-
Nonce