ILIAS  release_5-4 Revision v5.4.26-12-gabc799a52e6
MockPrincipal.php
Go to the documentation of this file.
1<?php
2
3namespace Sabre\DAVACL;
4
5use Sabre\DAV;
6
7class MockPrincipal extends DAV\Node implements IPrincipal {
8
9 public $name;
11 public $groupMembership = [];
12 public $groupMemberSet = [];
13
14 function __construct($name, $principalUrl, array $groupMembership = [], array $groupMemberSet = []) {
15
16 $this->name = $name;
17 $this->principalUrl = $principalUrl;
18 $this->groupMembership = $groupMembership;
19 $this->groupMemberSet = $groupMemberSet;
20
21 }
22
23 function getName() {
24
25 return $this->name;
26
27 }
28
29 function getDisplayName() {
30
31 return $this->getName();
32
33 }
34
35 function getAlternateUriSet() {
36
37 return [];
38
39 }
40
41 function getPrincipalUrl() {
42
44
45 }
46
47 function getGroupMemberSet() {
48
50
51 }
52
53 function getGroupMemberShip() {
54
56
57 }
58
60
61 $this->groupMemberSet = $groupMemberSet;
62
63 }
64}
An exception for terminatinating execution or to throw for unit testing.
getGroupMemberSet()
Returns the list of group members.
setGroupMemberSet(array $groupMemberSet)
Sets a list of group members.
getPrincipalUrl()
Returns the full principal url.
__construct($name, $principalUrl, array $groupMembership=[], array $groupMemberSet=[])
getName()
Returns the name of the node.
getAlternateUriSet()
Returns a list of alternative urls for a principal.
getDisplayName()
Returns the displayname.
Node class.
Definition: Node.php:14
IPrincipal interface.
Definition: IPrincipal.php:16