stun_tag.h 3.82 KB
Newer Older
1 2 3
/*
 * This file is part of the Sofia-SIP package
 *
Pekka Pessi's avatar
Pekka Pessi committed
4
 * Copyright (C) 2005-2006 Nokia Corporation.
5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26
 *
 * Contact: Pekka Pessi <pekka.pessi@nokia.com>
 *
 * 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.
 *
 * 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.
 *
 * 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
 *
 */

#ifndef STUN_TAG_H
#define STUN_TAG_H
Pekka Pessi's avatar
Pekka Pessi committed
27
/**@file sofia-sip/stun_tag.h  Tags for STUN.
28 29
 *
 * @author Pekka Pessi <Pekka.Pessi@nokia.com>
Pekka Pessi's avatar
Pekka Pessi committed
30 31
 * @author Martti Mela <Martti.Mela@nokia.com>
 * @author Kai Vehmanen <Kai.Vehmanen@nokia.com>
32 33 34 35 36
 *
 * @date Created: Tue Oct 18 20:13:50 EEST 2005 ppessi
 */

#ifndef SU_TAG_H
37
#include <sofia-sip/su_tag.h>
38
#endif
39 40 41
#ifndef SU_TAG_IO_H
#include <sofia-sip/su_tag_io.h>
#endif
42

43 44
SOFIA_BEGIN_DECLS

Pekka Pessi's avatar
Pekka Pessi committed
45 46 47 48
/*****************************************
 * Note: see documentation in stun_tag.c *
 *****************************************/

49
#define STUNTAG_ANY()         stuntag_any, ((tag_value_t)0)
50
SOFIAPUBVAR tag_typedef_t stuntag_any;
51

Pekka Pessi's avatar
Pekka Pessi committed
52
#define STUNTAG_DOMAIN(x)  stuntag_domain, tag_str_v(x)
53
SOFIAPUBVAR tag_typedef_t stuntag_domain;
Pekka Pessi's avatar
Pekka Pessi committed
54
#define STUNTAG_DOMAIN_REF(x) stuntag_domain_ref, tag_str_vr(&(x))
55
SOFIAPUBVAR tag_typedef_t stuntag_domain_ref;
Pekka Pessi's avatar
Pekka Pessi committed
56

57
#define STUNTAG_SERVER(x)  stuntag_server, tag_str_v(x)
58
SOFIAPUBVAR tag_typedef_t stuntag_server;
59
#define STUNTAG_SERVER_REF(x) stuntag_server_ref, tag_str_vr(&(x))
60
SOFIAPUBVAR tag_typedef_t stuntag_server_ref;
61

Pekka Pessi's avatar
Pekka Pessi committed
62
#define STUNTAG_REQUIRE_INTEGRITY(x) stuntag_require_integrity, tag_int_v(x)
63
SOFIAPUBVAR tag_typedef_t stuntag_require_integrity;
Pekka Pessi's avatar
Pekka Pessi committed
64
#define STUNTAG_REQUIRE_INTEGRITY_REF(x) stuntag_require_integrity_ref, tag_int_vr(&(x))
65
SOFIAPUBVAR tag_typedef_t stuntag_require_integrity_ref;
Pekka Pessi's avatar
Pekka Pessi committed
66

67
#define STUNTAG_INTEGRITY(x) stuntag_integrity, tag_int_v(x)
68
SOFIAPUBVAR tag_typedef_t stuntag_integrity;
69
#define STUNTAG_INTEGRITY_REF(x) stuntag_integrity_ref, tag_int_vr(&(x))
70
SOFIAPUBVAR tag_typedef_t stuntag_integrity_ref;
71

72
#define STUNTAG_SOCKET(x) stuntag_socket, tag_socket_v(x)
73
SOFIAPUBVAR tag_typedef_t stuntag_socket;
74
#define STUNTAG_SOCKET_REF(x) stuntag_socket_ref, tag_socket_vr(&(x))
75
SOFIAPUBVAR tag_typedef_t stuntag_socket_ref;
76

77
#define STUNTAG_REGISTER_EVENTS(x) stuntag_register_events, tag_int_v(x)
78
SOFIAPUBVAR tag_typedef_t stuntag_register_events;
79
#define STUNTAG_REGISTER_EVENTS_REF(x) stuntag_register_events_ref, tag_int_vr(&(x))
80
SOFIAPUBVAR tag_typedef_t stuntag_register_events_ref;
81

82
#define STUNTAG_ACTION(x) stuntag_action, tag_int_v(x)
83
SOFIAPUBVAR tag_typedef_t stuntag_action;
84
#define STUNTAG_ACTION_REF(x) stuntag_action_ref, tag_int_vr(&(x))
85
SOFIAPUBVAR tag_typedef_t stuntag_action_ref;
86

87
#define STUNTAG_CHANGE_IP(x) stuntag_change_ip, tag_bool_v(x)
88
SOFIAPUBVAR tag_typedef_t stuntag_change_ip;
89
#define STUNTAG_CHANGE_IP_REF(x) stuntag_change_ip_ref, tag_bool_vr(&(x))
90
SOFIAPUBVAR tag_typedef_t stuntag_change_ip_ref;
91 92

#define STUNTAG_CHANGE_PORT(x) stuntag_change_port, tag_bool_v(x)
93
SOFIAPUBVAR tag_typedef_t stuntag_change_port;
94
#define STUNTAG_CHANGE_PORT_REF(x) stuntag_change_port_ref, tag_bool_vr(&(x))
95
SOFIAPUBVAR tag_typedef_t stuntag_change_port_ref;
96

97
#define STUNTAG_TIMEOUT(x) stuntag_timeout, tag_uint_v((x))
98
SOFIAPUBVAR tag_typedef_t stuntag_timeout;
99
#define STUNTAG_TIMEOUT_REF(x) stuntag_timeout_ref, tag_uint_vr(&(x))
100
SOFIAPUBVAR tag_typedef_t stuntag_timeout_ref;
101 102


103 104
SOFIA_END_DECLS

105
#endif /* STUN_TAG_H */