Lines Matching full:method

50 .. method:: SGMLParser.reset()
56 .. method:: SGMLParser.setnomoretags()
62 .. method:: SGMLParser.setliteral()
67 .. method:: SGMLParser.feed(data)
74 .. method:: SGMLParser.close()
77 mark. This method may be redefined by a derived class to define additional
82 .. method:: SGMLParser.get_starttag_text()
90 .. method:: SGMLParser.handle_starttag(tag, method, attributes)
92 This method is called to handle start tags for which either a :meth:`start_tag`
93 or :meth:`do_tag` method has been defined. The *tag* argument is the name of
94 the tag converted to lower case, and the *method* argument is the bound method
106 For instance, for the tag ``<A HREF="http://www.cwi.nl/">``, this method would
108 base implementation simply calls *method* with *attributes* as the only
115 .. method:: SGMLParser.handle_endtag(tag, method)
117 This method is called to handle endtags for which an :meth:`end_tag` method has
119 case, and the *method* argument is the bound method which should be used to
120 support semantic interpretation of the end tag. If no :meth:`end_tag` method is
122 implementation simply calls *method*.
125 .. method:: SGMLParser.handle_data(data)
127 This method is called to process arbitrary data. It is intended to be
131 .. method:: SGMLParser.handle_charref(ref)
133 This method is called to process a character reference of the form ``&#ref;``.
135 a string. If that method returns a string, it is passed to :meth:`handle_data`,
142 .. method:: SGMLParser.convert_charref(ref)
147 :meth:`convert_codepoint` method. If *ref* is invalid or out of range, this
148 method returns ``None``. This method is called by the default
154 .. method:: SGMLParser.convert_codepoint(codepoint)
162 .. method:: SGMLParser.handle_entityref(ref)
164 This method is called to process a general entity reference of the form
167 the method :meth:`handle_data` with the translation; otherwise, it calls the
168 method ``unknown_entityref(ref)``. The default :attr:`entitydefs` defines
175 .. method:: SGMLParser.convert_entityref(ref)
181 translations. If no translation is available for *ref*, this method returns
182 ``None``. This method is called by the default :meth:`handle_entityref`
188 .. method:: SGMLParser.handle_comment(comment)
190 This method is called when a comment is encountered. The *comment* argument is
193 cause this method to be called with the argument ``'text'``. The default method
197 .. method:: SGMLParser.handle_decl(data)
199 Method called when an SGML declaration is read by the parser. In practice, the
207 .. method:: SGMLParser.report_unbalanced(tag)
209 This method is called when an end tag is found which does not correspond to any
213 .. method:: SGMLParser.unknown_starttag(tag, attributes)
215 This method is called to process an unknown start tag. It is intended to be
219 .. method:: SGMLParser.unknown_endtag(tag)
221 This method is called to process an unknown end tag. It is intended to be
225 .. method:: SGMLParser.unknown_charref(ref)
227 This method is called to process unresolvable numeric character references.
233 .. method:: SGMLParser.unknown_entityref(ref)
235 This method is called to process an unknown entity reference. It is intended to
241 method names must be in lower case:
244 .. method:: SGMLParser.start_tag(attributes)
247 This method is called to process an opening tag *tag*. It has preference over
252 .. method:: SGMLParser.do_tag(attributes)
255 This method is called to process an opening tag *tag* for which no
256 :meth:`start_tag` method is defined. The *attributes* argument has the same
260 .. method:: SGMLParser.end_tag()
263 This method is called to process a closing tag *tag*.
267 stack. Definition of an :meth:`end_tag` method is optional for these tags. For
269 method must be defined; if defined, it will not be used. If both
271 :meth:`start_tag` method takes precedence.