[svn-commits] branch murf/AAL r21449 -
/team/murf/AAL/include/asterisk/argdesc.h
svn-commits at lists.digium.com
svn-commits at lists.digium.com
Wed Apr 19 06:17:28 MST 2006
Author: murf
Date: Wed Apr 19 08:17:26 2006
New Revision: 21449
URL: http://svn.digium.com/view/asterisk?rev=21449&view=rev
Log:
Copying in work done with AEL.
Added:
team/murf/AAL/include/asterisk/argdesc.h (with props)
Added: team/murf/AAL/include/asterisk/argdesc.h
URL: http://svn.digium.com/view/asterisk/team/murf/AAL/include/asterisk/argdesc.h?rev=21449&view=auto
==============================================================================
--- team/murf/AAL/include/asterisk/argdesc.h (added)
+++ team/murf/AAL/include/asterisk/argdesc.h Wed Apr 19 08:17:26 2006
@@ -1,0 +1,55 @@
+#ifndef INC_ARGDESC_H
+
+typedef enum {ARGD_REQUIRED, ARGD_OPTIONAL, ARGD_OPTIONAL_PREV,ARGD_OPTIONAL_PLACEHOLD} argtype;
+typedef enum {ARGD_STRING, ARGD_INT, ARGD_FLOAT, ARGD_ENUM, ARGD_OPTIONSET, ARGD_VARARG } argdtype;
+typedef enum {ARGD_OPT_NOARG, ARGD_OPT_WITHARG, ARGD_OPT_WITHOPTARG, } argdopttype;
+
+struct argapp
+{
+ char *name;
+ char *desc;
+ struct argdesc *args;
+ struct appsetvar *setvars;
+ struct argchoice *opts;
+ struct argapp *next;
+};
+
+struct argdesc
+{
+ argtype type; /* REQUIRED, OPTIONAL, OPTIONAL_PREV */
+ argdtype dtype; /* STRING, INT,FLOAT, ENUM, OPTIONSET, VARARG */
+ char *name;
+ struct argchoice *choices; /* if dtype == ENUM */
+
+ struct argdesc *last_args; /* for makeing an ordered list */
+ struct argdesc *next;
+};
+
+struct appsetvar
+{
+ char *name;
+ struct argchoice *vals;
+ struct appsetvar *next;
+};
+
+struct argchoice
+{
+ char *name;
+ argdopttype opttype; /* IF THIS IS AN OPTION LIST */
+ struct argchoice *next;
+};
+
+/* for passing info into and out of yyparse */
+
+struct parse_arginfo
+{
+ struct argapp *apps; /* yyparse will set this to point to the parse tree */
+ void *scanner; /* yylex needs a scanner. Set it up, and pass it in */
+ int syntax_error_count; /* the count of syntax errors encountered */
+};
+
+struct argapp *argdesc_parse(char *filename, int *errors);
+void argdesc_destroy(struct argapp *apps);
+
+#define INC_ARGDESC_H
+#endif
Propchange: team/murf/AAL/include/asterisk/argdesc.h
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: team/murf/AAL/include/asterisk/argdesc.h
------------------------------------------------------------------------------
svn:keywords = Author Date Id Revision
Propchange: team/murf/AAL/include/asterisk/argdesc.h
------------------------------------------------------------------------------
svn:mime-type = text/plain
More information about the svn-commits
mailing list