comparison src/protocols/msn/msnslp.h @ 6701:b7e113a59b51

[gaim-migrate @ 7227] Updated to MSN Protocol 9. committer: Tailor Script <tailor@pidgin.im>
author Christian Hammond <chipx86@chipx86.com>
date Tue, 02 Sep 2003 04:32:16 +0000
parents
children 8efafdc38718
comparison
equal deleted inserted replaced
6700:57161e3abbb5 6701:b7e113a59b51
1 /**
2 * @file msnslp.h MSNSLP support
3 *
4 * gaim
5 *
6 * Copyright (C) 2003 Christian Hammond <chipx86@gnupdate.org>
7 *
8 * This program is free software; you can redistribute it and/or modify
9 * it under the terms of the GNU General Public License as published by
10 * the Free Software Foundation; either version 2 of the License, or
11 * (at your option) any later version.
12 *
13 * This program is distributed in the hope that it will be useful,
14 * but WITHOUT ANY WARRANTY; without even the implied warranty of
15 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16 * GNU General Public License for more details.
17 *
18 * You should have received a copy of the GNU General Public License
19 * along with this program; if not, write to the Free Software
20 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
21 */
22 #ifndef _MSN_SLP_H_
23 #define _MSN_SLP_H_
24
25 typedef struct
26 {
27 long session_id;
28 long id;
29 long offset;
30 long total_size;
31 long length;
32 long flags;
33 long prev_id;
34 long prev_f9;
35 long prev_total_size;
36
37 } MsnSlpHeader;
38
39 typedef struct
40 {
41 long app_id;
42
43 } MsnSlpFooter;
44
45 #include "switchboard.h"
46
47 typedef struct
48 {
49 gboolean local_initiated;
50
51 MsnSwitchBoard *swboard;
52
53 int session_id;
54 int prev_msg_id;
55
56 } MsnSlpSession;
57
58 /**
59 * Creates a MSNSLP session.
60 *
61 * @param swboard The switchboard.
62 * @param local_initiated TRUE if the session was initiated locally.
63 *
64 * @return The new MSNSLP session handle.
65 */
66 MsnSlpSession *msn_slp_session_new(MsnSwitchBoard *swboard,
67 gboolean local_initiated);
68
69 /**
70 * Destroys a MSNSLP session handle.
71 *
72 * This does not close the connection.
73 *
74 * @param slpsession The MSNSLP session to destroy.
75 */
76 void msn_slp_session_destroy(MsnSlpSession *slpsession);
77
78 /**
79 * Sends a message over a MSNSLP session.
80 *
81 * @param slpsession The MSNSLP session to send the message over.
82 * @param msg The message to send.
83 */
84 void msn_slp_session_send_msg(MsnSlpSession *session, MsnMessage *msg);
85
86 #endif /* _MSN_SLP_H_ */