|
Grammatica 1.5 Documentation | |||||||
| FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||
System.Object
|
+--NFAStateQueue
in TokenNFA.csAn NFA state queue. This queue is used during processing to keep track of the current and subsequent NFA states. The current state is read from the beginning of the queue, and new states are added at the end. A marker index is used to separate the current from the subsequent states.
The queue implementation is optimized for quick removal at the beginning and addition at the end. It will attempt to use a fixed-size array to store the whole queue, and moves the data in this array only when absolutely needed. The array is also enlarged automatically if too many states are being processed at a single time.
| Field Summary | |
bool |
Empty
The empty queue property (read-only). |
bool |
Marked
The marked first entry property (read-only). |
| Method Summary | |
void |
AddLast( NFAState state )
Adds a new entry at the end of the queue. |
void |
Clear()
Clears this queue. |
void |
MarkEnd()
Marks the end of the queue. |
NFAState |
RemoveFirst()
Removes and returns the first entry in the queue. |
| Field Detail |
public bool Empty;
public bool Marked;
| Method Detail |
public void AddLast( NFAState state );
state - the state to addpublic void Clear();
public void MarkEnd();
public NFAState RemoveFirst();
|
Grammatica 1.5 Documentation | |||||||
| FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||