class documentation

class SAXTreeBuilder(TreeBuilder): (source)

View In Hierarchy

A Beautiful Soup treebuilder that listens for SAX events. This is not currently used for anything, but it demonstrates how a simple TreeBuilder would work.

Method characters Undocumented
Method close Undocumented
Method endDocument Undocumented
Method endElement Undocumented
Method endElementNS Undocumented
Method endPrefixMapping Undocumented
Method feed Run some incoming markup through some parsing process, populating the `BeautifulSoup` object in self.soup.
Method startDocument Undocumented
Method startElement Undocumented
Method startElementNS Undocumented
Method startPrefixMapping Undocumented

Inherited from TreeBuilder:

Method __init__ Constructor.
Method can_be_empty_element Might a tag with this name be an empty-element tag?
Method initialize_soup The BeautifulSoup object has been initialized and is now being associated with the TreeBuilder.
Method prepare_markup Run any preliminary steps necessary to make incoming markup acceptable to the parser.
Method reset Do any work necessary to reset the underlying parser for a new document.
Method set_up_substitutions Set up any substitutions that will need to be performed on a `Tag` when it's output as a string.
Method test_fragment_to_document Wrap an HTML fragment to make it look like a document.
Constant ALTERNATE_NAMES Undocumented
Constant DEFAULT_CDATA_LIST_ATTRIBUTES Undocumented
Constant DEFAULT_PRESERVE_WHITESPACE_TAGS Undocumented
Constant DEFAULT_STRING_CONTAINERS Undocumented
Constant NAME Undocumented
Constant TRACKS_LINE_NUMBERS Undocumented
Constant USE_DEFAULT Undocumented
Class Variable empty_element_tags Undocumented
Class Variable features Undocumented
Class Variable is_xml Undocumented
Class Variable picklable Undocumented
Instance Variable cdata_list_attributes Undocumented
Instance Variable preserve_whitespace_tags Undocumented
Instance Variable soup Undocumented
Instance Variable store_line_numbers Undocumented
Instance Variable string_containers Undocumented
Method _replace_cdata_list_attribute_values When an attribute value is associated with a tag that can have multiple values for that attribute, convert the string value to a list of strings.
def characters(self, content): (source)

Undocumented

def close(self): (source)

Undocumented

def endDocument(self): (source)

Undocumented

def endElement(self, name): (source)

Undocumented

def endElementNS(self, nsTuple, nodeName): (source)

Undocumented

def endPrefixMapping(self, prefix): (source)

Undocumented

def feed(self, markup): (source)

Run some incoming markup through some parsing process, populating the `BeautifulSoup` object in self.soup. This method is not implemented in TreeBuilder; it must be implemented in subclasses. :return: None.

def startDocument(self): (source)

Undocumented

def startElement(self, name, attrs): (source)

Undocumented

def startElementNS(self, nsTuple, nodeName, attrs): (source)

Undocumented

def startPrefixMapping(self, prefix, nodeValue): (source)

Undocumented