44 $this->value = $shareAccess;
80 switch ($this->value) {
82 case SharingPlugin::ACCESS_NOTSHARED :
85 case SharingPlugin::ACCESS_SHAREDOWNER :
88 case SharingPlugin::ACCESS_READ :
91 case SharingPlugin::ACCESS_READWRITE :
94 case SharingPlugin::ACCESS_NOACCESS :
126 foreach ($elems as $elem) {
127 switch ($elem[
'name']) {
128 case '{DAV:}not-shared' :
129 return new self(SharingPlugin::ACCESS_NOTSHARED);
130 case '{DAV:}shared-owner' :
131 return new self(SharingPlugin::ACCESS_SHAREDOWNER);
133 return new self(SharingPlugin::ACCESS_READ);
134 case '{DAV:}read-write' :
135 return new self(SharingPlugin::ACCESS_READWRITE);
136 case '{DAV:}no-access' :
137 return new self(SharingPlugin::ACCESS_NOACCESS);
140 throw new BadRequest(
'Invalid value for {DAV:}share-access element');
parseInnerTree(array $elementMap=null)
Parses all elements below the current element.
xmlSerialize(Writer $writer)
The xmlSerialize method is called during xml writing.
The Reader class expands upon PHP's built-in XMLReader.
getValue()
Returns the current value.
This is the XML element interface.
static xmlDeserialize(Reader $reader)
The deserialize method is called during xml parsing.
__construct($shareAccess)
Creates the property.
This class represents the {DAV:}share-access property.
writeElement($name, $content=null)
Write a full element tag and it's contents.