A simple lexer matches texts with simple regular expressions.
More...
#include <grammartextlexer.h>
A simple lexer matches texts with simple regular expressions.
◆ GrammarTextLexer()
Constructs the grammar textlexer.
- Parameters
-
scopes | a reference to the scopes model |
◆ ~GrammarTextLexer()
edbee::GrammarTextLexer::~GrammarTextLexer |
( |
| ) |
|
|
virtual |
◆ lexLines()
void edbee::GrammarTextLexer::lexLines |
( |
int | lineStart, |
|
|
int | lineCount ) |
|
virtual |
This method lexes a range of line.
- Returns
- the last indexed offset
◆ lexRange()
void edbee::GrammarTextLexer::lexRange |
( |
int | beginOffset, |
|
|
int | endOffset ) |
|
virtual |
This method is called when the given range needs to be lexed.
WARNING, this method must be VERY optimized and should 'remember' the lexing states between calls. To invalidate the scopes/lexing state the textReplaced method can be used
- Parameters
-
beginOffset | the first offset |
endOffset | the last offset to |
Implements edbee::TextLexer.
◆ textChanged()
This method is called to notify the lexer some data has been changed.
- Todo
- : rebuild an optimized scope-rebuilding algorithm
Implements edbee::TextLexer.
The documentation for this class was generated from the following files: