added [for]
EzcInfo pushed into Ezc:: added info about a wrong directive git-svn-id: svn://ttmath.org/publicrep/cgi/ezc/trunk@5 e52654a7-88a9-db11-a3e9-0013d4bc506e
This commit is contained in:
1 parent
700dcd0571
commit
ac632987f3
2 files changed
+148
-48
No files matched your search
@@ -7,24 +7,28 @@
|
||||
#include <vector>
|
||||
#include <map>
|
||||
|
||||
struct EzcInfo
|
||||
{
|
||||
std::string text;
|
||||
bool result;
|
||||
|
||||
EzcInfo()
|
||||
{
|
||||
result = false;
|
||||
}
|
||||
};
|
||||
|
||||
class Ezc
|
||||
{
|
||||
public:
|
||||
typedef void (*UserFunction)(EzcInfo &);
|
||||
typedef std::map<std::string, UserFunction> UserFunctions;
|
||||
struct Info
|
||||
{
|
||||
std::string text;
|
||||
bool result;
|
||||
int iter;
|
||||
};
|
||||
|
||||
UserFunctions user_functions;
|
||||
typedef void (*UserFunction)(Info &);
|
||||
|
||||
struct UserInfo
|
||||
{
|
||||
UserFunction user_function;
|
||||
int iter;
|
||||
};
|
||||
|
||||
typedef std::map<std::string, UserInfo> UserInfoTable;
|
||||
|
||||
UserInfoTable user_info_table;
|
||||
|
||||
Ezc();
|
||||
void Init();
|
||||
@@ -62,14 +66,17 @@ private:
|
||||
bool CreateTreeReadItem(const char * & itext);
|
||||
void CreateTreeReadAll(const char * & itext);
|
||||
void CreateTreeReadIfany(const char * & itext);
|
||||
void CreateTreeReadFor(const char * & itext);
|
||||
bool CreateTreeReadDeleteLastEndItem();
|
||||
void CreateTree(const char * & itext);
|
||||
|
||||
void MakeTextIfany(std::string & otext, UserFunctions & user_functions);
|
||||
void MakeTextContainer(std::string & otext, UserFunctions & user_functions);
|
||||
void MakeTextIfany(std::string & otext, UserInfoTable & user_info_table);
|
||||
void MakeTextFor(std::string & otext, UserInfoTable & user_info_table);
|
||||
void MakeTextContainer(std::string & otext, UserInfoTable & user_info_table);
|
||||
void MakeTextMsgCantFind(std::string & otext, std::string & key);
|
||||
void MakeTextNormal(std::string & otext, UserFunctions & user_functions);
|
||||
void MakeTextNormal(std::string & otext, UserInfoTable & user_info_table);
|
||||
|
||||
void MakeText(std::string & otext,UserFunctions & user_functions);
|
||||
void MakeText(std::string & otext,UserInfoTable & user_info_table);
|
||||
};
|
||||
|
||||
Item item_root;
|
||||
|
||||
Reference in new issue
Block a user