File: MutableAclInterface.php

package info (click to toggle)
php-symfony-security-acl 3.3.4-4
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 1,020 kB
  • sloc: php: 5,160; sql: 273; makefile: 25; xml: 20
file content (108 lines) | stat: -rw-r--r-- 3,172 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
<?php

/*
 * This file is part of the Symfony package.
 *
 * (c) Fabien Potencier <fabien@symfony.com>
 *
 * For the full copyright and license information, please view the LICENSE
 * file that was distributed with this source code.
 */

namespace Symfony\Component\Security\Acl\Model;

/**
 * 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.
 *
 * @author Johannes M. Schmitt <schmittjoh@gmail.com>
 */
interface MutableAclInterface extends AclInterface
{
    /**
     * Deletes a class-based ACE.
     */
    public function deleteClassAce(int $index);

    /**
     * Deletes a class-field-based ACE.
     */
    public function deleteClassFieldAce(int $index, string $field);

    /**
     * Deletes an object-based ACE.
     */
    public function deleteObjectAce(int $index);

    /**
     * Deletes an object-field-based ACE.
     */
    public function deleteObjectFieldAce(int $index, string $field);

    /**
     * Returns the primary key of this ACL.
     *
     * @return int
     */
    public function getId();

    /**
     * Inserts a class-based ACE.
     */
    public function insertClassAce(SecurityIdentityInterface $sid, int $mask, int $index = 0, bool $granting = true, ?string $strategy = null);

    /**
     * Inserts a class-field-based ACE.
     */
    public function insertClassFieldAce(string $field, SecurityIdentityInterface $sid, int $mask, int $index = 0, bool $granting = true, ?string $strategy = null);

    /**
     * Inserts an object-based ACE.
     */
    public function insertObjectAce(SecurityIdentityInterface $sid, int $mask, int $index = 0, bool $granting = true, ?string $strategy = null);

    /**
     * Inserts an object-field-based ACE.
     */
    public function insertObjectFieldAce(string $field, SecurityIdentityInterface $sid, int $mask, int $index = 0, bool $granting = true, ?string $strategy = null);

    /**
     * Sets whether entries are inherited.
     */
    public function setEntriesInheriting(bool $boolean);

    /**
     * Sets the parent ACL.
     */
    public function setParentAcl(?AclInterface $acl = null);

    /**
     * Updates a class-based ACE.
     *
     * @param string|null $strategy if null the strategy should not be changed
     */
    public function updateClassAce(int $index, int $mask, ?string $strategy = null);

    /**
     * Updates a class-field-based ACE.
     *
     * @param string|null $strategy if null the strategy should not be changed
     */
    public function updateClassFieldAce(int $index, string $field, int $mask, ?string $strategy = null);

    /**
     * Updates an object-based ACE.
     *
     * @param string|null $strategy if null the strategy should not be changed
     */
    public function updateObjectAce(int $index, int $mask, ?string $strategy = null);

    /**
     * Updates an object-field-based ACE.
     *
     * @param string|null $strategy if null the strategy should not be changed
     */
    public function updateObjectFieldAce(int $index, string $field, int $mask, ?string $strategy = null);
}