Symfony2 API
Interface

Symfony\Component\Security\Acl\Model\MutableAclInterface

interface MutableAclInterface implements AclInterface

This interface adds mutators for the AclInterface.

All changes to Access Control Entries must go through this interface. Access Control Entries must never be modified directly.

Methods

array getClassAces()

Returns all class-based ACEs associated with this ACL

from AclInterface
array getClassFieldAces(string $field)

Returns all class-field-based ACEs associated with this ACL

from AclInterface
array getObjectAces()

Returns all object-based ACEs associated with this ACL

from AclInterface
array getObjectFieldAces(string $field)

Returns all object-field-based ACEs associated with this ACL

from AclInterface
ObjectIdentityInterface getObjectIdentity()

Returns the object identity associated with this ACL

from AclInterface
AclInterface|null getParentAcl()

Returns the parent ACL, or null if there is none.

from AclInterface
bool isEntriesInheriting()

Whether this ACL is inheriting ACEs from a parent ACL.

from AclInterface
bool isFieldGranted(string $field, array $masks, array $securityIdentities, bool $administrativeMode = false)

Determines whether field access is granted

from AclInterface
bool isGranted(array $masks, array $securityIdentities, bool $administrativeMode = false)

Determines whether access is granted

from AclInterface
bool isSidLoaded(mixed $securityIdentities)

Whether the ACL has loaded ACEs for all of the passed security identities

from AclInterface
deleteClassAce(int $index)

Deletes a class-based ACE

deleteClassFieldAce(int $index, string $field)

Deletes a class-field-based ACE

deleteObjectAce(int $index)

Deletes an object-based ACE

deleteObjectFieldAce(int $index, string $field)

Deletes an object-field-based ACE

int getId()

Returns the primary key of this ACL

insertClassAce(SecurityIdentityInterface $sid, int $mask, int $index, bool $granting = true, string $strategy = null)

Inserts a class-based ACE

insertClassFieldAce(string $field, SecurityIdentityInterface $sid, int $mask, int $index, bool $granting = true, string $strategy = null)

Inserts a class-field-based ACE

insertObjectAce(SecurityIdentityInterface $sid, int $mask, int $index, bool $granting = true, string $strategy = null)

Inserts an object-based ACE

insertObjectFieldAce(string $field, SecurityIdentityInterface $sid, int $mask, int $index, bool $granting = true, string $strategy = null)

Inserts an object-field-based ACE

setEntriesInheriting(bool $boolean)

Sets whether entries are inherited

setParentAcl(AclInterface $acl = null)

Sets the parent ACL

updateClassAce(int $index, int $mask, string $strategy = null)

Updates a class-based ACE

updateClassFieldAce(int $index, string $field, int $mask, string $strategy = null)

Updates a class-field-based ACE

updateObjectAce(int $index, int $mask, string $strategy = null)

Updates an object-based ACE

updateObjectFieldAce(int $index, string $field, int $mask, string $strategy = null)

Updates an object-field-based ACE

Details

in AclInterface at line 33
public array getClassAces()

Returns all class-based ACEs associated with this ACL

Return Value

array

in AclInterface at line 42
public array getClassFieldAces(string $field)

Returns all class-field-based ACEs associated with this ACL

Parameters

string $field

Return Value

array

in AclInterface at line 49
public array getObjectAces()

Returns all object-based ACEs associated with this ACL

Return Value

array

in AclInterface at line 58
public array getObjectFieldAces(string $field)

Returns all object-field-based ACEs associated with this ACL

Parameters

string $field

Return Value

array

in AclInterface at line 65
public ObjectIdentityInterface getObjectIdentity()

Returns the object identity associated with this ACL

in AclInterface at line 72
public AclInterface|null getParentAcl()

Returns the parent ACL, or null if there is none.

Return Value

AclInterface|null

in AclInterface at line 79
public bool isEntriesInheriting()

Whether this ACL is inheriting ACEs from a parent ACL.

Return Value

bool

in AclInterface at line 91
public bool isFieldGranted(string $field, array $masks, array $securityIdentities, bool $administrativeMode = false)

Determines whether field access is granted

Parameters

string $field
array $masks
array $securityIdentities
bool $administrativeMode

Return Value

bool

in AclInterface at line 104
public bool isGranted(array $masks, array $securityIdentities, bool $administrativeMode = false)

Determines whether access is granted

Parameters

array $masks
array $securityIdentities
bool $administrativeMode

Return Value

bool

Exceptions

NoAceFoundException when no ACE was applicable for this request

in AclInterface at line 113
public bool isSidLoaded(mixed $securityIdentities)

Whether the ACL has loaded ACEs for all of the passed security identities

Parameters

mixed $securityIdentities an implementation of SecurityIdentityInterface, or an array thereof

Return Value

bool

at line 29
public deleteClassAce(int $index)

Deletes a class-based ACE

Parameters

int $index

at line 37
public deleteClassFieldAce(int $index, string $field)

Deletes a class-field-based ACE

Parameters

int $index
string $field

at line 44
public deleteObjectAce(int $index)

Deletes an object-based ACE

Parameters

int $index

at line 52
public deleteObjectFieldAce(int $index, string $field)

Deletes an object-field-based ACE

Parameters

int $index
string $field

at line 59
public int getId()

Returns the primary key of this ACL

Return Value

int

at line 70
public insertClassAce(SecurityIdentityInterface $sid, int $mask, int $index, bool $granting = true, string $strategy = null)

Inserts a class-based ACE

Parameters

SecurityIdentityInterface $sid
int $mask
int $index
bool $granting
string $strategy

at line 82
public insertClassFieldAce(string $field, SecurityIdentityInterface $sid, int $mask, int $index, bool $granting = true, string $strategy = null)

Inserts a class-field-based ACE

Parameters

string $field
SecurityIdentityInterface $sid
int $mask
int $index
bool $granting
string $strategy

at line 93
public insertObjectAce(SecurityIdentityInterface $sid, int $mask, int $index, bool $granting = true, string $strategy = null)

Inserts an object-based ACE

Parameters

SecurityIdentityInterface $sid
int $mask
int $index
bool $granting
string $strategy

at line 105
public insertObjectFieldAce(string $field, SecurityIdentityInterface $sid, int $mask, int $index, bool $granting = true, string $strategy = null)

Inserts an object-field-based ACE

Parameters

string $field
SecurityIdentityInterface $sid
int $mask
int $index
bool $granting
string $strategy

at line 112
public setEntriesInheriting(bool $boolean)

Sets whether entries are inherited

Parameters

bool $boolean

at line 119
public setParentAcl(AclInterface $acl = null)

Sets the parent ACL

Parameters

AclInterface $acl

at line 128
public updateClassAce(int $index, int $mask, string $strategy = null)

Updates a class-based ACE

Parameters

int $index
int $mask
string $strategy if null the strategy should not be changed

at line 138
public updateClassFieldAce(int $index, string $field, int $mask, string $strategy = null)

Updates a class-field-based ACE

Parameters

int $index
string $field
int $mask
string $strategy if null the strategy should not be changed

at line 147
public updateObjectAce(int $index, int $mask, string $strategy = null)

Updates an object-based ACE

Parameters

int $index
int $mask
string $strategy if null the strategy should not be changed

at line 157
public updateObjectFieldAce(int $index, string $field, int $mask, string $strategy = null)

Updates an object-field-based ACE

Parameters

int $index
string $field
int $mask
string $strategy if null the strategy should not be changed