Пример #1
0
    def __init__(self, request, **kw):
        FormatterBase.__init__(self, request, **kw)

        self.document = minidom.Document()
        self.document.documentElement = self.document.createElement('xml')
        self.position = self.document.documentElement
        self.tag_stack = [('xml', {})]
Пример #2
0
    def __init__(self, request, **kw):
        '''We should use this for creating the doc'''
        FormatterBase.__init__(self, request, **kw)

        self.doc = dom.createDocument(None, "article", dom.createDocumentType(
            "article", "-//OASIS//DTD DocBook V4.4//EN",
            "http://www.docbook.org/xml/4.4/docbookx.dtd"))
        self.root = self.doc.documentElement
        self.curdepth = 0
        self.outputFormatter = DocBookOutputFormatter(self.doc)
        self.exchangeKeys = []
        self.exchangeValues = []