Mercurial > pidgin.yaz
comparison libgaim/server.h @ 14192:60b1bc8dbf37
[gaim-migrate @ 16863]
Renamed 'core' to 'libgaim'
committer: Tailor Script <tailor@pidgin.im>
author | Evan Schoenberg <evan.s@dreskin.net> |
---|---|
date | Sat, 19 Aug 2006 01:50:10 +0000 |
parents | |
children | 0a9c44ce9a4a |
comparison
equal
deleted
inserted
replaced
14191:009db0b357b5 | 14192:60b1bc8dbf37 |
---|---|
1 /** | |
2 * @file server.h Server API | |
3 * @ingroup core | |
4 * | |
5 * gaim | |
6 * | |
7 * Gaim is the legal property of its developers, whose names are too numerous | |
8 * to list here. Please refer to the COPYRIGHT file distributed with this | |
9 * source distribution. | |
10 * | |
11 * This program is free software; you can redistribute it and/or modify | |
12 * it under the terms of the GNU General Public License as published by | |
13 * the Free Software Foundation; either version 2 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 General Public License for more details. | |
20 * | |
21 * You should have received a copy of the GNU General Public License | |
22 * along with this program; if not, write to the Free Software | |
23 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | |
24 */ | |
25 #ifndef _GAIM_SERVER_H_ | |
26 #define _GAIM_SERVER_H_ | |
27 | |
28 #include "account.h" | |
29 #include "conversation.h" | |
30 #include "prpl.h" | |
31 | |
32 #ifdef __cplusplus | |
33 extern "C" { | |
34 #endif | |
35 | |
36 /** | |
37 * Send a typing message to a given user over a given connection. | |
38 * | |
39 * TODO: Could probably move this into the conversation API. | |
40 * | |
41 * @param typing One of GAIM_TYPING, GAIM_TYPED, or GAIM_NOT_TYPING. | |
42 * @return A quiet-period, specified in seconds, where Gaim will not | |
43 * send any additional typing notification messages. Most | |
44 * protocols should return 0, which means that no additional | |
45 * GAIM_TYPING messages need to be sent. If this is 5, for | |
46 * example, then Gaim will wait five seconds, and if the Gaim | |
47 * user is still typing then Gaim will send another GAIM_TYPING | |
48 * message. | |
49 */ | |
50 unsigned int serv_send_typing(GaimConnection *gc, const char *name, GaimTypingState state); | |
51 | |
52 void serv_move_buddy(GaimBuddy *, GaimGroup *, GaimGroup *); | |
53 int serv_send_im(GaimConnection *, const char *, const char *, GaimMessageFlags flags); | |
54 void serv_get_info(GaimConnection *, const char *); | |
55 void serv_set_info(GaimConnection *, const char *); | |
56 | |
57 void serv_add_permit(GaimConnection *, const char *); | |
58 void serv_add_deny(GaimConnection *, const char *); | |
59 void serv_rem_permit(GaimConnection *, const char *); | |
60 void serv_rem_deny(GaimConnection *, const char *); | |
61 void serv_set_permit_deny(GaimConnection *); | |
62 void serv_join_chat(GaimConnection *, GHashTable *); | |
63 void serv_reject_chat(GaimConnection *, GHashTable *); | |
64 void serv_chat_invite(GaimConnection *, int, const char *, const char *); | |
65 void serv_chat_leave(GaimConnection *, int); | |
66 void serv_chat_whisper(GaimConnection *, int, const char *, const char *); | |
67 int serv_chat_send(GaimConnection *, int, const char *, GaimMessageFlags flags); | |
68 void serv_alias_buddy(GaimBuddy *); | |
69 void serv_got_alias(GaimConnection *gc, const char *who, const char *alias); | |
70 | |
71 /** | |
72 * Receive a typing message from a remote user. Either GAIM_TYPING | |
73 * or GAIM_TYPED. If the user has stopped typing then use | |
74 * serv_got_typing_stopped instead. | |
75 * | |
76 * TODO: Could probably move this into the conversation API. | |
77 * | |
78 * @param timeout If this is a number greater than 0, then | |
79 * Gaim will wait this number of seconds and then | |
80 * set this buddy to the GAIM_NOT_TYPING state. This | |
81 * is used by protocols that send repeated typing messages | |
82 * while the user is composing the message. | |
83 */ | |
84 void serv_got_typing(GaimConnection *gc, const char *name, int timeout, | |
85 GaimTypingState state); | |
86 | |
87 /** | |
88 * TODO: Could probably move this into the conversation API. | |
89 */ | |
90 void serv_got_typing_stopped(GaimConnection *gc, const char *name); | |
91 | |
92 void serv_got_im(GaimConnection *gc, const char *who, const char *msg, | |
93 GaimMessageFlags flags, time_t mtime); | |
94 void serv_set_buddyicon(GaimConnection *gc, const char *filename); | |
95 void serv_got_chat_invite(GaimConnection *gc, const char *name, | |
96 const char *who, const char *message, | |
97 GHashTable *data); | |
98 GaimConversation *serv_got_joined_chat(GaimConnection *gc, | |
99 int id, const char *name); | |
100 void serv_got_chat_left(GaimConnection *g, int id); | |
101 void serv_got_chat_in(GaimConnection *g, int id, const char *who, | |
102 GaimMessageFlags flags, const char *message, time_t mtime); | |
103 void serv_send_file(GaimConnection *gc, const char *who, const char *file); | |
104 | |
105 #ifdef __cplusplus | |
106 } | |
107 #endif | |
108 | |
109 #endif /* _GAIM_SERVER_H_ */ |