Defines a program. More...
#include <Grammar.h>
Public Member Functions | |
| CModule & | axiom (String name) |
| Declares the starting rule object. | |
| CModule & | add (CRule &rule) |
| Adds a rule. | |
| CRule & | begin (String name) |
| Starts the definition of a new rule object. | |
| void | saveToFile (const char *filename) |
| Saves the program to a file name. | |
| void | loadFromFile (const char *filename, char *debugfile=NULL) |
| Loads a program from a file name. | |
Public Attributes | |
| TMap< String, TVector< CRule > > | rules |
| Maps rules to identifiers. A single identifier can be shared by many rules. | |
| String | baseAxiom |
| Stores the base axiom. | |