Added SILC Thread Queue API
[runtime.git] / apps / irssi / src / silc / core / silc-queries.h
1 /*
2
3   silc-queries.h 
4
5   Author: Pekka Riikonen <priikone@silcnet.org>
6
7   Copyright (C) 2002 Pekka Riikonen
8
9   This program is free software; you can redistribute it and/or modify
10   it under the terms of the GNU General Public License as published by
11   the Free Software Foundation; version 2 of the License.
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 */
19
20 #ifndef SILC_QUERIES_H
21 #define SILC_QUERIES_H
22
23 #include "chat-protocols.h"
24 #include "queries.h"
25 #include "silc-servers.h"
26
27 /* Returns SILC_QUERY_REC if it's SILC query, NULL if it isn't. */
28 #define SILC_QUERY(query) \
29         PROTO_CHECK_CAST(QUERY(query), QUERY_REC, chat_type, "SILC")
30 #define IS_SILC_QUERY(query) \
31         (SILC_QUERY(query) ? TRUE : FALSE)
32 #define silc_query_find(server, name) \
33         query_find(SERVER(server), name)
34
35 QUERY_REC *silc_query_create(const char *server_tag,
36                              const char *nick, int automatic);
37 void silc_queries_init(void);
38 void silc_queries_deinit(void);
39 void command_attr(const char *data, SILC_SERVER_REC *server,
40                   WI_ITEM_REC *item);
41 void silc_query_attributes_default(SilcClient client,
42                                    SilcClientConnection conn);
43 void silc_query_attributes_print(SILC_SERVER_REC *server,
44                                  SilcClient client,
45                                  SilcClientConnection conn,
46                                  SilcDList attrs,
47                                  SilcClientEntry client_entry);
48
49 #endif /* SILC_QUERIES_H */