AceConflict.php 786 B

12345678910111213141516171819202122232425262728293031
  1. <?php
  2. declare(strict_types=1);
  3. namespace Sabre\DAVACL\Exception;
  4. use Sabre\DAV;
  5. /**
  6. * This exception is thrown when a client attempts to set conflicting
  7. * permissions.
  8. *
  9. * @copyright Copyright (C) fruux GmbH (https://fruux.com/)
  10. * @author Evert Pot (http://evertpot.com/)
  11. * @license http://sabre.io/license/ Modified BSD License
  12. */
  13. class AceConflict extends DAV\Exception\Conflict
  14. {
  15. /**
  16. * Adds in extra information in the xml response.
  17. *
  18. * This method adds the {DAV:}no-ace-conflict element as defined in rfc3744
  19. */
  20. public function serialize(DAV\Server $server, \DOMElement $errorNode)
  21. {
  22. $doc = $errorNode->ownerDocument;
  23. $np = $doc->createElementNS('DAV:', 'd:no-ace-conflict');
  24. $errorNode->appendChild($np);
  25. }
  26. }