You are here

class JwtAuthBaseEvent in JSON Web Token Authentication (JWT) 8.0

Same name and namespace in other branches
  1. 8 src/Authentication/Event/JwtAuthBaseEvent.php \Drupal\jwt\Authentication\Event\JwtAuthBaseEvent

Class JwtAuthBaseEvent.

@package Drupal\jwt\Authentication\Event

Hierarchy

  • class \Drupal\jwt\Authentication\Event\JwtAuthBaseEvent extends \Symfony\Component\EventDispatcher\Event

Expanded class hierarchy of JwtAuthBaseEvent

File

src/Authentication/Event/JwtAuthBaseEvent.php, line 13

Namespace

Drupal\jwt\Authentication\Event
View source
class JwtAuthBaseEvent extends Event {

  /**
   * The JsonWebToken.
   *
   * @var \Drupal\jwt\JsonWebToken\JsonWebTokenInterface
   */
  protected $jwt;

  /**
   * Constructs a JwtAuthEvent with a JsonWebToken.
   *
   * @param \Drupal\jwt\JsonWebToken\JsonWebTokenInterface $token
   *   A decoded JWT.
   */
  public function __construct(JsonWebTokenInterface $token) {
    $this->jwt = $token;
  }

  /**
   * Returns the JWT.
   *
   * @return \Drupal\jwt\JsonWebToken\JsonWebTokenInterface
   *   Returns the token.
   */
  public function getToken() {
    return $this->jwt;
  }

}

Members

Namesort descending Modifiers Type Description Overrides
JwtAuthBaseEvent::$jwt protected property The JsonWebToken.
JwtAuthBaseEvent::getToken public function Returns the JWT.
JwtAuthBaseEvent::__construct public function Constructs a JwtAuthEvent with a JsonWebToken. 1