Source of file RequiresAuthenticator.php
Size: 0,809 Bytes - Last Modified: 2021-12-24T06:47:35+00:00
/var/www/docs.ssmods.com/process/src/src/Helpers/RequiresAuthenticator.php
12345678910111213141516171819202122232425262728293031323334353637 | <?php declare(strict_types=1); namespace Firesphere\GraphQLJWT\Helpers; use Firesphere\GraphQLJWT\Authentication\JWTAuthenticator; /** * Parent class requires a JWTAuthenticator instance to be injected */ trait RequiresAuthenticator { /** * @var JWTAuthenticator|null */ protected $jwtAuthenticator = null; /** * @return JWTAuthenticator|null */ protected function getJWTAuthenticator(): ?JWTAuthenticator { return $this->jwtAuthenticator; } /** * Inject authenticator this mutation should use * * @param JWTAuthenticator $authenticator * @return $this */ public function setJWTAuthenticator(JWTAuthenticator $authenticator): self { $this->jwtAuthenticator = $authenticator; return $this; } } |