AuthenticatedVoter
in package
implements
CacheableVoterInterface
AuthenticatedVoter votes if an attribute like IS_AUTHENTICATED_FULLY, IS_AUTHENTICATED_REMEMBERED, IS_AUTHENTICATED is present.
This list is most restrictive to least restrictive checking.
Tags
Table of Contents
Interfaces
- CacheableVoterInterface
- Let voters expose the attributes and types they care about.
Constants
- IS_AUTHENTICATED = 'IS_AUTHENTICATED'
- IS_AUTHENTICATED_FULLY = 'IS_AUTHENTICATED_FULLY'
- IS_AUTHENTICATED_REMEMBERED = 'IS_AUTHENTICATED_REMEMBERED'
- IS_IMPERSONATOR = 'IS_IMPERSONATOR'
- IS_REMEMBERED = 'IS_REMEMBERED'
- PUBLIC_ACCESS = 'PUBLIC_ACCESS'
Properties
- $authenticationTrustResolver : mixed
Methods
- __construct() : mixed
- supportsAttribute() : bool
- supportsType() : bool
- vote() : int
- {@inheritdoc}
Constants
IS_AUTHENTICATED
public
mixed
IS_AUTHENTICATED
= 'IS_AUTHENTICATED'
IS_AUTHENTICATED_FULLY
public
mixed
IS_AUTHENTICATED_FULLY
= 'IS_AUTHENTICATED_FULLY'
IS_AUTHENTICATED_REMEMBERED
public
mixed
IS_AUTHENTICATED_REMEMBERED
= 'IS_AUTHENTICATED_REMEMBERED'
IS_IMPERSONATOR
public
mixed
IS_IMPERSONATOR
= 'IS_IMPERSONATOR'
IS_REMEMBERED
public
mixed
IS_REMEMBERED
= 'IS_REMEMBERED'
PUBLIC_ACCESS
public
mixed
PUBLIC_ACCESS
= 'PUBLIC_ACCESS'
Properties
$authenticationTrustResolver
private
mixed
$authenticationTrustResolver
Methods
__construct()
public
__construct(AuthenticationTrustResolverInterface $authenticationTrustResolver) : mixed
Parameters
- $authenticationTrustResolver : AuthenticationTrustResolverInterface
supportsAttribute()
public
supportsAttribute(string $attribute) : bool
Parameters
- $attribute : string
Return values
boolsupportsType()
public
supportsType(string $subjectType) : bool
Parameters
- $subjectType : string
-
The type of the subject inferred by
get_class
orget_debug_type
Return values
boolvote()
{@inheritdoc}
public
vote(TokenInterface $token, mixed $subject, array<string|int, mixed> $attributes) : int
Parameters
- $token : TokenInterface
- $subject : mixed
- $attributes : array<string|int, mixed>