| Home | Trees | Index | Help |
|---|
| Package ZestyParser :: Module Parser :: Class ZestyParser |
|
DebuggingParsertokens.
| Method Summary | |
|---|---|
Initializes the parser, optionally calling useData | |
| tuple |
Returns row/column coordinates for a given point in the input stream, or cursor by default. |
| iterator |
Returns a generator iterator which scans for token every time it is invoked. |
| object |
Scan for one token. |
| bool |
A convenience method that skips one token and returns whether it matched. |
Begin parsing a stream of data | |
| Instance Variable Summary | |
|---|---|
| dict | context: A dictionary which can be used for storing any necessary state
information. |
| int | cursor: The current position of the parser in data. |
| sequence | data: The sequence being parsed (probably a string). |
token |
last: The last matched token. |
| Class Variable Summary | |
|---|---|
int |
len = 0 |
| Method Details |
|---|
__init__(self,
data=None)
Initializes the parser, optionally calling |
coord(self, loc=None)Returns row/column coordinates for a given point in the input stream, orcursor by default. Counting starts at
(1, 1).
|
iter(self, token, skip=None, until=None)Returns a generator iterator which scans fortoken every time it is invoked.
|
scan(self, token)Scan for one token.
|
skip(self, token)A convenience method that skips one token and returns whether it matched.
|
useData(self, data)Begin parsing a stream of data
|
| Instance Variable Details |
|---|
contextA dictionary which can be used for storing any necessary state information.
|
cursorThe current position of the parser indata.
|
dataThe sequence being parsed (probably a string).
|
lastThe last matched token.
|
| Class Variable Details |
|---|
len
|
| Home | Trees | Index | Help |
|---|
| Generated by Epydoc 2.1 on Thu Mar 22 02:13:39 2007 | http://epydoc.sf.net |