70 throw new DAV\Exception\MethodNotAllowed();
81 throw new DAV\Exception\MethodNotAllowed();
107 throw new DAV\Exception\MethodNotAllowed(
'Creating new files in this collection is not supported');
121 throw new DAV\Exception\MethodNotAllowed(
'Creating new collections in this collection is not supported');
135 if (
$name == $child->getName())
139 throw new DAV\Exception\NotFound(
'Addressbook with name \'' .
$name .
'\' could not be found
'); 148 function getChildren() { 150 $addressbooks = $this->carddavBackend->getAddressBooksForUser($this->principalUri); 152 foreach ($addressbooks as $addressbook) { 153 $objs[] = new AddressBook($this->carddavBackend, $addressbook); 167 function createExtendedCollection($name, MkCol $mkCol) { 169 if (!$mkCol->hasResourceType('{
' . Plugin::NS_CARDDAV . '}addressbook
')) { 170 throw new DAV\Exception\InvalidResourceType('Unknown resourceType
for this collection
'); 172 $properties = $mkCol->getRemainingValues(); 173 $mkCol->setRemainingResultCode(201); 174 $this->carddavBackend->createAddressBook($this->principalUri, $name, $properties); 185 function getOwner() { 187 return $this->principalUri;
createDirectory($filename)
Creates a new directory under this object.
split($path)
Returns the 'dirname' and 'basename' for a path.
The IExtendedCollection interface.
createFile($filename, $data=null)
Creates a new file under this object.
getName()
Returns the name of this object.
setName($name)
Updates the name of this object.
getChild($name)
Returns a single addressbook, by name.
getChildren()
Returns a list of addressbooks.
__construct(Backend\BackendInterface $carddavBackend, $principalUri)
Constructor.
getLastModified()
Returns the last modification date.