Main Page | Class Hierarchy | Class List | File List | Class Members | File Members

ht_lang_syntax_lexer Class Reference

#include <syntax.h>

Inheritance diagram for ht_lang_syntax_lexer:

ht_syntax_lexer Object ht_c_syntax_lexer ht_html_syntax_lexer List of all members.

Public Member Functions

void init (syntax_lexer_rule *lexer_rules)
virtual void done ()
virtual lexer_token gettoken (void *buf, UINT buflen, text_pos p, bool start_of_line, lexer_state *ret_state, UINT *ret_len)

Protected Member Functions

void free_lexer_rules ()
void set_lexer_rules (syntax_lexer_rule *lr)

Protected Attributes

syntax_lexer_rulelexer_rules
void ** lexer_rules_precompiled
int lexer_rules_count

Member Function Documentation

void ht_lang_syntax_lexer::done  )  [virtual]
 

Reimplemented from Object.

Reimplemented in ht_c_syntax_lexer, and ht_html_syntax_lexer.

Definition at line 88 of file syntax.cc.

References Object::done(), and free_lexer_rules().

Referenced by ht_html_syntax_lexer::done(), and ht_c_syntax_lexer::done().

void ht_lang_syntax_lexer::free_lexer_rules  )  [protected]
 

Definition at line 94 of file syntax.cc.

References lexer_rules, lexer_rules_count, lexer_rules_precompiled, LRST_REGEX, regex_t, regfree(), and syntax_lexer_rule::string_type.

Referenced by done().

lexer_token ht_lang_syntax_lexer::gettoken void *  buf,
UINT  buflen,
text_pos  p,
bool  start_of_line,
lexer_state ret_state,
UINT ret_len
[virtual]
 

Implements ht_syntax_lexer.

Reimplemented in ht_c_syntax_lexer, and ht_html_syntax_lexer.

Definition at line 107 of file syntax.cc.

References buf, ht_syntax_lexer::geterrortoken(), lexer_rules, lexer_rules_precompiled, lexer_state, lexer_token, LRST_ANYCHAR, LRST_CHARSET, LRST_DQSTRING, LRST_EMPTY, LRST_IDENTIFIER, LRST_QSTRING, LRST_REGEX, LRST_STRING, LRST_STRING_EXPECT, LRST_WHITESPACE, LSTSET, syntax_lexer_rule::need_line_start, syntax_lexer_rule::needstate, regex_t, regmatch(), syntax_lexer_rule::state, syntax_lexer_rule::string, syntax_lexer_rule::string_type, syntax_lexer_rule::token, and UINT.

Referenced by ht_html_syntax_lexer::gettoken(), and ht_c_syntax_lexer::gettoken().

void ht_lang_syntax_lexer::init syntax_lexer_rule lexer_rules  ) 
 

Definition at line 82 of file syntax.cc.

References Object::init(), and set_lexer_rules().

void ht_lang_syntax_lexer::set_lexer_rules syntax_lexer_rule lr  )  [protected]
 

Definition at line 210 of file syntax.cc.

References lexer_rules, lexer_rules_count, lexer_rules_precompiled, LRST_REGEX, malloc(), NULL, REG_EXTENDED, regcomp(), regex_t, and syntax_lexer_rule::string_type.

Referenced by init().


Member Data Documentation

syntax_lexer_rule* ht_lang_syntax_lexer::lexer_rules [protected]
 

Definition at line 84 of file syntax.h.

Referenced by free_lexer_rules(), gettoken(), and set_lexer_rules().

int ht_lang_syntax_lexer::lexer_rules_count [protected]
 

Definition at line 86 of file syntax.h.

Referenced by free_lexer_rules(), and set_lexer_rules().

void** ht_lang_syntax_lexer::lexer_rules_precompiled [protected]
 

Definition at line 85 of file syntax.h.

Referenced by free_lexer_rules(), gettoken(), and set_lexer_rules().


The documentation for this class was generated from the following files:
Generated on Fri May 7 21:15:59 2004 by doxygen 1.3.5