public function JsonWebToken::getClaim in JSON Web Token Authentication (JWT) 8
Same name and namespace in other branches
- 8.0 src/JsonWebToken/JsonWebToken.php \Drupal\jwt\JsonWebToken\JsonWebToken::getClaim()
Retrieve a claim from the JWT payload.
@returns mixed The contents of the claim.
Parameters
mixed $claim: Either a string or indexed array of strings (if nested) representing the claim to retrieve. If an indexed array is passed, it will be used to traverse the JWT where the 0th element is the topmost claim.
Overrides JsonWebTokenInterface::getClaim
File
- src/
JsonWebToken/ JsonWebToken.php, line 40
Class
- JsonWebToken
- Class JsonWebToken.
Namespace
Drupal\jwt\JsonWebTokenCode
public function getClaim($claim) {
$payload = $this->payload;
return $this
->internalGetClaim($payload, $claim);
}