Properly play a holdtime message if the announce-holdtime option is
[asterisk-bristuff.git] / include / asterisk / enum.h
blobc2fe3b5925b40f713b9459e512d7555df3006800
1 /*
2 * Asterisk -- An open source telephony toolkit.
4 * Copyright (C) 1999 - 2005, Digium, Inc.
6 * Mark Spencer <markster@digium.com>
8 * See http://www.asterisk.org for more information about
9 * the Asterisk project. Please do not directly contact
10 * any of the maintainers of this project for assistance;
11 * the project provides a web site, mailing lists and IRC
12 * channels for your use.
14 * This program is free software, distributed under the terms of
15 * the GNU General Public License Version 2. See the LICENSE file
16 * at the top of the source tree.
19 /*! \file enum.h
20 \brief DNS and ENUM functions
23 #ifndef _ASTERISK_ENUM_H
24 #define _ASTERISK_ENUM_H
26 #include "asterisk/channel.h"
28 /*! \brief Lookup entry in ENUM Returns 1 if found, 0 if not found, -1 on hangup
29 \param chan Channel
30 \param number E164 number with or without the leading +
31 \param location Number returned (or SIP uri)
32 \param maxloc Max length
33 \param technology Technology (from url scheme in response)
34 You can set it to get particular answer RR, if there are many techs in DNS response, example: "sip"
35 If you need any record, then set it to empty string
36 \param maxtech Max length
37 \param suffix Zone suffix (if is NULL then use enum.conf 'search' variable)
38 \param options Options ('c' to count number of NAPTR RR)
39 \param record The position of required RR in the answer list
41 int ast_get_enum(struct ast_channel *chan, const char *number, char *location, int maxloc, char *technology,
42 int maxtech, char* suffix, char* options, unsigned int record);
44 /*! \brief Lookup DNS TXT record (used by app TXTCIDnum
45 \param chan Channel
46 \param number E164 number with or without the leading +
47 \param location Number returned (or SIP uri)
48 \param maxloc Max length of number
49 \param technology Technology (not used in TXT records)
50 \param maxtech Max length
51 \param txt Text string (return value)
52 \param maxtxt Max length of "txt"
54 int ast_get_txt(struct ast_channel *chan, const char *number, char *location, int maxloc, char *technology, int maxtech, char *txt, int maxtxt);
56 int ast_enum_init(void);
57 int ast_enum_reload(void);
59 #endif /* _ASTERISK_ENUM_H */