libpurple/server.h

Fri, 06 Sep 2013 23:02:04 +0530

author
Ankit Vani <a@nevitus.org>
date
Fri, 06 Sep 2013 23:02:04 +0530
branch
soc.2013.gobjectification.plugins
changeset 36691
92122af1f083
parent 36637
9b0109ae118d
child 36782
64936dae41a3
permissions
-rw-r--r--

Some documentation updates with regard to 'protocol plugins' and 'protocols'

5872
754c63f29b77 [gaim-migrate @ 6304]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
1 /**
754c63f29b77 [gaim-migrate @ 6304]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
2 * @file server.h Server API
754c63f29b77 [gaim-migrate @ 6304]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
3 * @ingroup core
20147
66f05a854eee applied changes from 8a731bbd0197fbcc91a705c2d8f528154216defa
Richard Laager <rlaager@pidgin.im>
parents: 19862
diff changeset
4 */
66f05a854eee applied changes from 8a731bbd0197fbcc91a705c2d8f528154216defa
Richard Laager <rlaager@pidgin.im>
parents: 19862
diff changeset
5
66f05a854eee applied changes from 8a731bbd0197fbcc91a705c2d8f528154216defa
Richard Laager <rlaager@pidgin.im>
parents: 19862
diff changeset
6 /* purple
5872
754c63f29b77 [gaim-migrate @ 6304]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
7 *
15884
4de1981757fc sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
8 * Purple is the legal property of its developers, whose names are too numerous
8046
c581b20a47d6 [gaim-migrate @ 8730]
Sean Egan <seanegan@pidgin.im>
parents: 7118
diff changeset
9 * to list here. Please refer to the COPYRIGHT file distributed with this
c581b20a47d6 [gaim-migrate @ 8730]
Sean Egan <seanegan@pidgin.im>
parents: 7118
diff changeset
10 * source distribution.
6787
7d8e0ba98f68 [gaim-migrate @ 7326]
Christian Hammond <chipx86@chipx86.com>
parents: 6695
diff changeset
11 *
5872
754c63f29b77 [gaim-migrate @ 6304]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
12 * This program is free software; you can redistribute it and/or modify
754c63f29b77 [gaim-migrate @ 6304]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
13 * it under the terms of the GNU General Public License as published by
754c63f29b77 [gaim-migrate @ 6304]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
14 * the Free Software Foundation; either version 2 of the License, or
754c63f29b77 [gaim-migrate @ 6304]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
15 * (at your option) any later version.
754c63f29b77 [gaim-migrate @ 6304]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
16 *
754c63f29b77 [gaim-migrate @ 6304]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
17 * This program is distributed in the hope that it will be useful,
754c63f29b77 [gaim-migrate @ 6304]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
18 * but WITHOUT ANY WARRANTY; without even the implied warranty of
754c63f29b77 [gaim-migrate @ 6304]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
19 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
754c63f29b77 [gaim-migrate @ 6304]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
20 * GNU General Public License for more details.
754c63f29b77 [gaim-migrate @ 6304]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
21 *
754c63f29b77 [gaim-migrate @ 6304]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
22 * You should have received a copy of the GNU General Public License
754c63f29b77 [gaim-migrate @ 6304]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
23 * along with this program; if not, write to the Free Software
19859
71d37b57eff2 The FSF changed its address a while ago; our files were out of date.
John Bailey <rekkanoryo@rekkanoryo.org>
parents: 19639
diff changeset
24 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
5872
754c63f29b77 [gaim-migrate @ 6304]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
25 */
15884
4de1981757fc sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
26 #ifndef _PURPLE_SERVER_H_
4de1981757fc sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
27 #define _PURPLE_SERVER_H_
5872
754c63f29b77 [gaim-migrate @ 6304]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
28
34605
89e6c5346d63 Begun refactoring for PurpleConversation
Ankit Vani <a@nevitus.org>
parents: 32787
diff changeset
29 #include "accounts.h"
89e6c5346d63 Begun refactoring for PurpleConversation
Ankit Vani <a@nevitus.org>
parents: 32787
diff changeset
30 #include "conversations.h"
36543
a8c3fecee2d3 Renamed prpl.[ch] to protocol.[ch]
Ankit Vani <a@nevitus.org>
parents: 34670
diff changeset
31 #include "protocol.h"
5872
754c63f29b77 [gaim-migrate @ 6304]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
32
32787
7072f190d6ad Use G_BEGIN/END_DECLS in public libpurple files. This was
Elliott Sales de Andrade <qulogic@pidgin.im>
parents: 32301
diff changeset
33 G_BEGIN_DECLS
5944
f19df037ac58 [gaim-migrate @ 6385]
Christian Hammond <chipx86@chipx86.com>
parents: 5872
diff changeset
34
13844
835b8f7b3d1d [gaim-migrate @ 16295]
Mark Doliner <markdoliner@pidgin.im>
parents: 13295
diff changeset
35 /**
835b8f7b3d1d [gaim-migrate @ 16295]
Mark Doliner <markdoliner@pidgin.im>
parents: 13295
diff changeset
36 * Send a typing message to a given user over a given connection.
835b8f7b3d1d [gaim-migrate @ 16295]
Mark Doliner <markdoliner@pidgin.im>
parents: 13295
diff changeset
37 *
835b8f7b3d1d [gaim-migrate @ 16295]
Mark Doliner <markdoliner@pidgin.im>
parents: 13295
diff changeset
38 * TODO: Could probably move this into the conversation API.
835b8f7b3d1d [gaim-migrate @ 16295]
Mark Doliner <markdoliner@pidgin.im>
parents: 13295
diff changeset
39 *
16262
1d9b65303dfc Doxygen updates. This eliminated all the warnings from Doxygen.
Richard Laager <rlaager@pidgin.im>
parents: 15997
diff changeset
40 * @param gc The connection over which to send the typing notification.
1d9b65303dfc Doxygen updates. This eliminated all the warnings from Doxygen.
Richard Laager <rlaager@pidgin.im>
parents: 15997
diff changeset
41 * @param name The user to send the typing notification to.
34670
9bd5bd903dc7 Renamed chat buddies to chat users, and IM conversation typing state to IM typing state.
Ankit Vani <a@nevitus.org>
parents: 34632
diff changeset
42 * @param state One of PURPLE_IM_TYPING, PURPLE_IM_TYPED, or PURPLE_IM_NOT_TYPING.
15884
4de1981757fc sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
43 * @return A quiet-period, specified in seconds, where Purple will not
13844
835b8f7b3d1d [gaim-migrate @ 16295]
Mark Doliner <markdoliner@pidgin.im>
parents: 13295
diff changeset
44 * send any additional typing notification messages. Most
835b8f7b3d1d [gaim-migrate @ 16295]
Mark Doliner <markdoliner@pidgin.im>
parents: 13295
diff changeset
45 * protocols should return 0, which means that no additional
34670
9bd5bd903dc7 Renamed chat buddies to chat users, and IM conversation typing state to IM typing state.
Ankit Vani <a@nevitus.org>
parents: 34632
diff changeset
46 * PURPLE_IM_TYPING messages need to be sent. If this is 5, for
15884
4de1981757fc sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
47 * example, then Purple will wait five seconds, and if the Purple
34670
9bd5bd903dc7 Renamed chat buddies to chat users, and IM conversation typing state to IM typing state.
Ankit Vani <a@nevitus.org>
parents: 34632
diff changeset
48 * user is still typing then Purple will send another PURPLE_IM_TYPING
13844
835b8f7b3d1d [gaim-migrate @ 16295]
Mark Doliner <markdoliner@pidgin.im>
parents: 13295
diff changeset
49 * message.
835b8f7b3d1d [gaim-migrate @ 16295]
Mark Doliner <markdoliner@pidgin.im>
parents: 13295
diff changeset
50 */
34670
9bd5bd903dc7 Renamed chat buddies to chat users, and IM conversation typing state to IM typing state.
Ankit Vani <a@nevitus.org>
parents: 34632
diff changeset
51 unsigned int serv_send_typing(PurpleConnection *gc, const char *name, PurpleIMTypingState state);
13844
835b8f7b3d1d [gaim-migrate @ 16295]
Mark Doliner <markdoliner@pidgin.im>
parents: 13295
diff changeset
52
15884
4de1981757fc sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
53 void serv_move_buddy(PurpleBuddy *, PurpleGroup *, PurpleGroup *);
34620
e49aa67344e1 Renamed PurpleConversationMessageFlags back to PurpleMessageFlags.
Ankit Vani <a@nevitus.org>
parents: 34605
diff changeset
54 int serv_send_im(PurpleConnection *, const char *, const char *, PurpleMessageFlags flags);
19639
93a56951f439 In the attention API, use the PURPLE_NOTIFY_MESSAGE flag to serv_got_im()
Jeff Connelly <jeff2@soc.pidgin.im>
parents: 19604
diff changeset
55
36637
9b0109ae118d Renamed some prpl stuff to protocol stuff.
Ankit Vani <a@nevitus.org>
parents: 36543
diff changeset
56 /** Get information about an account's attention commands, from the protocol.
25888
d0fdd378a635 Remove trailing whitespace
Mark Doliner <markdoliner@pidgin.im>
parents: 23875
diff changeset
57 *
36637
9b0109ae118d Renamed some prpl stuff to protocol stuff.
Ankit Vani <a@nevitus.org>
parents: 36543
diff changeset
58 * @return The attention command numbered 'code' from the protocol's attention_types, or NULL.
19639
93a56951f439 In the attention API, use the PURPLE_NOTIFY_MESSAGE flag to serv_got_im()
Jeff Connelly <jeff2@soc.pidgin.im>
parents: 19604
diff changeset
59 */
93a56951f439 In the attention API, use the PURPLE_NOTIFY_MESSAGE flag to serv_got_im()
Jeff Connelly <jeff2@soc.pidgin.im>
parents: 19604
diff changeset
60 PurpleAttentionType *purple_get_attention_type_from_code(PurpleAccount *account, guint type_code);
93a56951f439 In the attention API, use the PURPLE_NOTIFY_MESSAGE flag to serv_got_im()
Jeff Connelly <jeff2@soc.pidgin.im>
parents: 19604
diff changeset
61
15884
4de1981757fc sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
62 void serv_get_info(PurpleConnection *, const char *);
4de1981757fc sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
63 void serv_set_info(PurpleConnection *, const char *);
13844
835b8f7b3d1d [gaim-migrate @ 16295]
Mark Doliner <markdoliner@pidgin.im>
parents: 13295
diff changeset
64
15884
4de1981757fc sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
65 void serv_add_permit(PurpleConnection *, const char *);
4de1981757fc sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
66 void serv_add_deny(PurpleConnection *, const char *);
4de1981757fc sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
67 void serv_rem_permit(PurpleConnection *, const char *);
4de1981757fc sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
68 void serv_rem_deny(PurpleConnection *, const char *);
4de1981757fc sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
69 void serv_set_permit_deny(PurpleConnection *);
4de1981757fc sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
70 void serv_chat_invite(PurpleConnection *, int, const char *, const char *);
4de1981757fc sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
71 void serv_chat_leave(PurpleConnection *, int);
4de1981757fc sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
72 void serv_chat_whisper(PurpleConnection *, int, const char *, const char *);
34620
e49aa67344e1 Renamed PurpleConversationMessageFlags back to PurpleMessageFlags.
Ankit Vani <a@nevitus.org>
parents: 34605
diff changeset
73 int serv_chat_send(PurpleConnection *, int, const char *, PurpleMessageFlags flags);
15884
4de1981757fc sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
74 void serv_alias_buddy(PurpleBuddy *);
4de1981757fc sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
75 void serv_got_alias(PurpleConnection *gc, const char *who, const char *alias);
19639
93a56951f439 In the attention API, use the PURPLE_NOTIFY_MESSAGE flag to serv_got_im()
Jeff Connelly <jeff2@soc.pidgin.im>
parents: 19604
diff changeset
76
22474
d08590a6660c This is part of a patch from felipec, also known as shx, that adds
John Bailey <rekkanoryo@rekkanoryo.org>
parents: 20147
diff changeset
77 /**
36691
92122af1f083 Some documentation updates with regard to 'protocol plugins' and 'protocols'
Ankit Vani <a@nevitus.org>
parents: 36637
diff changeset
78 * A protocol should call this when it retrieves a private alias from
22474
d08590a6660c This is part of a patch from felipec, also known as shx, that adds
John Bailey <rekkanoryo@rekkanoryo.org>
parents: 20147
diff changeset
79 * the server. Private aliases are the aliases the user sets, while public
d08590a6660c This is part of a patch from felipec, also known as shx, that adds
John Bailey <rekkanoryo@rekkanoryo.org>
parents: 20147
diff changeset
80 * aliases are the aliases or display names that buddies set for themselves.
d08590a6660c This is part of a patch from felipec, also known as shx, that adds
John Bailey <rekkanoryo@rekkanoryo.org>
parents: 20147
diff changeset
81 *
d08590a6660c This is part of a patch from felipec, also known as shx, that adds
John Bailey <rekkanoryo@rekkanoryo.org>
parents: 20147
diff changeset
82 * @param gc The connection on which the alias was received.
25889
26d9ca30335c Change "screen name" to "username" or "buddy name" in a whole bunch of
Mark Doliner <markdoliner@pidgin.im>
parents: 25888
diff changeset
83 * @param who The name of the buddy whose alias was received.
22474
d08590a6660c This is part of a patch from felipec, also known as shx, that adds
John Bailey <rekkanoryo@rekkanoryo.org>
parents: 20147
diff changeset
84 * @param alias The alias that was received.
d08590a6660c This is part of a patch from felipec, also known as shx, that adds
John Bailey <rekkanoryo@rekkanoryo.org>
parents: 20147
diff changeset
85 */
d08590a6660c This is part of a patch from felipec, also known as shx, that adds
John Bailey <rekkanoryo@rekkanoryo.org>
parents: 20147
diff changeset
86 void purple_serv_got_private_alias(PurpleConnection *gc, const char *who, const char *alias);
d08590a6660c This is part of a patch from felipec, also known as shx, that adds
John Bailey <rekkanoryo@rekkanoryo.org>
parents: 20147
diff changeset
87
13844
835b8f7b3d1d [gaim-migrate @ 16295]
Mark Doliner <markdoliner@pidgin.im>
parents: 13295
diff changeset
88
835b8f7b3d1d [gaim-migrate @ 16295]
Mark Doliner <markdoliner@pidgin.im>
parents: 13295
diff changeset
89 /**
34670
9bd5bd903dc7 Renamed chat buddies to chat users, and IM conversation typing state to IM typing state.
Ankit Vani <a@nevitus.org>
parents: 34632
diff changeset
90 * Receive a typing message from a remote user. Either PURPLE_IM_TYPING
9bd5bd903dc7 Renamed chat buddies to chat users, and IM conversation typing state to IM typing state.
Ankit Vani <a@nevitus.org>
parents: 34632
diff changeset
91 * or PURPLE_IM_TYPED. If the user has stopped typing then use
13844
835b8f7b3d1d [gaim-migrate @ 16295]
Mark Doliner <markdoliner@pidgin.im>
parents: 13295
diff changeset
92 * serv_got_typing_stopped instead.
835b8f7b3d1d [gaim-migrate @ 16295]
Mark Doliner <markdoliner@pidgin.im>
parents: 13295
diff changeset
93 *
835b8f7b3d1d [gaim-migrate @ 16295]
Mark Doliner <markdoliner@pidgin.im>
parents: 13295
diff changeset
94 * TODO: Could probably move this into the conversation API.
835b8f7b3d1d [gaim-migrate @ 16295]
Mark Doliner <markdoliner@pidgin.im>
parents: 13295
diff changeset
95 *
16262
1d9b65303dfc Doxygen updates. This eliminated all the warnings from Doxygen.
Richard Laager <rlaager@pidgin.im>
parents: 15997
diff changeset
96 * @param gc The connection on which the typing message was received.
1d9b65303dfc Doxygen updates. This eliminated all the warnings from Doxygen.
Richard Laager <rlaager@pidgin.im>
parents: 15997
diff changeset
97 * @param name The name of the remote user.
13844
835b8f7b3d1d [gaim-migrate @ 16295]
Mark Doliner <markdoliner@pidgin.im>
parents: 13295
diff changeset
98 * @param timeout If this is a number greater than 0, then
15884
4de1981757fc sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
99 * Purple will wait this number of seconds and then
34670
9bd5bd903dc7 Renamed chat buddies to chat users, and IM conversation typing state to IM typing state.
Ankit Vani <a@nevitus.org>
parents: 34632
diff changeset
100 * set this buddy to the PURPLE_IM_NOT_TYPING state. This
13844
835b8f7b3d1d [gaim-migrate @ 16295]
Mark Doliner <markdoliner@pidgin.im>
parents: 13295
diff changeset
101 * is used by protocols that send repeated typing messages
835b8f7b3d1d [gaim-migrate @ 16295]
Mark Doliner <markdoliner@pidgin.im>
parents: 13295
diff changeset
102 * while the user is composing the message.
16262
1d9b65303dfc Doxygen updates. This eliminated all the warnings from Doxygen.
Richard Laager <rlaager@pidgin.im>
parents: 15997
diff changeset
103 * @param state The typing state received
13844
835b8f7b3d1d [gaim-migrate @ 16295]
Mark Doliner <markdoliner@pidgin.im>
parents: 13295
diff changeset
104 */
15884
4de1981757fc sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
105 void serv_got_typing(PurpleConnection *gc, const char *name, int timeout,
34670
9bd5bd903dc7 Renamed chat buddies to chat users, and IM conversation typing state to IM typing state.
Ankit Vani <a@nevitus.org>
parents: 34632
diff changeset
106 PurpleIMTypingState state);
13844
835b8f7b3d1d [gaim-migrate @ 16295]
Mark Doliner <markdoliner@pidgin.im>
parents: 13295
diff changeset
107
835b8f7b3d1d [gaim-migrate @ 16295]
Mark Doliner <markdoliner@pidgin.im>
parents: 13295
diff changeset
108 /**
835b8f7b3d1d [gaim-migrate @ 16295]
Mark Doliner <markdoliner@pidgin.im>
parents: 13295
diff changeset
109 * TODO: Could probably move this into the conversation API.
835b8f7b3d1d [gaim-migrate @ 16295]
Mark Doliner <markdoliner@pidgin.im>
parents: 13295
diff changeset
110 */
15884
4de1981757fc sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
111 void serv_got_typing_stopped(PurpleConnection *gc, const char *name);
13844
835b8f7b3d1d [gaim-migrate @ 16295]
Mark Doliner <markdoliner@pidgin.im>
parents: 13295
diff changeset
112
15884
4de1981757fc sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
113 void serv_got_im(PurpleConnection *gc, const char *who, const char *msg,
34620
e49aa67344e1 Renamed PurpleConversationMessageFlags back to PurpleMessageFlags.
Ankit Vani <a@nevitus.org>
parents: 34605
diff changeset
114 PurpleMessageFlags flags, time_t mtime);
15203
1a092806f344 [gaim-migrate @ 17927]
Mark Doliner <markdoliner@pidgin.im>
parents: 15043
diff changeset
115
1a092806f344 [gaim-migrate @ 17927]
Mark Doliner <markdoliner@pidgin.im>
parents: 15043
diff changeset
116 /**
1a092806f344 [gaim-migrate @ 17927]
Mark Doliner <markdoliner@pidgin.im>
parents: 15043
diff changeset
117 * @param data The hash function should be g_str_hash() and the equal
1a092806f344 [gaim-migrate @ 17927]
Mark Doliner <markdoliner@pidgin.im>
parents: 15043
diff changeset
118 * function should be g_str_equal().
1a092806f344 [gaim-migrate @ 17927]
Mark Doliner <markdoliner@pidgin.im>
parents: 15043
diff changeset
119 */
15997
ff97c5f69196 A little doxygen love and some tiny gaim->purpleisms
Mark Doliner <markdoliner@pidgin.im>
parents: 15884
diff changeset
120 void serv_join_chat(PurpleConnection *, GHashTable *data);
15203
1a092806f344 [gaim-migrate @ 17927]
Mark Doliner <markdoliner@pidgin.im>
parents: 15043
diff changeset
121
1a092806f344 [gaim-migrate @ 17927]
Mark Doliner <markdoliner@pidgin.im>
parents: 15043
diff changeset
122 /**
1a092806f344 [gaim-migrate @ 17927]
Mark Doliner <markdoliner@pidgin.im>
parents: 15043
diff changeset
123 * @param data The hash function should be g_str_hash() and the equal
1a092806f344 [gaim-migrate @ 17927]
Mark Doliner <markdoliner@pidgin.im>
parents: 15043
diff changeset
124 * function should be g_str_equal().
1a092806f344 [gaim-migrate @ 17927]
Mark Doliner <markdoliner@pidgin.im>
parents: 15043
diff changeset
125 */
15997
ff97c5f69196 A little doxygen love and some tiny gaim->purpleisms
Mark Doliner <markdoliner@pidgin.im>
parents: 15884
diff changeset
126 void serv_reject_chat(PurpleConnection *, GHashTable *data);
15203
1a092806f344 [gaim-migrate @ 17927]
Mark Doliner <markdoliner@pidgin.im>
parents: 15043
diff changeset
127
1a092806f344 [gaim-migrate @ 17927]
Mark Doliner <markdoliner@pidgin.im>
parents: 15043
diff changeset
128 /**
36637
9b0109ae118d Renamed some prpl stuff to protocol stuff.
Ankit Vani <a@nevitus.org>
parents: 36543
diff changeset
129 * Called by a protocol when an account is invited into a chat.
16262
1d9b65303dfc Doxygen updates. This eliminated all the warnings from Doxygen.
Richard Laager <rlaager@pidgin.im>
parents: 15997
diff changeset
130 *
1d9b65303dfc Doxygen updates. This eliminated all the warnings from Doxygen.
Richard Laager <rlaager@pidgin.im>
parents: 15997
diff changeset
131 * @param gc The connection on which the invite arrived.
1d9b65303dfc Doxygen updates. This eliminated all the warnings from Doxygen.
Richard Laager <rlaager@pidgin.im>
parents: 15997
diff changeset
132 * @param name The name of the chat you're being invited to.
1d9b65303dfc Doxygen updates. This eliminated all the warnings from Doxygen.
Richard Laager <rlaager@pidgin.im>
parents: 15997
diff changeset
133 * @param who The username of the person inviting the account.
1d9b65303dfc Doxygen updates. This eliminated all the warnings from Doxygen.
Richard Laager <rlaager@pidgin.im>
parents: 15997
diff changeset
134 * @param message The optional invite message.
1d9b65303dfc Doxygen updates. This eliminated all the warnings from Doxygen.
Richard Laager <rlaager@pidgin.im>
parents: 15997
diff changeset
135 * @param data The components necessary if you want to call serv_join_chat().
1d9b65303dfc Doxygen updates. This eliminated all the warnings from Doxygen.
Richard Laager <rlaager@pidgin.im>
parents: 15997
diff changeset
136 * The hash function should be g_str_hash() and the equal
1d9b65303dfc Doxygen updates. This eliminated all the warnings from Doxygen.
Richard Laager <rlaager@pidgin.im>
parents: 15997
diff changeset
137 * function should be g_str_equal().
15203
1a092806f344 [gaim-migrate @ 17927]
Mark Doliner <markdoliner@pidgin.im>
parents: 15043
diff changeset
138 */
15884
4de1981757fc sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
139 void serv_got_chat_invite(PurpleConnection *gc, const char *name,
5872
754c63f29b77 [gaim-migrate @ 6304]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
140 const char *who, const char *message,
754c63f29b77 [gaim-migrate @ 6304]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
141 GHashTable *data);
15203
1a092806f344 [gaim-migrate @ 17927]
Mark Doliner <markdoliner@pidgin.im>
parents: 15043
diff changeset
142
28684
b4c337df39a1 Documented chat API. References #10605
Felix Kerekes <sttwister@soc.pidgin.im>
parents: 25889
diff changeset
143 /**
36637
9b0109ae118d Renamed some prpl stuff to protocol stuff.
Ankit Vani <a@nevitus.org>
parents: 36543
diff changeset
144 * Called by a protocol when an account has joined a chat.
28684
b4c337df39a1 Documented chat API. References #10605
Felix Kerekes <sttwister@soc.pidgin.im>
parents: 25889
diff changeset
145 *
31293
169eeb43b52c Remove trailing whitespace
Richard Laager <rlaager@pidgin.im>
parents: 28684
diff changeset
146 * @param gc The connection on which the chat was joined.
36637
9b0109ae118d Renamed some prpl stuff to protocol stuff.
Ankit Vani <a@nevitus.org>
parents: 36543
diff changeset
147 * @param id The id of the chat, assigned by the protocol.
28684
b4c337df39a1 Documented chat API. References #10605
Felix Kerekes <sttwister@soc.pidgin.im>
parents: 25889
diff changeset
148 * @param name The name of the chat.
b4c337df39a1 Documented chat API. References #10605
Felix Kerekes <sttwister@soc.pidgin.im>
parents: 25889
diff changeset
149 * @return The resulting conversation
b4c337df39a1 Documented chat API. References #10605
Felix Kerekes <sttwister@soc.pidgin.im>
parents: 25889
diff changeset
150 */
34632
ebe6b2a60305 Changed all arguments and return types of Chat and IMs to PurpleChatConversation and PurpleIMConversation.
Ankit Vani <a@nevitus.org>
parents: 34622
diff changeset
151 PurpleChatConversation *serv_got_joined_chat(PurpleConnection *gc,
5872
754c63f29b77 [gaim-migrate @ 6304]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
152 int id, const char *name);
22920
6681f6f71dfc applied changes from feb2303b4209e0eeb4e20beaf151b1e4368c4e03
Evan Schoenberg <evands@pidgin.im>
parents: 22919
diff changeset
153 /**
36637
9b0109ae118d Renamed some prpl stuff to protocol stuff.
Ankit Vani <a@nevitus.org>
parents: 36543
diff changeset
154 * Called by a protocol when an attempt to join a chat via serv_join_chat()
22920
6681f6f71dfc applied changes from feb2303b4209e0eeb4e20beaf151b1e4368c4e03
Evan Schoenberg <evands@pidgin.im>
parents: 22919
diff changeset
155 * fails.
6681f6f71dfc applied changes from feb2303b4209e0eeb4e20beaf151b1e4368c4e03
Evan Schoenberg <evands@pidgin.im>
parents: 22919
diff changeset
156 *
6681f6f71dfc applied changes from feb2303b4209e0eeb4e20beaf151b1e4368c4e03
Evan Schoenberg <evands@pidgin.im>
parents: 22919
diff changeset
157 * @param gc The connection on which chat joining failed
23270
2b7db16e721a As discussed on the devel list, purple_serv_got_join_chat_failed() and the
Evan Schoenberg <evands@pidgin.im>
parents: 22920
diff changeset
158 * @param data The components passed to serv_join_chat() originally.
2b7db16e721a As discussed on the devel list, purple_serv_got_join_chat_failed() and the
Evan Schoenberg <evands@pidgin.im>
parents: 22920
diff changeset
159 * The hash function should be g_str_hash() and the equal
2b7db16e721a As discussed on the devel list, purple_serv_got_join_chat_failed() and the
Evan Schoenberg <evands@pidgin.im>
parents: 22920
diff changeset
160 * function should be g_str_equal().
22920
6681f6f71dfc applied changes from feb2303b4209e0eeb4e20beaf151b1e4368c4e03
Evan Schoenberg <evands@pidgin.im>
parents: 22919
diff changeset
161 */
23270
2b7db16e721a As discussed on the devel list, purple_serv_got_join_chat_failed() and the
Evan Schoenberg <evands@pidgin.im>
parents: 22920
diff changeset
162 void purple_serv_got_join_chat_failed(PurpleConnection *gc, GHashTable *data);
25888
d0fdd378a635 Remove trailing whitespace
Mark Doliner <markdoliner@pidgin.im>
parents: 23875
diff changeset
163
28684
b4c337df39a1 Documented chat API. References #10605
Felix Kerekes <sttwister@soc.pidgin.im>
parents: 25889
diff changeset
164 /**
36637
9b0109ae118d Renamed some prpl stuff to protocol stuff.
Ankit Vani <a@nevitus.org>
parents: 36543
diff changeset
165 * Called by a protocol when an account has left a chat.
28684
b4c337df39a1 Documented chat API. References #10605
Felix Kerekes <sttwister@soc.pidgin.im>
parents: 25889
diff changeset
166 *
b4c337df39a1 Documented chat API. References #10605
Felix Kerekes <sttwister@soc.pidgin.im>
parents: 25889
diff changeset
167 * @param g The connection on which the chat was left.
36637
9b0109ae118d Renamed some prpl stuff to protocol stuff.
Ankit Vani <a@nevitus.org>
parents: 36543
diff changeset
168 * @param id The id of the chat, as assigned by the protocol.
28684
b4c337df39a1 Documented chat API. References #10605
Felix Kerekes <sttwister@soc.pidgin.im>
parents: 25889
diff changeset
169 */
15884
4de1981757fc sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
170 void serv_got_chat_left(PurpleConnection *g, int id);
28684
b4c337df39a1 Documented chat API. References #10605
Felix Kerekes <sttwister@soc.pidgin.im>
parents: 25889
diff changeset
171
b4c337df39a1 Documented chat API. References #10605
Felix Kerekes <sttwister@soc.pidgin.im>
parents: 25889
diff changeset
172 /**
36637
9b0109ae118d Renamed some prpl stuff to protocol stuff.
Ankit Vani <a@nevitus.org>
parents: 36543
diff changeset
173 * Called by a protocol when a message has been received in a chat.
28684
b4c337df39a1 Documented chat API. References #10605
Felix Kerekes <sttwister@soc.pidgin.im>
parents: 25889
diff changeset
174 *
b4c337df39a1 Documented chat API. References #10605
Felix Kerekes <sttwister@soc.pidgin.im>
parents: 25889
diff changeset
175 * @param g The connection on which the message was received.
36637
9b0109ae118d Renamed some prpl stuff to protocol stuff.
Ankit Vani <a@nevitus.org>
parents: 36543
diff changeset
176 * @param id The id of the chat, as assigned by the protocol.
28684
b4c337df39a1 Documented chat API. References #10605
Felix Kerekes <sttwister@soc.pidgin.im>
parents: 25889
diff changeset
177 * @param who The name of the user who sent the message.
b4c337df39a1 Documented chat API. References #10605
Felix Kerekes <sttwister@soc.pidgin.im>
parents: 25889
diff changeset
178 * @param flags The flags of the message.
b4c337df39a1 Documented chat API. References #10605
Felix Kerekes <sttwister@soc.pidgin.im>
parents: 25889
diff changeset
179 * @param message The message received in the chat.
b4c337df39a1 Documented chat API. References #10605
Felix Kerekes <sttwister@soc.pidgin.im>
parents: 25889
diff changeset
180 * @param mtime The time when the message was received.
b4c337df39a1 Documented chat API. References #10605
Felix Kerekes <sttwister@soc.pidgin.im>
parents: 25889
diff changeset
181 */
15884
4de1981757fc sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
182 void serv_got_chat_in(PurpleConnection *g, int id, const char *who,
34620
e49aa67344e1 Renamed PurpleConversationMessageFlags back to PurpleMessageFlags.
Ankit Vani <a@nevitus.org>
parents: 34605
diff changeset
183 PurpleMessageFlags flags, const char *message, time_t mtime);
15884
4de1981757fc sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
184 void serv_send_file(PurpleConnection *gc, const char *who, const char *file);
5872
754c63f29b77 [gaim-migrate @ 6304]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
185
32787
7072f190d6ad Use G_BEGIN/END_DECLS in public libpurple files. This was
Elliott Sales de Andrade <qulogic@pidgin.im>
parents: 32301
diff changeset
186 G_END_DECLS
5944
f19df037ac58 [gaim-migrate @ 6385]
Christian Hammond <chipx86@chipx86.com>
parents: 5872
diff changeset
187
15884
4de1981757fc sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
188 #endif /* _PURPLE_SERVER_H_ */
32787
7072f190d6ad Use G_BEGIN/END_DECLS in public libpurple files. This was
Elliott Sales de Andrade <qulogic@pidgin.im>
parents: 32301
diff changeset
189

mercurial