This file contains implementation of sourceparser.cpp. More...
#include "tools/schema/sourceparser.hpp"#include "boost/regex.hpp"#include <stack>
Go to the source code of this file.
Namespaces | |
| namespace | schema_validation |
Functions | |
| static std::string | schema_validation::sub (const std::string &s) |
| Private function to surround an argument with brackets. | |
| static std::string | schema_validation::quote (const std::string &s) |
| Private function to surround argument with not mandatory quotes. | |
| static std::string | schema_validation::property (const std::string &name, const std::string &value="") |
| Creates a property template. | |
| const std::string & | schema_validation::get_valid () |
| A few regex templates. | |
| const std::string & | schema_validation::get_wiki () |
| Template to check line is beginnnig of Wiki block. | |
| const std::string & | schema_validation::get_parent_begin () |
| Template to check begining of parent block. | |
| const std::string & | schema_validation::get_parent_end () |
| Template to check closing of parent block. | |
| const std::string & | schema_validation::get_tag_begin () |
| Template to check if line contains opening of tag block. | |
| const std::string & | schema_validation::get_tag_end () |
| Template to check end of tag block. | |
| const std::string & | schema_validation::get_allow_link () |
| Template to check allow{link} block. | |
| const std::string & | schema_validation::get_allow_global () |
| Template to check allow{global} block. | |
| static const std::string & | schema_validation::get_allow_type () |
| static const std::string & | schema_validation::get_remove_type () |
| static const std::string & | schema_validation::get_remove_key () |
| const std::string & | schema_validation::get_table_key_begin () |
| Template to check begining of table{config} storing key values. | |
| const std::string & | schema_validation::get_table_end () |
| Template to check if table is closed. | |
| const std::string & | schema_validation::get_key_value () |
| Template to get key value. | |
| void | schema_validation::test_regex (std::ostream &f) |
| Writes to the file regex templates list. | |
Variables | |
| const std::string | schema_validation::valid = "^\\s*\\*\\s*" |
| Little parts of regex templates used to parse Wml annoations. | |
| const std::string | schema_validation::wiki_begin = "^\\s*/\\*(?:WIKI|SCHEMA)" |
| begining of wiki block | |
| const std::string | schema_validation::space = "\\s*" |
| whitespace is possible | |
| const std::string | schema_validation::equals = "=" |
| sigh "=" | |
| const std::string | schema_validation::quote_symbol = "\"?" |
| non-mandatory sign " | |
| const std::string | schema_validation::block_begin = "@begin" |
| begining of the block. | |
| const std::string | schema_validation::block_end = "@end" |
| end of block | |
| const std::string | schema_validation::allow = "@allow" |
| allow directive | |
| const std::string | schema_validation::remove = "@remove" |
| remove directive | |
| const std::string | schema_validation::property_open = "\\{" |
| sign "{" - curly bracket | |
| const std::string | schema_validation::property_close = "\\}" |
| sign "}" - another curly bracket | |
| const std::string | schema_validation::name_type = "[a-z][a-zA-Z0-9_-]*" |
| type of possible name identificator | |
| const std::string | schema_validation::parent_type = "/|(?:[a-z][a-zA-Z0-9_-]*/)+" |
| type of possible parent indentificator | |
| const std::string | schema_validation::link_type = "(?:[a-z][a-zA-Z0-9_-]*/)*(?:[a-z][a-zA-Z0-9_-]*)" |
| type of possible link indentificator | |
| const std::string | schema_validation::number = "\\d*" |
| template to number regex | |
| const std::string | schema_validation::sign = "-?" |
| sign "-" - hyphen-minus used to set sign of signed integer | |
| const std::string | schema_validation::eol = ".*$" |
| end of line + possible various character before. | |
This file contains implementation of sourceparser.cpp.
Definition in file sourceparser.cpp.
| Generated by doxygen 1.7.1 on Fri May 25 2012 01:10:54 for The Battle for Wesnoth | Gna! | Forum | Wiki | CIA | devdocs |