/* * Asterisk -- An open source telephony toolkit. * * Copyright (C) 2007 Dave Chappell * * David Chappell * * See http://www.asterisk.org for more information about * the Asterisk project. Please do not directly contact * any of the maintainers of this project for assistance; * the project provides a web site, mailing lists and IRC * channels for your use. * * This program is free software, distributed under the terms of * the GNU General Public License Version 2. See the LICENSE file * at the top of the source tree. */ /*! \file * * \brief Trivial application to read an extension into a variable * * \author David Chappell * * \ingroup applications */ #include "asterisk.h" ASTERISK_FILE_VERSION(__FILE__, "$Revision$") #include "asterisk/lock.h" #include "asterisk/file.h" #include "asterisk/logger.h" #include "asterisk/channel.h" #include "asterisk/pbx.h" #include "asterisk/app.h" #include "asterisk/module.h" #include "asterisk/options.h" #include "asterisk/utils.h" #include "asterisk/indications.h" enum { OPT_SKIP = (1 << 0), OPT_INDICATION = (1 << 1), OPT_NOANSWER = (1 << 2), } readexten_option_flags; AST_APP_OPTIONS(readexten_app_options, { AST_APP_OPTION('s', OPT_SKIP), AST_APP_OPTION('i', OPT_INDICATION), AST_APP_OPTION('n', OPT_NOANSWER), }); static char *app = "ReadExten"; static char *synopsis = "Read an extension into a variable"; static char *descrip = " ReadExten([,[][,[][,[