MutableAclProviderInterface.php 1.4 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950
  1. <?php
  2. /*
  3. * This file is part of the Symfony package.
  4. *
  5. * (c) Fabien Potencier <fabien@symfony.com>
  6. *
  7. * For the full copyright and license information, please view the LICENSE
  8. * file that was distributed with this source code.
  9. */
  10. namespace Symfony\Component\Security\Acl\Model;
  11. /**
  12. * Provides support for creating and storing ACL instances.
  13. *
  14. * @author Johannes M. Schmitt <schmittjoh@gmail.com>
  15. */
  16. interface MutableAclProviderInterface extends AclProviderInterface
  17. {
  18. /**
  19. * Creates a new ACL for the given object identity.
  20. *
  21. * @throws AclAlreadyExistsException when there already is an ACL for the given
  22. * object identity
  23. * @param ObjectIdentityInterface $oid
  24. * @return MutableAclInterface
  25. */
  26. public function createAcl(ObjectIdentityInterface $oid);
  27. /**
  28. * Deletes the ACL for a given object identity.
  29. *
  30. * This will automatically trigger a delete for any child ACLs. If you don't
  31. * want child ACLs to be deleted, you will have to set their parent ACL to null.
  32. *
  33. * @param ObjectIdentityInterface $oid
  34. */
  35. public function deleteAcl(ObjectIdentityInterface $oid);
  36. /**
  37. * Persists any changes which were made to the ACL, or any associated
  38. * access control entries.
  39. *
  40. * Changes to parent ACLs are not persisted.
  41. *
  42. * @param MutableAclInterface $acl
  43. */
  44. public function updateAcl(MutableAclInterface $acl);
  45. }