You are here

public function RevocableTokenRepositoryTrait::getNew in Simple OAuth (OAuth2) & OpenID Connect 5.x

Same name and namespace in other branches
  1. 8.4 src/Repositories/RevocableTokenRepositoryTrait.php \Drupal\simple_oauth\Repositories\RevocableTokenRepositoryTrait::getNew()
  2. 8.2 src/Repositories/RevocableTokenRepositoryTrait.php \Drupal\simple_oauth\Repositories\RevocableTokenRepositoryTrait::getNew()
  3. 8.3 src/Repositories/RevocableTokenRepositoryTrait.php \Drupal\simple_oauth\Repositories\RevocableTokenRepositoryTrait::getNew()
2 calls to RevocableTokenRepositoryTrait::getNew()
AuthCodeRepository::getNewAuthCode in src/Repositories/AuthCodeRepository.php
RefreshTokenRepository::getNewRefreshToken in src/Repositories/RefreshTokenRepository.php

File

src/Repositories/RevocableTokenRepositoryTrait.php, line 104

Class

RevocableTokenRepositoryTrait
Common methods for token repositories on different grants.

Namespace

Drupal\simple_oauth\Repositories

Code

public function getNew() {
  $class = static::$entityClass;
  return new $class();
}