summaryrefslogtreecommitdiff
path: root/extensions/OLPC_Buddy_Info.xml
blob: 339da95adaae1f0f6d25f99e73d53b36f1bb3348 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
<?xml version="1.0" ?>
<node name="/OLPC_Buddy_Info" xmlns:tp="http://telepathy.freedesktop.org/wiki/DbusSpec#extensions-v0">
  <tp:copyright> Copyright (C) 2007 Collabora Limited </tp:copyright>
  <tp:license xmlns="http://www.w3.org/1999/xhtml">
    <p>This library is free software; you can redistribute it and/or
modify it under the terms of the GNU Lesser General Public
License as published by the Free Software Foundation; either
version 2.1 of the License, or (at your option) any later version.</p>

<p>This library 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
Lesser General Public License for more details.</p>

<p>You should have received a copy of the GNU Lesser General Public
License along with this library; if not, write to the Free Software
Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA</p>
  </tp:license>
  <interface name="org.laptop.Telepathy.BuddyInfo">
    <tp:requires interface="org.freedesktop.Telepathy.Connection"/>

    <method name="SetProperties">
      <arg direction="in" name="properties" type="a{sv}">
        <tp:docstring>
          A dictionary mapping information names to the desired values.
          This replaces any existing buddy properties completely: any keys
          which were previously present, but are not present in this dictionary,
          are deleted.
        </tp:docstring>
      </arg>
      <tp:docstring xmlns="http://www.w3.org/1999/xhtml">
        <p>Set the information of the local user for this connection.</p>
        <p>This method may be called before Connect(), in which case the given
        properties will be advertised as soon as possible after connection
        (possibly immediately).</p>
      </tp:docstring>
      <tp:possible-errors>
        <tp:error name="org.freedesktop.Telepathy.Error.InvalidArgument"/>
      </tp:possible-errors>
    </method>

    <method name="GetProperties">
      <arg direction="in" name="contact" type="u">
        <tp:docstring>
          An integer handle for the contact to request his properties for
        </tp:docstring>
      </arg>
      <arg direction="out" name="properties" type="a{sv}">
        <tp:docstring>
          A dictionary mapping information names to their values
        </tp:docstring>
      </arg>
      <tp:docstring>
        Get the properties of a particular contact.
      </tp:docstring>
      <tp:possible-errors>
        <tp:error name="org.freedesktop.Telepathy.Error.Disconnected"/>
        <tp:error name="org.freedesktop.Telepathy.Error.InvalidArgument"/>
      </tp:possible-errors>
    </method>

    <signal name="PropertiesChanged">
      <arg name="contact" type="u">
        <tp:docstring>
          An integer handle representing the contact
        </tp:docstring>
      </arg>
      <arg name="properties" type="a{sv}">
        <tp:docstring>
          A dictionary mapping property names to their new values. All
          properties are included, not just those that have changed.
        </tp:docstring>
      </arg>
      <tp:docstring>
        Signal emitted when the properties of a contact from your 'subscribe'
        contact list are changed.
      </tp:docstring>
    </signal>


   <tp:struct name="Activity" array-name="Activity_List">
      <tp:docstring>A struct containing:
          <ul>
            <li>the identifier of the activity</li>
            <li>the room handle of the activity channel</li>
          </ul>
        </tp:docstring>
      <tp:member type="s" name="id"/>
      <tp:member type="u" tp:type="Room_Handle" name="room"/>
    </tp:struct>

    <method name="SetActivities">
      <arg direction="in" name="activities" type="a(su)" tp:type="Activity[]">
        <tp:docstring xmlns="http://www.w3.org/1999/xhtml">
          An array of structs containing:
          <ul>
            <li>the identifier of the activity</li>
            <li>the room handle of the activity channel</li>
          </ul>
        </tp:docstring>
      </arg>
      <tp:docstring>
        Set the activities of the local user for this connection.
      </tp:docstring>
      <tp:possible-errors>
        <tp:error name="org.freedesktop.Telepathy.Error.Disconnected"/>
        <tp:error name="org.freedesktop.Telepathy.Error.InvalidArgument"/>
      </tp:possible-errors>
    </method>

    <method name="GetActivities">
      <arg direction="in" name="contact" type="u">
        <tp:docstring>
          An integer handle for the contact whose activities are to be returned
        </tp:docstring>
      </arg>
      <arg direction="out" name="activities" type="a(su)" tp:type="Activity[]">
        <tp:docstring xmlns="http://www.w3.org/1999/xhtml">
          An array of structs containing:
          <ul>
            <li>the identifier of the activity</li>
            <li>the room handle of the activity channel</li>
          </ul>
        </tp:docstring>
      </arg>
      <tp:docstring>
        Get the activities of a particular contact.
      </tp:docstring>
      <tp:possible-errors>
        <tp:error name="org.freedesktop.Telepathy.Error.Disconnected"/>
        <tp:error name="org.freedesktop.Telepathy.Error.InvalidArgument"/>
      </tp:possible-errors>
    </method>

    <signal name="ActivitiesChanged">
      <arg name="contact" type="u">
        <tp:docstring>
          An integer handle representing the contact
        </tp:docstring>
      </arg>
      <arg name="activities" type="a(su)" tp:type="Activity[]">
        <tp:docstring xmlns="http://www.w3.org/1999/xhtml">
          An array of structs containing:
          <ul>
            <li>the identifier of the activity</li>
            <li>the handle of the activity channel</li>
          </ul>
        </tp:docstring>
      </arg>
      <tp:docstring>
        Signal emitted when the activities of a contact from your 'subscribe'
        contact list are changed.
      </tp:docstring>
    </signal>

    <method name="SetCurrentActivity">
      <arg direction="in" name="activity" type="s">
        <tp:docstring>
          The identifier of the activity, or the empty string if there is no
          current activity
        </tp:docstring>
      </arg>
      <arg direction="in" name="channel" type="u">
        <tp:docstring>
          The room handle of the activity channel, or 0 if there is no current
          activity
        </tp:docstring>
      </arg>
      <tp:docstring>
        Set the current activity of the local user for this connection.
      </tp:docstring>
      <tp:possible-errors>
        <tp:error name="org.freedesktop.Telepathy.Error.Disconnected"/>
        <tp:error name="org.freedesktop.Telepathy.Error.InvalidArgument"/>
      </tp:possible-errors>
    </method>

    <method name="GetCurrentActivity">
      <arg direction="in" name="contact" type="u">
        <tp:docstring>
          An integer handle for the contact whose current activity is to be
          returned
        </tp:docstring>
      </arg>
      <arg direction="out" name="activity" type="s">
        <tp:docstring>
          The identifier of the activity, or "" if there is no current activity
        </tp:docstring>
      </arg>
      <arg direction="out" name="channel" type="u">
        <tp:docstring>
          The room handle of the activity, or 0 if there is no current activity
        </tp:docstring>
      </arg>
      <tp:docstring>
        Get the current activity of a particular contact.
      </tp:docstring>
      <tp:possible-errors>
        <tp:error name="org.freedesktop.Telepathy.Error.Disconnected"/>
        <tp:error name="org.freedesktop.Telepathy.Error.InvalidArgument"/>
      </tp:possible-errors>
    </method>

    <signal name="CurrentActivityChanged">
      <arg name="contact" type="u">
        <tp:docstring>
          An integer handle representing the contact
        </tp:docstring>
      </arg>
      <arg name="activity" type="s">
        <tp:docstring>
          The identifier of the activity, or "" if there is no current activity
        </tp:docstring>
      </arg>
      <arg name="channel" type="u">
        <tp:docstring>
          The room handle of the activity channel, or 0 if there is no current
          activity
        </tp:docstring>
      </arg>
      <tp:docstring>
        Signal emitted when the current activity of a contact from your 'subscribe'
        contact list is changed.
      </tp:docstring>
    </signal>

    <tp:docstring xmlns="http://www.w3.org/1999/xhtml">
      <p>An interface on connections to associate OLPC buddy information
        with contacts, providing methods for the user to set their own
        information and retrieve information of contacts.
        The user is automatically notified when information of contacts that
        are in his 'subscribe' contact list change.</p>

      <p>The following types and names are used to request and set information
        (except for activities):</p>
      <dl>
        <dt>s:color</dt>
        <dd>The color name of the buddy. Format used is #RRGGBB,#RRGGBB
          (stroke,fill).
        </dd>

        <dt>ay:key</dt>
        <dd>The public key of the buddy.</dd>

        <dt>s:jid</dt>
        <dd>For link-local connections, the JID of the buddy's server account.</dd>
      </dl>

      <p>Activities are represented by a struct containing:</p>
      <ul>
        <li>the identifier of the activity</li>
        <li>the handle of the activity channel</li>
      </ul>
    </tp:docstring>
  </interface>
</node>
<!-- vim:set sw=2 sts=2 et ft=xml: -->