ProgramListing#

class pyconverter.xml2py.ast_tree.ProgramListing(element, parse_children=True)#

Provides the program listing element.

Methods

ProgramListing.find(_type[, terms])

Find the first type matching a given type string.

ProgramListing.find_all(_type[, recursive, ...])

Find all types matching a given type string.

ProgramListing.get(entry)

Get an item from an element.

ProgramListing.has_children()

Return wether the element has children.

ProgramListing.print_tree()

Print the tree.

ProgramListing.rec_find(_type[, terms])

Find the first type matching a given type string recursively.

ProgramListing.to_rst([prefix])

Return a string to enable converting the element to an RST format.

ProgramListing.types_repr()

Return the string types.

Attributes

ProgramListing.added

Has the revision flag added.

ProgramListing.any_isalnum

Returns True if any characters are alphanumeric.

ProgramListing.children

Children of the tree.

ProgramListing.content

Text content.

ProgramListing.id

ID of the element.

ProgramListing.next_elem

Next element.

ProgramListing.prev_elem

Previous element.

ProgramListing.raw

Raw string of the element.

ProgramListing.source

Return the source value.

ProgramListing.tag

Element tag.

ProgramListing.tail

Tail of the element as a string.

ProgramListing.text_content

Text content.

ProgramListing.title

Element title.

ProgramListing.tostring

Attributes of the element as a dictionary.