summaryrefslogtreecommitdiffstats
path: root/apps/dav/lib
diff options
context:
space:
mode:
Diffstat (limited to 'apps/dav/lib')
-rw-r--r--apps/dav/lib/AppInfo/Application.php170
-rw-r--r--apps/dav/lib/CalDAV/BirthdayService.php (renamed from apps/dav/lib/caldav/birthdayservice.php)0
-rw-r--r--apps/dav/lib/CalDAV/CalDavBackend.php (renamed from apps/dav/lib/caldav/caldavbackend.php)0
-rw-r--r--apps/dav/lib/CalDAV/Calendar.php (renamed from apps/dav/lib/caldav/calendar.php)0
-rw-r--r--apps/dav/lib/CalDAV/CalendarHome.php (renamed from apps/dav/lib/caldav/calendarhome.php)0
-rw-r--r--apps/dav/lib/CalDAV/CalendarRoot.php (renamed from apps/dav/lib/caldav/calendarroot.php)0
-rw-r--r--apps/dav/lib/CalDAV/Schedule/IMipPlugin.php (renamed from apps/dav/lib/caldav/schedule/imipplugin.php)0
-rw-r--r--apps/dav/lib/CardDAV/AddressBook.php (renamed from apps/dav/lib/carddav/addressbook.php)0
-rw-r--r--apps/dav/lib/CardDAV/AddressBookImpl.php (renamed from apps/dav/lib/carddav/addressbookimpl.php)0
-rw-r--r--apps/dav/lib/CardDAV/AddressBookRoot.php (renamed from apps/dav/lib/carddav/addressbookroot.php)0
-rw-r--r--apps/dav/lib/CardDAV/CardDavBackend.php (renamed from apps/dav/lib/carddav/carddavbackend.php)0
-rw-r--r--apps/dav/lib/CardDAV/ContactsManager.php (renamed from apps/dav/lib/carddav/contactsmanager.php)0
-rw-r--r--apps/dav/lib/CardDAV/Converter.php (renamed from apps/dav/lib/carddav/converter.php)0
-rw-r--r--apps/dav/lib/CardDAV/Plugin.php (renamed from apps/dav/lib/carddav/plugin.php)0
-rw-r--r--apps/dav/lib/CardDAV/SyncJob.php (renamed from apps/dav/lib/carddav/syncjob.php)2
-rw-r--r--apps/dav/lib/CardDAV/SyncService.php (renamed from apps/dav/lib/carddav/syncservice.php)0
-rw-r--r--apps/dav/lib/CardDAV/UserAddressBooks.php (renamed from apps/dav/lib/carddav/useraddressbooks.php)0
-rw-r--r--apps/dav/lib/CardDAV/Xml/Groups.php (renamed from apps/dav/lib/carddav/xml/groups.php)0
-rw-r--r--apps/dav/lib/Command/CreateAddressBook.php77
-rw-r--r--apps/dav/lib/Command/CreateCalendar.php81
-rw-r--r--apps/dav/lib/Command/SyncBirthdayCalendar.php85
-rw-r--r--apps/dav/lib/Command/SyncSystemAddressBook.php65
-rw-r--r--apps/dav/lib/Comments/CommentNode.php (renamed from apps/dav/lib/comments/commentnode.php)0
-rw-r--r--apps/dav/lib/Comments/CommentsPlugin.php (renamed from apps/dav/lib/comments/commentsplugin.php)0
-rw-r--r--apps/dav/lib/Comments/EntityCollection.php (renamed from apps/dav/lib/comments/entitycollection.php)0
-rw-r--r--apps/dav/lib/Comments/EntityTypeCollection.php (renamed from apps/dav/lib/comments/entitytypecollection.php)0
-rw-r--r--apps/dav/lib/Comments/RootCollection.php (renamed from apps/dav/lib/comments/rootcollection.php)0
-rw-r--r--apps/dav/lib/Connector/LegacyDAVACL.php (renamed from apps/dav/lib/connector/legacydavacl.php)0
-rw-r--r--apps/dav/lib/Connector/PublicAuth.php (renamed from apps/dav/lib/connector/publicauth.php)0
-rw-r--r--apps/dav/lib/Connector/Sabre/AppEnabledPlugin.php (renamed from apps/dav/lib/connector/sabre/appenabledplugin.php)0
-rw-r--r--apps/dav/lib/Connector/Sabre/Auth.php (renamed from apps/dav/lib/connector/sabre/auth.php)0
-rw-r--r--apps/dav/lib/Connector/Sabre/BlockLegacyClientPlugin.php (renamed from apps/dav/lib/connector/sabre/blocklegacyclientplugin.php)0
-rw-r--r--apps/dav/lib/Connector/Sabre/ChecksumList.php (renamed from apps/dav/lib/connector/sabre/checksumlist.php)0
-rw-r--r--apps/dav/lib/Connector/Sabre/CommentPropertiesPlugin.php (renamed from apps/dav/lib/connector/sabre/commentpropertiesplugin.php)0
-rw-r--r--apps/dav/lib/Connector/Sabre/CopyEtagHeaderPlugin.php (renamed from apps/dav/lib/connector/sabre/copyetagheaderplugin.php)0
-rw-r--r--apps/dav/lib/Connector/Sabre/CustomPropertiesBackend.php (renamed from apps/dav/lib/connector/sabre/custompropertiesbackend.php)0
-rw-r--r--apps/dav/lib/Connector/Sabre/DavAclPlugin.php (renamed from apps/dav/lib/connector/sabre/davaclplugin.php)0
-rw-r--r--apps/dav/lib/Connector/Sabre/Directory.php (renamed from apps/dav/lib/connector/sabre/directory.php)0
-rw-r--r--apps/dav/lib/Connector/Sabre/DummyGetResponsePlugin.php (renamed from apps/dav/lib/connector/sabre/dummygetresponseplugin.php)0
-rw-r--r--apps/dav/lib/Connector/Sabre/Exception/EntityTooLarge.php (renamed from apps/dav/lib/connector/sabre/exception/entitytoolarge.php)0
-rw-r--r--apps/dav/lib/Connector/Sabre/Exception/FileLocked.php (renamed from apps/dav/lib/connector/sabre/exception/filelocked.php)0
-rw-r--r--apps/dav/lib/Connector/Sabre/Exception/Forbidden.php (renamed from apps/dav/lib/connector/sabre/exception/forbidden.php)0
-rw-r--r--apps/dav/lib/Connector/Sabre/Exception/InvalidPath.php (renamed from apps/dav/lib/connector/sabre/exception/invalidpath.php)0
-rw-r--r--apps/dav/lib/Connector/Sabre/Exception/UnsupportedMediaType.php (renamed from apps/dav/lib/connector/sabre/exception/unsupportedmediatype.php)0
-rw-r--r--apps/dav/lib/Connector/Sabre/ExceptionLoggerPlugin.php (renamed from apps/dav/lib/connector/sabre/exceptionloggerplugin.php)0
-rw-r--r--apps/dav/lib/Connector/Sabre/FakeLockerPlugin.php (renamed from apps/dav/lib/connector/sabre/fakelockerplugin.php)0
-rw-r--r--apps/dav/lib/Connector/Sabre/File.php (renamed from apps/dav/lib/connector/sabre/file.php)0
-rw-r--r--apps/dav/lib/Connector/Sabre/FilesPlugin.php (renamed from apps/dav/lib/connector/sabre/filesplugin.php)0
-rw-r--r--apps/dav/lib/Connector/Sabre/FilesReportPlugin.php (renamed from apps/dav/lib/connector/sabre/filesreportplugin.php)0
-rw-r--r--apps/dav/lib/Connector/Sabre/LockPlugin.php (renamed from apps/dav/lib/connector/sabre/lockplugin.php)0
-rw-r--r--apps/dav/lib/Connector/Sabre/MaintenancePlugin.php (renamed from apps/dav/lib/connector/sabre/maintenanceplugin.php)0
-rw-r--r--apps/dav/lib/Connector/Sabre/Node.php (renamed from apps/dav/lib/connector/sabre/node.php)0
-rw-r--r--apps/dav/lib/Connector/Sabre/ObjectTree.php (renamed from apps/dav/lib/connector/sabre/objecttree.php)0
-rw-r--r--apps/dav/lib/Connector/Sabre/Principal.php (renamed from apps/dav/lib/connector/sabre/principal.php)0
-rw-r--r--apps/dav/lib/Connector/Sabre/QuotaPlugin.php (renamed from apps/dav/lib/connector/sabre/quotaplugin.php)0
-rw-r--r--apps/dav/lib/Connector/Sabre/Server.php (renamed from apps/dav/lib/connector/sabre/server.php)0
-rw-r--r--apps/dav/lib/Connector/Sabre/ServerFactory.php (renamed from apps/dav/lib/connector/sabre/serverfactory.php)0
-rw-r--r--apps/dav/lib/Connector/Sabre/ShareTypeList.php (renamed from apps/dav/lib/connector/sabre/sharetypelist.php)0
-rw-r--r--apps/dav/lib/Connector/Sabre/SharesPlugin.php (renamed from apps/dav/lib/connector/sabre/sharesplugin.php)0
-rw-r--r--apps/dav/lib/Connector/Sabre/TagList.php (renamed from apps/dav/lib/connector/sabre/taglist.php)0
-rw-r--r--apps/dav/lib/Connector/Sabre/TagsPlugin.php (renamed from apps/dav/lib/connector/sabre/tagsplugin.php)0
-rw-r--r--apps/dav/lib/DAV/GroupPrincipalBackend.php (renamed from apps/dav/lib/dav/groupprincipalbackend.php)0
-rw-r--r--apps/dav/lib/DAV/Sharing/Backend.php (renamed from apps/dav/lib/dav/sharing/backend.php)0
-rw-r--r--apps/dav/lib/DAV/Sharing/IShareable.php (renamed from apps/dav/lib/dav/sharing/ishareable.php)0
-rw-r--r--apps/dav/lib/DAV/Sharing/Plugin.php (renamed from apps/dav/lib/dav/sharing/plugin.php)0
-rw-r--r--apps/dav/lib/DAV/Sharing/Xml/Invite.php (renamed from apps/dav/lib/dav/sharing/xml/invite.php)0
-rw-r--r--apps/dav/lib/DAV/Sharing/Xml/ShareRequest.php (renamed from apps/dav/lib/dav/sharing/xml/sharerequest.php)0
-rw-r--r--apps/dav/lib/DAV/SystemPrincipalBackend.php (renamed from apps/dav/lib/dav/systemprincipalbackend.php)0
-rw-r--r--apps/dav/lib/Files/BrowserErrorPagePlugin.php (renamed from apps/dav/lib/files/browsererrorpageplugin.php)0
-rw-r--r--apps/dav/lib/Files/CustomPropertiesBackend.php (renamed from apps/dav/lib/files/custompropertiesbackend.php)0
-rw-r--r--apps/dav/lib/Files/FilesHome.php (renamed from apps/dav/lib/files/fileshome.php)0
-rw-r--r--apps/dav/lib/Files/RootCollection.php (renamed from apps/dav/lib/files/rootcollection.php)0
-rw-r--r--apps/dav/lib/Files/Sharing/PublicLinkCheckPlugin.php (renamed from apps/dav/lib/files/sharing/publiclinkcheckplugin.php)0
-rw-r--r--apps/dav/lib/HookManager.php (renamed from apps/dav/lib/hookmanager.php)0
-rw-r--r--apps/dav/lib/RootCollection.php (renamed from apps/dav/lib/rootcollection.php)0
-rw-r--r--apps/dav/lib/Server.php (renamed from apps/dav/lib/server.php)0
-rw-r--r--apps/dav/lib/SystemTag/SystemTagMappingNode.php (renamed from apps/dav/lib/systemtag/systemtagmappingnode.php)0
-rw-r--r--apps/dav/lib/SystemTag/SystemTagNode.php (renamed from apps/dav/lib/systemtag/systemtagnode.php)0
-rw-r--r--apps/dav/lib/SystemTag/SystemTagPlugin.php (renamed from apps/dav/lib/systemtag/systemtagplugin.php)0
-rw-r--r--apps/dav/lib/SystemTag/SystemTagsByIdCollection.php (renamed from apps/dav/lib/systemtag/systemtagsbyidcollection.php)0
-rw-r--r--apps/dav/lib/SystemTag/SystemTagsObjectMappingCollection.php (renamed from apps/dav/lib/systemtag/systemtagsobjectmappingcollection.php)0
-rw-r--r--apps/dav/lib/SystemTag/SystemTagsObjectTypeCollection.php (renamed from apps/dav/lib/systemtag/systemtagsobjecttypecollection.php)0
-rw-r--r--apps/dav/lib/SystemTag/SystemTagsRelationsCollection.php (renamed from apps/dav/lib/systemtag/systemtagsrelationscollection.php)0
-rw-r--r--apps/dav/lib/Upload/AssemblyStream.php (renamed from apps/dav/lib/upload/assemblystream.php)0
-rw-r--r--apps/dav/lib/Upload/FutureFile.php (renamed from apps/dav/lib/upload/futurefile.php)0
-rw-r--r--apps/dav/lib/Upload/RootCollection.php (renamed from apps/dav/lib/upload/rootcollection.php)0
-rw-r--r--apps/dav/lib/Upload/UploadFolder.php (renamed from apps/dav/lib/upload/uploadfolder.php)0
-rw-r--r--apps/dav/lib/Upload/UploadHome.php (renamed from apps/dav/lib/upload/uploadhome.php)0
88 files changed, 479 insertions, 1 deletions
diff --git a/apps/dav/lib/AppInfo/Application.php b/apps/dav/lib/AppInfo/Application.php
new file mode 100644
index 00000000000..d44ea22e2f3
--- /dev/null
+++ b/apps/dav/lib/AppInfo/Application.php
@@ -0,0 +1,170 @@
+<?php
+/**
+ * @author Björn Schießle <schiessle@owncloud.com>
+ * @author Thomas Müller <thomas.mueller@tmit.eu>
+ *
+ * @copyright Copyright (c) 2016, ownCloud, Inc.
+ * @license AGPL-3.0
+ *
+ * This code is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU Affero General Public License, version 3,
+ * as published by the Free Software Foundation.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Affero General Public License for more details.
+ *
+ * You should have received a copy of the GNU Affero General Public License, version 3,
+ * along with this program. If not, see <http://www.gnu.org/licenses/>
+ *
+ */
+namespace OCA\DAV\AppInfo;
+
+use OCA\DAV\CalDAV\BirthdayService;
+use OCA\DAV\CalDAV\CalDavBackend;
+use OCA\DAV\CardDAV\CardDavBackend;
+use OCA\DAV\CardDAV\ContactsManager;
+use OCA\DAV\CardDAV\SyncJob;
+use OCA\DAV\CardDAV\SyncService;
+use OCA\DAV\Connector\Sabre\Principal;
+use OCA\DAV\DAV\GroupPrincipalBackend;
+use OCA\DAV\HookManager;
+use \OCP\AppFramework\App;
+use OCP\AppFramework\IAppContainer;
+use OCP\Contacts\IManager;
+use OCP\IUser;
+use Symfony\Component\EventDispatcher\GenericEvent;
+
+class Application extends App {
+
+ /**
+ * Application constructor.
+ *
+ * @param array $urlParams
+ */
+ public function __construct (array $urlParams=array()) {
+ parent::__construct('dav', $urlParams);
+
+ $container = $this->getContainer();
+ $container->registerService('ContactsManager', function($c) {
+ /** @var IAppContainer $c */
+ return new ContactsManager(
+ $c->query('CardDavBackend')
+ );
+ });
+
+ $container->registerService('HookManager', function($c) {
+ /** @var IAppContainer $c */
+ return new HookManager(
+ $c->getServer()->getUserManager(),
+ $c->query('SyncService'),
+ $c->query('CalDavBackend'),
+ $c->query('CardDavBackend')
+ );
+ });
+
+ $container->registerService('SyncService', function($c) {
+ /** @var IAppContainer $c */
+ return new SyncService(
+ $c->query('CardDavBackend'),
+ $c->getServer()->getUserManager(),
+ $c->getServer()->getLogger()
+ );
+ });
+
+ $container->registerService('CardDavBackend', function($c) {
+ /** @var IAppContainer $c */
+ $db = $c->getServer()->getDatabaseConnection();
+ $dispatcher = $c->getServer()->getEventDispatcher();
+ $principal = new Principal(
+ $c->getServer()->getUserManager(),
+ $c->getServer()->getGroupManager()
+ );
+ return new CardDavBackend($db, $principal, $dispatcher);
+ });
+
+ $container->registerService('CalDavBackend', function($c) {
+ /** @var IAppContainer $c */
+ $db = $c->getServer()->getDatabaseConnection();
+ $principal = new Principal(
+ $c->getServer()->getUserManager(),
+ $c->getServer()->getGroupManager()
+ );
+ return new CalDavBackend($db, $principal);
+ });
+
+ $container->registerService('BirthdayService', function($c) {
+ /** @var IAppContainer $c */
+ $g = new GroupPrincipalBackend(
+ $c->getServer()->getGroupManager()
+ );
+ return new BirthdayService(
+ $c->query('CalDavBackend'),
+ $c->query('CardDavBackend'),
+ $g
+ );
+ });
+ }
+
+ /**
+ * @param IManager $contactsManager
+ * @param string $userID
+ */
+ public function setupContactsProvider(IManager $contactsManager, $userID) {
+ /** @var ContactsManager $cm */
+ $cm = $this->getContainer()->query('ContactsManager');
+ $cm->setupContactsProvider($contactsManager, $userID);
+ }
+
+ public function registerHooks() {
+ /** @var HookManager $hm */
+ $hm = $this->getContainer()->query('HookManager');
+ $hm->setup();
+
+ $listener = function($event) {
+ if ($event instanceof GenericEvent) {
+ /** @var BirthdayService $b */
+ $b = $this->getContainer()->query('BirthdayService');
+ $b->onCardChanged(
+ $event->getArgument('addressBookId'),
+ $event->getArgument('cardUri'),
+ $event->getArgument('cardData')
+ );
+ }
+ };
+
+ $dispatcher = $this->getContainer()->getServer()->getEventDispatcher();
+ $dispatcher->addListener('\OCA\DAV\CardDAV\CardDavBackend::createCard', $listener);
+ $dispatcher->addListener('\OCA\DAV\CardDAV\CardDavBackend::updateCard', $listener);
+ $dispatcher->addListener('\OCA\DAV\CardDAV\CardDavBackend::deleteCard', function($event) {
+ if ($event instanceof GenericEvent) {
+ /** @var BirthdayService $b */
+ $b = $this->getContainer()->query('BirthdayService');
+ $b->onCardDeleted(
+ $event->getArgument('addressBookId'),
+ $event->getArgument('cardUri')
+ );
+ }
+ });
+ }
+
+ public function getSyncService() {
+ return $this->getContainer()->query('SyncService');
+ }
+
+ public function generateBirthdays() {
+ try {
+ /** @var BirthdayService $migration */
+ $migration = $this->getContainer()->query('BirthdayService');
+ $userManager = $this->getContainer()->getServer()->getUserManager();
+
+ $userManager->callForAllUsers(function($user) use($migration) {
+ /** @var IUser $user */
+ $migration->syncUser($user->getUID());
+ });
+ } catch (\Exception $ex) {
+ $this->getContainer()->getServer()->getLogger()->logException($ex);
+ }
+ }
+}
diff --git a/apps/dav/lib/caldav/birthdayservice.php b/apps/dav/lib/CalDAV/BirthdayService.php
index b74116f4083..b74116f4083 100644
--- a/apps/dav/lib/caldav/birthdayservice.php
+++ b/apps/dav/lib/CalDAV/BirthdayService.php
diff --git a/apps/dav/lib/caldav/caldavbackend.php b/apps/dav/lib/CalDAV/CalDavBackend.php
index f0f236de3ff..f0f236de3ff 100644
--- a/apps/dav/lib/caldav/caldavbackend.php
+++ b/apps/dav/lib/CalDAV/CalDavBackend.php
diff --git a/apps/dav/lib/caldav/calendar.php b/apps/dav/lib/CalDAV/Calendar.php
index f3637692e43..f3637692e43 100644
--- a/apps/dav/lib/caldav/calendar.php
+++ b/apps/dav/lib/CalDAV/Calendar.php
diff --git a/apps/dav/lib/caldav/calendarhome.php b/apps/dav/lib/CalDAV/CalendarHome.php
index a4c485a8983..a4c485a8983 100644
--- a/apps/dav/lib/caldav/calendarhome.php
+++ b/apps/dav/lib/CalDAV/CalendarHome.php
diff --git a/apps/dav/lib/caldav/calendarroot.php b/apps/dav/lib/CalDAV/CalendarRoot.php
index d302da3d861..d302da3d861 100644
--- a/apps/dav/lib/caldav/calendarroot.php
+++ b/apps/dav/lib/CalDAV/CalendarRoot.php
diff --git a/apps/dav/lib/caldav/schedule/imipplugin.php b/apps/dav/lib/CalDAV/Schedule/IMipPlugin.php
index d9f2ec674f0..d9f2ec674f0 100644
--- a/apps/dav/lib/caldav/schedule/imipplugin.php
+++ b/apps/dav/lib/CalDAV/Schedule/IMipPlugin.php
diff --git a/apps/dav/lib/carddav/addressbook.php b/apps/dav/lib/CardDAV/AddressBook.php
index 8b1b600ec3d..8b1b600ec3d 100644
--- a/apps/dav/lib/carddav/addressbook.php
+++ b/apps/dav/lib/CardDAV/AddressBook.php
diff --git a/apps/dav/lib/carddav/addressbookimpl.php b/apps/dav/lib/CardDAV/AddressBookImpl.php
index 8b29d6d5c0c..8b29d6d5c0c 100644
--- a/apps/dav/lib/carddav/addressbookimpl.php
+++ b/apps/dav/lib/CardDAV/AddressBookImpl.php
diff --git a/apps/dav/lib/carddav/addressbookroot.php b/apps/dav/lib/CardDAV/AddressBookRoot.php
index 99c36c2e767..99c36c2e767 100644
--- a/apps/dav/lib/carddav/addressbookroot.php
+++ b/apps/dav/lib/CardDAV/AddressBookRoot.php
diff --git a/apps/dav/lib/carddav/carddavbackend.php b/apps/dav/lib/CardDAV/CardDavBackend.php
index 28d5ed1ae99..28d5ed1ae99 100644
--- a/apps/dav/lib/carddav/carddavbackend.php
+++ b/apps/dav/lib/CardDAV/CardDavBackend.php
diff --git a/apps/dav/lib/carddav/contactsmanager.php b/apps/dav/lib/CardDAV/ContactsManager.php
index 7900c6ccae0..7900c6ccae0 100644
--- a/apps/dav/lib/carddav/contactsmanager.php
+++ b/apps/dav/lib/CardDAV/ContactsManager.php
diff --git a/apps/dav/lib/carddav/converter.php b/apps/dav/lib/CardDAV/Converter.php
index c8d9b94c267..c8d9b94c267 100644
--- a/apps/dav/lib/carddav/converter.php
+++ b/apps/dav/lib/CardDAV/Converter.php
diff --git a/apps/dav/lib/carddav/plugin.php b/apps/dav/lib/CardDAV/Plugin.php
index e02cc5686b8..e02cc5686b8 100644
--- a/apps/dav/lib/carddav/plugin.php
+++ b/apps/dav/lib/CardDAV/Plugin.php
diff --git a/apps/dav/lib/carddav/syncjob.php b/apps/dav/lib/CardDAV/SyncJob.php
index 0554af6fbf1..b6748c05f5c 100644
--- a/apps/dav/lib/carddav/syncjob.php
+++ b/apps/dav/lib/CardDAV/SyncJob.php
@@ -22,7 +22,7 @@
namespace OCA\DAV\CardDAV;
use OC\BackgroundJob\TimedJob;
-use OCA\Dav\AppInfo\Application;
+use OCA\DAV\AppInfo\Application;
class SyncJob extends TimedJob {
diff --git a/apps/dav/lib/carddav/syncservice.php b/apps/dav/lib/CardDAV/SyncService.php
index c4741a01772..c4741a01772 100644
--- a/apps/dav/lib/carddav/syncservice.php
+++ b/apps/dav/lib/CardDAV/SyncService.php
diff --git a/apps/dav/lib/carddav/useraddressbooks.php b/apps/dav/lib/CardDAV/UserAddressBooks.php
index 734e3829e69..734e3829e69 100644
--- a/apps/dav/lib/carddav/useraddressbooks.php
+++ b/apps/dav/lib/CardDAV/UserAddressBooks.php
diff --git a/apps/dav/lib/carddav/xml/groups.php b/apps/dav/lib/CardDAV/Xml/Groups.php
index b39615db033..b39615db033 100644
--- a/apps/dav/lib/carddav/xml/groups.php
+++ b/apps/dav/lib/CardDAV/Xml/Groups.php
diff --git a/apps/dav/lib/Command/CreateAddressBook.php b/apps/dav/lib/Command/CreateAddressBook.php
new file mode 100644
index 00000000000..48302a2b439
--- /dev/null
+++ b/apps/dav/lib/Command/CreateAddressBook.php
@@ -0,0 +1,77 @@
+<?php
+/**
+ * @author Björn Schießle <schiessle@owncloud.com>
+ * @author Thomas Müller <thomas.mueller@tmit.eu>
+ *
+ * @copyright Copyright (c) 2016, ownCloud, Inc.
+ * @license AGPL-3.0
+ *
+ * This code is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU Affero General Public License, version 3,
+ * as published by the Free Software Foundation.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Affero General Public License for more details.
+ *
+ * You should have received a copy of the GNU Affero General Public License, version 3,
+ * along with this program. If not, see <http://www.gnu.org/licenses/>
+ *
+ */
+namespace OCA\DAV\Command;
+
+use OCA\DAV\CardDAV\CardDavBackend;
+use OCA\DAV\Connector\Sabre\Principal;
+use OCP\IConfig;
+use OCP\IDBConnection;
+use OCP\IGroupManager;
+use OCP\ILogger;
+use OCP\IUserManager;
+use Symfony\Component\Console\Command\Command;
+use Symfony\Component\Console\Input\InputArgument;
+use Symfony\Component\Console\Input\InputInterface;
+use Symfony\Component\Console\Output\OutputInterface;
+
+class CreateAddressBook extends Command {
+
+ /** @var IUserManager */
+ private $userManager;
+
+ /** @var CardDavBackend */
+ private $cardDavBackend;
+
+ /**
+ * @param IUserManager $userManager
+ * @param CardDavBackend $cardDavBackend
+ */
+ function __construct(IUserManager $userManager,
+ CardDavBackend $cardDavBackend
+ ) {
+ parent::__construct();
+ $this->userManager = $userManager;
+ $this->cardDavBackend = $cardDavBackend;
+ }
+
+ protected function configure() {
+ $this
+ ->setName('dav:create-addressbook')
+ ->setDescription('Create a dav addressbook')
+ ->addArgument('user',
+ InputArgument::REQUIRED,
+ 'User for whom the addressbook will be created')
+ ->addArgument('name',
+ InputArgument::REQUIRED,
+ 'Name of the addressbook');
+ }
+
+ protected function execute(InputInterface $input, OutputInterface $output) {
+ $user = $input->getArgument('user');
+ if (!$this->userManager->userExists($user)) {
+ throw new \InvalidArgumentException("User <$user> in unknown.");
+ }
+
+ $name = $input->getArgument('name');
+ $this->cardDavBackend->createAddressBook("principals/users/$user", $name, []);
+ }
+}
diff --git a/apps/dav/lib/Command/CreateCalendar.php b/apps/dav/lib/Command/CreateCalendar.php
new file mode 100644
index 00000000000..d7f82dd0e52
--- /dev/null
+++ b/apps/dav/lib/Command/CreateCalendar.php
@@ -0,0 +1,81 @@
+<?php
+/**
+ * @author Thomas Müller <thomas.mueller@tmit.eu>
+ *
+ * @copyright Copyright (c) 2016, ownCloud, Inc.
+ * @license AGPL-3.0
+ *
+ * This code is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU Affero General Public License, version 3,
+ * as published by the Free Software Foundation.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Affero General Public License for more details.
+ *
+ * You should have received a copy of the GNU Affero General Public License, version 3,
+ * along with this program. If not, see <http://www.gnu.org/licenses/>
+ *
+ */
+namespace OCA\DAV\Command;
+
+use OCA\DAV\CalDAV\CalDavBackend;
+use OCA\DAV\Connector\Sabre\Principal;
+use OCP\IDBConnection;
+use OCP\IGroupManager;
+use OCP\IUserManager;
+use Symfony\Component\Console\Command\Command;
+use Symfony\Component\Console\Input\InputArgument;
+use Symfony\Component\Console\Input\InputInterface;
+use Symfony\Component\Console\Output\OutputInterface;
+
+class CreateCalendar extends Command {
+
+ /** @var IUserManager */
+ protected $userManager;
+
+ /** @var IGroupManager $groupManager */
+ private $groupManager;
+
+ /** @var \OCP\IDBConnection */
+ protected $dbConnection;
+
+ /**
+ * @param IUserManager $userManager
+ * @param IDBConnection $dbConnection
+ */
+ function __construct(IUserManager $userManager, IGroupManager $groupManager, IDBConnection $dbConnection) {
+ parent::__construct();
+ $this->userManager = $userManager;
+ $this->groupManager = $groupManager;
+ $this->dbConnection = $dbConnection;
+ }
+
+ protected function configure() {
+ $this
+ ->setName('dav:create-calendar')
+ ->setDescription('Create a dav calendar')
+ ->addArgument('user',
+ InputArgument::REQUIRED,
+ 'User for whom the calendar will be created')
+ ->addArgument('name',
+ InputArgument::REQUIRED,
+ 'Name of the calendar');
+ }
+
+ protected function execute(InputInterface $input, OutputInterface $output) {
+ $user = $input->getArgument('user');
+ if (!$this->userManager->userExists($user)) {
+ throw new \InvalidArgumentException("User <$user> in unknown.");
+ }
+ $principalBackend = new Principal(
+ $this->userManager,
+ $this->groupManager
+ );
+
+ $name = $input->getArgument('name');
+ $caldav = new CalDavBackend($this->dbConnection, $principalBackend);
+ $caldav->createCalendar("principals/users/$user", $name, []);
+ }
+}
diff --git a/apps/dav/lib/Command/SyncBirthdayCalendar.php b/apps/dav/lib/Command/SyncBirthdayCalendar.php
new file mode 100644
index 00000000000..90a73a3eeb3
--- /dev/null
+++ b/apps/dav/lib/Command/SyncBirthdayCalendar.php
@@ -0,0 +1,85 @@
+<?php
+/**
+ * @author Thomas Müller <thomas.mueller@tmit.eu>
+ *
+ * @copyright Copyright (c) 2016, ownCloud, Inc.
+ * @license AGPL-3.0
+ *
+ * This code is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU Affero General Public License, version 3,
+ * as published by the Free Software Foundation.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Affero General Public License for more details.
+ *
+ * You should have received a copy of the GNU Affero General Public License, version 3,
+ * along with this program. If not, see <http://www.gnu.org/licenses/>
+ *
+ */
+namespace OCA\DAV\Command;
+
+use OCA\DAV\CalDAV\BirthdayService;
+use OCP\IUser;
+use OCP\IUserManager;
+use Symfony\Component\Console\Command\Command;
+use Symfony\Component\Console\Helper\ProgressBar;
+use Symfony\Component\Console\Input\InputArgument;
+use Symfony\Component\Console\Input\InputInterface;
+use Symfony\Component\Console\Output\OutputInterface;
+
+class SyncBirthdayCalendar extends Command {
+
+ /** @var BirthdayService */
+ private $birthdayService;
+
+ /** @var IUserManager */
+ private $userManager;
+
+ /**
+ * @param IUserManager $userManager
+ * @param BirthdayService $birthdayService
+ */
+ function __construct(IUserManager $userManager, BirthdayService $birthdayService) {
+ parent::__construct();
+ $this->birthdayService = $birthdayService;
+ $this->userManager = $userManager;
+ }
+
+ protected function configure() {
+ $this
+ ->setName('dav:sync-birthday-calendar')
+ ->setDescription('Synchronizes the birthday calendar')
+ ->addArgument('user',
+ InputArgument::OPTIONAL,
+ 'User for whom the birthday calendar will be synchronized');
+ }
+
+ /**
+ * @param InputInterface $input
+ * @param OutputInterface $output
+ */
+ protected function execute(InputInterface $input, OutputInterface $output) {
+ $user = $input->getArgument('user');
+ if (!is_null($user)) {
+ if (!$this->userManager->userExists($user)) {
+ throw new \InvalidArgumentException("User <$user> in unknown.");
+ }
+ $output->writeln("Start birthday calendar sync for $user");
+ $this->birthdayService->syncUser($user);
+ return;
+ }
+ $output->writeln("Start birthday calendar sync for all users ...");
+ $p = new ProgressBar($output);
+ $p->start();
+ $this->userManager->callForAllUsers(function($user) use ($p) {
+ $p->advance();
+ /** @var IUser $user */
+ $this->birthdayService->syncUser($user->getUID());
+ });
+
+ $p->finish();
+ $output->writeln('');
+ }
+}
diff --git a/apps/dav/lib/Command/SyncSystemAddressBook.php b/apps/dav/lib/Command/SyncSystemAddressBook.php
new file mode 100644
index 00000000000..b62a42d7b90
--- /dev/null
+++ b/apps/dav/lib/Command/SyncSystemAddressBook.php
@@ -0,0 +1,65 @@
+<?php
+/**
+ * @author Thomas Müller <thomas.mueller@tmit.eu>
+ *
+ * @copyright Copyright (c) 2016, ownCloud, Inc.
+ * @license AGPL-3.0
+ *
+ * This code is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU Affero General Public License, version 3,
+ * as published by the Free Software Foundation.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Affero General Public License for more details.
+ *
+ * You should have received a copy of the GNU Affero General Public License, version 3,
+ * along with this program. If not, see <http://www.gnu.org/licenses/>
+ *
+ */
+namespace OCA\DAV\Command;
+
+use OCA\DAV\CardDAV\SyncService;
+use OCP\IUserManager;
+use Symfony\Component\Console\Command\Command;
+use Symfony\Component\Console\Helper\ProgressBar;
+use Symfony\Component\Console\Input\InputArgument;
+use Symfony\Component\Console\Input\InputInterface;
+use Symfony\Component\Console\Output\OutputInterface;
+
+class SyncSystemAddressBook extends Command {
+
+ /** @var SyncService */
+ private $syncService;
+
+ /**
+ * @param SyncService $syncService
+ */
+ function __construct(SyncService $syncService) {
+ parent::__construct();
+ $this->syncService = $syncService;
+ }
+
+ protected function configure() {
+ $this
+ ->setName('dav:sync-system-addressbook')
+ ->setDescription('Synchronizes users to the system addressbook');
+ }
+
+ /**
+ * @param InputInterface $input
+ * @param OutputInterface $output
+ */
+ protected function execute(InputInterface $input, OutputInterface $output) {
+ $output->writeln('Syncing users ...');
+ $progress = new ProgressBar($output);
+ $progress->start();
+ $this->syncService->syncInstance(function() use ($progress) {
+ $progress->advance();
+ });
+
+ $progress->finish();
+ $output->writeln('');
+ }
+}
diff --git a/apps/dav/lib/comments/commentnode.php b/apps/dav/lib/Comments/CommentNode.php
index 339abc6382d..339abc6382d 100644
--- a/apps/dav/lib/comments/commentnode.php
+++ b/apps/dav/lib/Comments/CommentNode.php
diff --git a/apps/dav/lib/comments/commentsplugin.php b/apps/dav/lib/Comments/CommentsPlugin.php
index d4a065649ef..d4a065649ef 100644
--- a/apps/dav/lib/comments/commentsplugin.php
+++ b/apps/dav/lib/Comments/CommentsPlugin.php
diff --git a/apps/dav/lib/comments/entitycollection.php b/apps/dav/lib/Comments/EntityCollection.php
index a55a18c00c0..a55a18c00c0 100644
--- a/apps/dav/lib/comments/entitycollection.php
+++ b/apps/dav/lib/Comments/EntityCollection.php
diff --git a/apps/dav/lib/comments/entitytypecollection.php b/apps/dav/lib/Comments/EntityTypeCollection.php
index 6bc42484207..6bc42484207 100644
--- a/apps/dav/lib/comments/entitytypecollection.php
+++ b/apps/dav/lib/Comments/EntityTypeCollection.php
diff --git a/apps/dav/lib/comments/rootcollection.php b/apps/dav/lib/Comments/RootCollection.php
index cda666f7162..cda666f7162 100644
--- a/apps/dav/lib/comments/rootcollection.php
+++ b/apps/dav/lib/Comments/RootCollection.php
diff --git a/apps/dav/lib/connector/legacydavacl.php b/apps/dav/lib/Connector/LegacyDAVACL.php
index eb6ca1fd7d5..eb6ca1fd7d5 100644
--- a/apps/dav/lib/connector/legacydavacl.php
+++ b/apps/dav/lib/Connector/LegacyDAVACL.php
diff --git a/apps/dav/lib/connector/publicauth.php b/apps/dav/lib/Connector/PublicAuth.php
index 3aa58cda244..3aa58cda244 100644
--- a/apps/dav/lib/connector/publicauth.php
+++ b/apps/dav/lib/Connector/PublicAuth.php
diff --git a/apps/dav/lib/connector/sabre/appenabledplugin.php b/apps/dav/lib/Connector/Sabre/AppEnabledPlugin.php
index cb061d6a309..cb061d6a309 100644
--- a/apps/dav/lib/connector/sabre/appenabledplugin.php
+++ b/apps/dav/lib/Connector/Sabre/AppEnabledPlugin.php
diff --git a/apps/dav/lib/connector/sabre/auth.php b/apps/dav/lib/Connector/Sabre/Auth.php
index b8047e779f5..b8047e779f5 100644
--- a/apps/dav/lib/connector/sabre/auth.php
+++ b/apps/dav/lib/Connector/Sabre/Auth.php
diff --git a/apps/dav/lib/connector/sabre/blocklegacyclientplugin.php b/apps/dav/lib/Connector/Sabre/BlockLegacyClientPlugin.php
index 70d19cb7f2a..70d19cb7f2a 100644
--- a/apps/dav/lib/connector/sabre/blocklegacyclientplugin.php
+++ b/apps/dav/lib/Connector/Sabre/BlockLegacyClientPlugin.php
diff --git a/apps/dav/lib/connector/sabre/checksumlist.php b/apps/dav/lib/Connector/Sabre/ChecksumList.php
index f137222acca..f137222acca 100644
--- a/apps/dav/lib/connector/sabre/checksumlist.php
+++ b/apps/dav/lib/Connector/Sabre/ChecksumList.php
diff --git a/apps/dav/lib/connector/sabre/commentpropertiesplugin.php b/apps/dav/lib/Connector/Sabre/CommentPropertiesPlugin.php
index a8d5f771122..a8d5f771122 100644
--- a/apps/dav/lib/connector/sabre/commentpropertiesplugin.php
+++ b/apps/dav/lib/Connector/Sabre/CommentPropertiesPlugin.php
diff --git a/apps/dav/lib/connector/sabre/copyetagheaderplugin.php b/apps/dav/lib/Connector/Sabre/CopyEtagHeaderPlugin.php
index 49b6a7b2de7..49b6a7b2de7 100644
--- a/apps/dav/lib/connector/sabre/copyetagheaderplugin.php
+++ b/apps/dav/lib/Connector/Sabre/CopyEtagHeaderPlugin.php
diff --git a/apps/dav/lib/connector/sabre/custompropertiesbackend.php b/apps/dav/lib/Connector/Sabre/CustomPropertiesBackend.php
index 5946c9910d4..5946c9910d4 100644
--- a/apps/dav/lib/connector/sabre/custompropertiesbackend.php
+++ b/apps/dav/lib/Connector/Sabre/CustomPropertiesBackend.php
diff --git a/apps/dav/lib/connector/sabre/davaclplugin.php b/apps/dav/lib/Connector/Sabre/DavAclPlugin.php
index f5699b469c3..f5699b469c3 100644
--- a/apps/dav/lib/connector/sabre/davaclplugin.php
+++ b/apps/dav/lib/Connector/Sabre/DavAclPlugin.php
diff --git a/apps/dav/lib/connector/sabre/directory.php b/apps/dav/lib/Connector/Sabre/Directory.php
index daa5f29ce79..daa5f29ce79 100644
--- a/apps/dav/lib/connector/sabre/directory.php
+++ b/apps/dav/lib/Connector/Sabre/Directory.php
diff --git a/apps/dav/lib/connector/sabre/dummygetresponseplugin.php b/apps/dav/lib/Connector/Sabre/DummyGetResponsePlugin.php
index b10d5aaab36..b10d5aaab36 100644
--- a/apps/dav/lib/connector/sabre/dummygetresponseplugin.php
+++ b/apps/dav/lib/Connector/Sabre/DummyGetResponsePlugin.php
diff --git a/apps/dav/lib/connector/sabre/exception/entitytoolarge.php b/apps/dav/lib/Connector/Sabre/Exception/EntityTooLarge.php
index d16e93bb637..d16e93bb637 100644
--- a/apps/dav/lib/connector/sabre/exception/entitytoolarge.php
+++ b/apps/dav/lib/Connector/Sabre/Exception/EntityTooLarge.php
diff --git a/apps/dav/lib/connector/sabre/exception/filelocked.php b/apps/dav/lib/Connector/Sabre/Exception/FileLocked.php
index 03ced0e81e2..03ced0e81e2 100644
--- a/apps/dav/lib/connector/sabre/exception/filelocked.php
+++ b/apps/dav/lib/Connector/Sabre/Exception/FileLocked.php
diff --git a/apps/dav/lib/connector/sabre/exception/forbidden.php b/apps/dav/lib/Connector/Sabre/Exception/Forbidden.php
index f2467e6b298..f2467e6b298 100644
--- a/apps/dav/lib/connector/sabre/exception/forbidden.php
+++ b/apps/dav/lib/Connector/Sabre/Exception/Forbidden.php
diff --git a/apps/dav/lib/connector/sabre/exception/invalidpath.php b/apps/dav/lib/Connector/Sabre/Exception/InvalidPath.php
index 7951a0a89b7..7951a0a89b7 100644
--- a/apps/dav/lib/connector/sabre/exception/invalidpath.php
+++ b/apps/dav/lib/Connector/Sabre/Exception/InvalidPath.php
diff --git a/apps/dav/lib/connector/sabre/exception/unsupportedmediatype.php b/apps/dav/lib/Connector/Sabre/Exception/UnsupportedMediaType.php
index 99e3c222c75..99e3c222c75 100644
--- a/apps/dav/lib/connector/sabre/exception/unsupportedmediatype.php
+++ b/apps/dav/lib/Connector/Sabre/Exception/UnsupportedMediaType.php
diff --git a/apps/dav/lib/connector/sabre/exceptionloggerplugin.php b/apps/dav/lib/Connector/Sabre/ExceptionLoggerPlugin.php
index 38bddef8769..38bddef8769 100644
--- a/apps/dav/lib/connector/sabre/exceptionloggerplugin.php
+++ b/apps/dav/lib/Connector/Sabre/ExceptionLoggerPlugin.php
diff --git a/apps/dav/lib/connector/sabre/fakelockerplugin.php b/apps/dav/lib/Connector/Sabre/FakeLockerPlugin.php
index 6db8740bc13..6db8740bc13 100644
--- a/apps/dav/lib/connector/sabre/fakelockerplugin.php
+++ b/apps/dav/lib/Connector/Sabre/FakeLockerPlugin.php
diff --git a/apps/dav/lib/connector/sabre/file.php b/apps/dav/lib/Connector/Sabre/File.php
index 943e9150e74..943e9150e74 100644
--- a/apps/dav/lib/connector/sabre/file.php
+++ b/apps/dav/lib/Connector/Sabre/File.php
diff --git a/apps/dav/lib/connector/sabre/filesplugin.php b/apps/dav/lib/Connector/Sabre/FilesPlugin.php
index 8822deb1661..8822deb1661 100644
--- a/apps/dav/lib/connector/sabre/filesplugin.php
+++ b/apps/dav/lib/Connector/Sabre/FilesPlugin.php
diff --git a/apps/dav/lib/connector/sabre/filesreportplugin.php b/apps/dav/lib/Connector/Sabre/FilesReportPlugin.php
index d4e1cbe3b20..d4e1cbe3b20 100644
--- a/apps/dav/lib/connector/sabre/filesreportplugin.php
+++ b/apps/dav/lib/Connector/Sabre/FilesReportPlugin.php
diff --git a/apps/dav/lib/connector/sabre/lockplugin.php b/apps/dav/lib/Connector/Sabre/LockPlugin.php
index 66da39a57c8..66da39a57c8 100644
--- a/apps/dav/lib/connector/sabre/lockplugin.php
+++ b/apps/dav/lib/Connector/Sabre/LockPlugin.php
diff --git a/apps/dav/lib/connector/sabre/maintenanceplugin.php b/apps/dav/lib/Connector/Sabre/MaintenancePlugin.php
index 6e9a5930b78..6e9a5930b78 100644
--- a/apps/dav/lib/connector/sabre/maintenanceplugin.php
+++ b/apps/dav/lib/Connector/Sabre/MaintenancePlugin.php
diff --git a/apps/dav/lib/connector/sabre/node.php b/apps/dav/lib/Connector/Sabre/Node.php
index ccc035063cd..ccc035063cd 100644
--- a/apps/dav/lib/connector/sabre/node.php
+++ b/apps/dav/lib/Connector/Sabre/Node.php
diff --git a/apps/dav/lib/connector/sabre/objecttree.php b/apps/dav/lib/Connector/Sabre/ObjectTree.php
index f38dfe679c7..f38dfe679c7 100644
--- a/apps/dav/lib/connector/sabre/objecttree.php
+++ b/apps/dav/lib/Connector/Sabre/ObjectTree.php
diff --git a/apps/dav/lib/connector/sabre/principal.php b/apps/dav/lib/Connector/Sabre/Principal.php
index 787bcdf469b..787bcdf469b 100644
--- a/apps/dav/lib/connector/sabre/principal.php
+++ b/apps/dav/lib/Connector/Sabre/Principal.php
diff --git a/apps/dav/lib/connector/sabre/quotaplugin.php b/apps/dav/lib/Connector/Sabre/QuotaPlugin.php
index a093c52851c..a093c52851c 100644
--- a/apps/dav/lib/connector/sabre/quotaplugin.php
+++ b/apps/dav/lib/Connector/Sabre/QuotaPlugin.php
diff --git a/apps/dav/lib/connector/sabre/server.php b/apps/dav/lib/Connector/Sabre/Server.php
index 421fc64422d..421fc64422d 100644
--- a/apps/dav/lib/connector/sabre/server.php
+++ b/apps/dav/lib/Connector/Sabre/Server.php
diff --git a/apps/dav/lib/connector/sabre/serverfactory.php b/apps/dav/lib/Connector/Sabre/ServerFactory.php
index 5853370778d..5853370778d 100644
--- a/apps/dav/lib/connector/sabre/serverfactory.php
+++ b/apps/dav/lib/Connector/Sabre/ServerFactory.php
diff --git a/apps/dav/lib/connector/sabre/sharetypelist.php b/apps/dav/lib/Connector/Sabre/ShareTypeList.php
index 763586412ad..763586412ad 100644
--- a/apps/dav/lib/connector/sabre/sharetypelist.php
+++ b/apps/dav/lib/Connector/Sabre/ShareTypeList.php
diff --git a/apps/dav/lib/connector/sabre/sharesplugin.php b/apps/dav/lib/Connector/Sabre/SharesPlugin.php
index c76068969e9..c76068969e9 100644
--- a/apps/dav/lib/connector/sabre/sharesplugin.php
+++ b/apps/dav/lib/Connector/Sabre/SharesPlugin.php
diff --git a/apps/dav/lib/connector/sabre/taglist.php b/apps/dav/lib/Connector/Sabre/TagList.php
index 5c1cd8b4f1d..5c1cd8b4f1d 100644
--- a/apps/dav/lib/connector/sabre/taglist.php
+++ b/apps/dav/lib/Connector/Sabre/TagList.php
diff --git a/apps/dav/lib/connector/sabre/tagsplugin.php b/apps/dav/lib/Connector/Sabre/TagsPlugin.php
index dfc1a2dd95d..dfc1a2dd95d 100644
--- a/apps/dav/lib/connector/sabre/tagsplugin.php
+++ b/apps/dav/lib/Connector/Sabre/TagsPlugin.php
diff --git a/apps/dav/lib/dav/groupprincipalbackend.php b/apps/dav/lib/DAV/GroupPrincipalBackend.php
index e0568639784..e0568639784 100644
--- a/apps/dav/lib/dav/groupprincipalbackend.php
+++ b/apps/dav/lib/DAV/GroupPrincipalBackend.php
diff --git a/apps/dav/lib/dav/sharing/backend.php b/apps/dav/lib/DAV/Sharing/Backend.php
index 225b773713d..225b773713d 100644
--- a/apps/dav/lib/dav/sharing/backend.php
+++ b/apps/dav/lib/DAV/Sharing/Backend.php
diff --git a/apps/dav/lib/dav/sharing/ishareable.php b/apps/dav/lib/DAV/Sharing/IShareable.php
index f6b6bfa8862..f6b6bfa8862 100644
--- a/apps/dav/lib/dav/sharing/ishareable.php
+++ b/apps/dav/lib/DAV/Sharing/IShareable.php
diff --git a/apps/dav/lib/dav/sharing/plugin.php b/apps/dav/lib/DAV/Sharing/Plugin.php
index 3173d1397ba..3173d1397ba 100644
--- a/apps/dav/lib/dav/sharing/plugin.php
+++ b/apps/dav/lib/DAV/Sharing/Plugin.php
diff --git a/apps/dav/lib/dav/sharing/xml/invite.php b/apps/dav/lib/DAV/Sharing/Xml/Invite.php
index ae40ff06701..ae40ff06701 100644
--- a/apps/dav/lib/dav/sharing/xml/invite.php
+++ b/apps/dav/lib/DAV/Sharing/Xml/Invite.php
diff --git a/apps/dav/lib/dav/sharing/xml/sharerequest.php b/apps/dav/lib/DAV/Sharing/Xml/ShareRequest.php
index 776fb446b6c..776fb446b6c 100644
--- a/apps/dav/lib/dav/sharing/xml/sharerequest.php
+++ b/apps/dav/lib/DAV/Sharing/Xml/ShareRequest.php
diff --git a/apps/dav/lib/dav/systemprincipalbackend.php b/apps/dav/lib/DAV/SystemPrincipalBackend.php
index 8001ec4e6c6..8001ec4e6c6 100644
--- a/apps/dav/lib/dav/systemprincipalbackend.php
+++ b/apps/dav/lib/DAV/SystemPrincipalBackend.php
diff --git a/apps/dav/lib/files/browsererrorpageplugin.php b/apps/dav/lib/Files/BrowserErrorPagePlugin.php
index 37a4166efef..37a4166efef 100644
--- a/apps/dav/lib/files/browsererrorpageplugin.php
+++ b/apps/dav/lib/Files/BrowserErrorPagePlugin.php
diff --git a/apps/dav/lib/files/custompropertiesbackend.php b/apps/dav/lib/Files/CustomPropertiesBackend.php
index aa541f88dad..aa541f88dad 100644
--- a/apps/dav/lib/files/custompropertiesbackend.php
+++ b/apps/dav/lib/Files/CustomPropertiesBackend.php
diff --git a/apps/dav/lib/files/fileshome.php b/apps/dav/lib/Files/FilesHome.php
index ef572d6618b..ef572d6618b 100644
--- a/apps/dav/lib/files/fileshome.php
+++ b/apps/dav/lib/Files/FilesHome.php
diff --git a/apps/dav/lib/files/rootcollection.php b/apps/dav/lib/Files/RootCollection.php
index 63328aac8e3..63328aac8e3 100644
--- a/apps/dav/lib/files/rootcollection.php
+++ b/apps/dav/lib/Files/RootCollection.php
diff --git a/apps/dav/lib/files/sharing/publiclinkcheckplugin.php b/apps/dav/lib/Files/Sharing/PublicLinkCheckPlugin.php
index 751f63d394e..751f63d394e 100644
--- a/apps/dav/lib/files/sharing/publiclinkcheckplugin.php
+++ b/apps/dav/lib/Files/Sharing/PublicLinkCheckPlugin.php
diff --git a/apps/dav/lib/hookmanager.php b/apps/dav/lib/HookManager.php
index aa3777088f8..aa3777088f8 100644
--- a/apps/dav/lib/hookmanager.php
+++ b/apps/dav/lib/HookManager.php
diff --git a/apps/dav/lib/rootcollection.php b/apps/dav/lib/RootCollection.php
index b6e1747e990..b6e1747e990 100644
--- a/apps/dav/lib/rootcollection.php
+++ b/apps/dav/lib/RootCollection.php
diff --git a/apps/dav/lib/server.php b/apps/dav/lib/Server.php
index edaa7ac8552..edaa7ac8552 100644
--- a/apps/dav/lib/server.php
+++ b/apps/dav/lib/Server.php
diff --git a/apps/dav/lib/systemtag/systemtagmappingnode.php b/apps/dav/lib/SystemTag/SystemTagMappingNode.php
index bb2936c13dc..bb2936c13dc 100644
--- a/apps/dav/lib/systemtag/systemtagmappingnode.php
+++ b/apps/dav/lib/SystemTag/SystemTagMappingNode.php
diff --git a/apps/dav/lib/systemtag/systemtagnode.php b/apps/dav/lib/SystemTag/SystemTagNode.php
index 500e1a3adea..500e1a3adea 100644
--- a/apps/dav/lib/systemtag/systemtagnode.php
+++ b/apps/dav/lib/SystemTag/SystemTagNode.php
diff --git a/apps/dav/lib/systemtag/systemtagplugin.php b/apps/dav/lib/SystemTag/SystemTagPlugin.php
index a266b4a1214..a266b4a1214 100644
--- a/apps/dav/lib/systemtag/systemtagplugin.php
+++ b/apps/dav/lib/SystemTag/SystemTagPlugin.php
diff --git a/apps/dav/lib/systemtag/systemtagsbyidcollection.php b/apps/dav/lib/SystemTag/SystemTagsByIdCollection.php
index 298902501ab..298902501ab 100644
--- a/apps/dav/lib/systemtag/systemtagsbyidcollection.php
+++ b/apps/dav/lib/SystemTag/SystemTagsByIdCollection.php
diff --git a/apps/dav/lib/systemtag/systemtagsobjectmappingcollection.php b/apps/dav/lib/SystemTag/SystemTagsObjectMappingCollection.php
index eb75ed06393..eb75ed06393 100644
--- a/apps/dav/lib/systemtag/systemtagsobjectmappingcollection.php
+++ b/apps/dav/lib/SystemTag/SystemTagsObjectMappingCollection.php
diff --git a/apps/dav/lib/systemtag/systemtagsobjecttypecollection.php b/apps/dav/lib/SystemTag/SystemTagsObjectTypeCollection.php
index bdbc73c4e32..bdbc73c4e32 100644
--- a/apps/dav/lib/systemtag/systemtagsobjecttypecollection.php
+++ b/apps/dav/lib/SystemTag/SystemTagsObjectTypeCollection.php
diff --git a/apps/dav/lib/systemtag/systemtagsrelationscollection.php b/apps/dav/lib/SystemTag/SystemTagsRelationsCollection.php
index 19db39d3f3a..19db39d3f3a 100644
--- a/apps/dav/lib/systemtag/systemtagsrelationscollection.php
+++ b/apps/dav/lib/SystemTag/SystemTagsRelationsCollection.php
diff --git a/apps/dav/lib/upload/assemblystream.php b/apps/dav/lib/Upload/AssemblyStream.php
index 4b80a591ce4..4b80a591ce4 100644
--- a/apps/dav/lib/upload/assemblystream.php
+++ b/apps/dav/lib/Upload/AssemblyStream.php
diff --git a/apps/dav/lib/upload/futurefile.php b/apps/dav/lib/Upload/FutureFile.php
index aca81afc055..aca81afc055 100644
--- a/apps/dav/lib/upload/futurefile.php
+++ b/apps/dav/lib/Upload/FutureFile.php
diff --git a/apps/dav/lib/upload/rootcollection.php b/apps/dav/lib/Upload/RootCollection.php
index 673a3734318..673a3734318 100644
--- a/apps/dav/lib/upload/rootcollection.php
+++ b/apps/dav/lib/Upload/RootCollection.php
diff --git a/apps/dav/lib/upload/uploadfolder.php b/apps/dav/lib/Upload/UploadFolder.php
index 01fbf1f8dc9..01fbf1f8dc9 100644
--- a/apps/dav/lib/upload/uploadfolder.php
+++ b/apps/dav/lib/Upload/UploadFolder.php
diff --git a/apps/dav/lib/upload/uploadhome.php b/apps/dav/lib/Upload/UploadHome.php
index ae4dcfa4931..ae4dcfa4931 100644
--- a/apps/dav/lib/upload/uploadhome.php
+++ b/apps/dav/lib/Upload/UploadHome.php