2010-04-14 14:58:52 +00:00
|
|
|
<?php
|
|
|
|
/**
|
2016-07-21 15:07:57 +00:00
|
|
|
* @copyright Copyright (c) 2016, ownCloud, Inc.
|
|
|
|
*
|
2015-03-26 10:44:34 +00:00
|
|
|
* @author Bart Visscher <bartv@thisnet.nl>
|
2016-05-26 17:56:05 +00:00
|
|
|
* @author Frank Karlitschek <frank@karlitschek.de>
|
|
|
|
* @author Lukas Reschke <lukas@statuscode.ch>
|
2015-03-26 10:44:34 +00:00
|
|
|
* @author Morris Jobke <hey@morrisjobke.de>
|
|
|
|
* @author Robin Appelman <icewind@owncloud.com>
|
|
|
|
* @author Thomas Müller <thomas.mueller@tmit.eu>
|
|
|
|
*
|
|
|
|
* @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/>
|
|
|
|
*
|
|
|
|
*/
|
2015-08-03 16:06:07 +00:00
|
|
|
use OCP\API;
|
2015-02-26 10:37:37 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Class to handle open collaboration services API requests
|
2010-04-14 14:58:52 +00:00
|
|
|
*/
|
|
|
|
class OC_OCS {
|
2012-07-23 16:34:21 +00:00
|
|
|
/**
|
2015-02-17 22:25:31 +00:00
|
|
|
* Called when a not existing OCS endpoint has been called
|
|
|
|
*/
|
2012-07-30 19:03:41 +00:00
|
|
|
public static function notFound() {
|
2015-02-17 22:25:31 +00:00
|
|
|
$format = \OC::$server->getRequest()->getParam('format', 'xml');
|
2013-02-11 16:44:02 +00:00
|
|
|
$txt='Invalid query, please check the syntax. API specifications are here:'
|
2015-02-17 22:25:31 +00:00
|
|
|
.' http://www.freedesktop.org/wiki/Specifications/open-collaboration-services. DEBUG OUTPUT:'."\n";
|
2015-08-19 12:21:10 +00:00
|
|
|
OC_API::respond(new OC_OCS_Result(null, API::RESPOND_UNKNOWN_ERROR, $txt), $format);
|
|
|
|
}
|
2012-07-23 16:34:21 +00:00
|
|
|
|
2011-02-06 00:22:48 +00:00
|
|
|
}
|