Lines Matching refs:parser
34 # weak references to avoid cycles between the parser and content
51 This uses a weak reference to the parser object to avoid creating
52 a circular reference between the parser and the content handler.
54 def __init__(self, parser):
55 self._ref = _mkproxy(parser)
58 parser = self._ref
59 if parser._parser is None:
61 return parser._parser.ErrorColumnNumber
64 parser = self._ref
65 if parser._parser is None:
67 return parser._parser.ErrorLineNumber
70 parser = self._ref
71 if parser is None:
73 return parser._source.getPublicId()
76 parser = self._ref
77 if parser is None:
79 return parser._source.getSystemId()
233 parser = self._parser
235 parser.CommentHandler = None
236 parser.StartCdataSectionHandler = None
237 parser.EndCdataSectionHandler = None
238 parser.StartDoctypeDeclHandler = None
239 parser.EndDoctypeDeclHandler = None
241 parser.CommentHandler = lex.comment
242 parser.StartCdataSectionHandler = lex.startCDATA
243 parser.EndCdataSectionHandler = lex.endCDATA
244 parser.StartDoctypeDeclHandler = self.start_doctype_decl
245 parser.EndDoctypeDeclHandler = lex.endDTD