]> git.mxchange.org Git - quix0rs-gnu-social.git/blob - _darcs/tentative_pristine
Laconica-specific extensions for Twitter API
[quix0rs-gnu-social.git] / _darcs / tentative_pristine
1 addfile ./actions/twitapilaconica.php
2 hunk ./actions/twitapilaconica.php 1
3 +<?php
4 +/**
5 + * Laconica, the distributed open-source microblogging tool
6 + *
7 + * Laconica-only extensions to the Twitter-like API
8 + *
9 + * PHP version 5
10 + *
11 + * LICENCE: This program is free software: you can redistribute it and/or modify
12 + * it under the terms of the GNU Affero General Public License as published by
13 + * the Free Software Foundation, either version 3 of the License, or
14 + * (at your option) any later version.
15 + *
16 + * This program is distributed in the hope that it will be useful,
17 + * but WITHOUT ANY WARRANTY; without even the implied warranty of
18 + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
19 + * GNU Affero General Public License for more details.
20 + *
21 + * You should have received a copy of the GNU Affero General Public License
22 + * along with this program.  If not, see <http://www.gnu.org/licenses/>.
23 + *
24 + * @category  Twitter
25 + * @package   Laconica
26 + * @author    Evan Prodromou <evan@controlyourself.ca>
27 + * @copyright 2008 Control Yourself, Inc.
28 + * @license   http://www.fsf.org/licensing/licenses/agpl-3.0.html GNU Affero General Public License version 3.0
29 + * @link      http://laconi.ca/
30 + */
31 +
32 +if (!defined('LACONICA')) {
33 +    exit(1);
34 +}
35 +
36 +require_once INSTALLDIR.'/lib/twitterapi.php';
37 +
38 +/**
39 + * Laconica-specific API methods
40 + *
41 + * This class handles all /laconica/ API methods.
42 + *
43 + * @category  Twitter
44 + * @package   Laconica
45 + * @author    Evan Prodromou <evan@controlyourself.ca>
46 + * @copyright 2008 Control Yourself, Inc.
47 + * @license   http://www.fsf.org/licensing/licenses/agpl-3.0.html GNU Affero General Public License version 3.0
48 + * @link      http://laconi.ca/
49 + */
50 +
51 +class TwitapilaconicaAction extends TwitterapiAction
52 +{
53 +    /**
54 +     * A version stamp for the API
55 +     *
56 +     * Returns a version number for this version of Laconica, which
57 +     * should make things a bit easier for upgrades.
58 +     *
59 +     * @param array $args    Web arguments
60 +     * @param array $apidata Twitter API data
61 +     *
62 +     * @return void
63 +     *
64 +     * @see ApiAction::process_command()
65 +     */
66 +
67 +    function version($args, $apidata)
68 +    {
69 +        parent::handle($args);
70 +        common_server_error(_('API method under construction.'), 501);
71 +    }
72 +
73 +    /**
74 +     * Dump of configuration variables
75 +     *
76 +     * Gives a full dump of configuration variables for this instance
77 +     * of Laconica, minus variables that may be security-sensitive (like
78 +     * passwords).
79 +     *
80 +     * @param array $args    Web arguments
81 +     * @param array $apidata Twitter API data
82 +     *
83 +     * @return void
84 +     *
85 +     * @see ApiAction::process_command()
86 +     */
87 +
88 +    function config($args, $apidata)
89 +    {
90 +        parent::handle($args);
91 +        common_server_error(_('API method under construction.'), 501);
92 +    }
93 +
94 +    /**
95 +     * WADL description of the API
96 +     *
97 +     * Gives a WADL description of the API provided by this version of the
98 +     * software.
99 +     *
100 +     * @param array $args    Web arguments
101 +     * @param array $apidata Twitter API data
102 +     *
103 +     * @return void
104 +     *
105 +     * @see ApiAction::process_command()
106 +     */
107 +
108 +    function wadl($args, $apidata)
109 +    {
110 +        parent::handle($args);
111 +        common_server_error(_('API method under construction.'), 501);
112 +    }
113 +}