Back to index

moin  1.9.0~rc2
Public Member Functions | Public Attributes | Static Public Attributes | Private Member Functions
MoinMoin.wikixml.util.XMLGenerator Class Reference
Inheritance diagram for MoinMoin.wikixml.util.XMLGenerator:
Inheritance graph
[legend]

List of all members.

Public Member Functions

def __init__
def startNode
def endNode
def simpleNode
def startDocument
def endDocument

Public Attributes

 xmlns

Static Public Attributes

dictionary default_xmlns = {}

Private Member Functions

def _build_tag

Detailed Description

Definition at line 13 of file util.py.


Constructor & Destructor Documentation

Reimplemented in MoinMoin.wikixml.util.RssGenerator.

Definition at line 16 of file util.py.

00016 
00017     def __init__(self, out):
00018         saxutils.XMLGenerator.__init__(self, out=out, encoding=config.charset)
00019         self.xmlns = self.default_xmlns


Member Function Documentation

def MoinMoin.wikixml.util.XMLGenerator._build_tag (   self,
  tag 
) [private]

Definition at line 20 of file util.py.

00020 
00021     def _build_tag(self, tag):
00022         if type(tag) == type(""):
00023             qname = tag
00024             tag = (None, tag)
00025         else:
00026             qname = "%s:%s" % tag
00027             tag = (self.xmlns[tag[0]], tag[1])
00028         return tag, qname

Here is the caller graph for this function:

Reimplemented in MoinMoin.wikixml.util.RssGenerator.

Definition at line 48 of file util.py.

00048 
00049     def endDocument(self):
00050         for prefix in self.xmlns:
00051             self.endPrefixMapping(prefix or None)
00052         saxutils.XMLGenerator.endDocument(self)
00053 

def MoinMoin.wikixml.util.XMLGenerator.endNode (   self,
  tag 
)

Definition at line 33 of file util.py.

00033 
00034     def endNode(self, tag):
00035         tag, qname = self._build_tag(tag)
00036         self.endElementNS(tag, qname)

Here is the call graph for this function:

Here is the caller graph for this function:

def MoinMoin.wikixml.util.XMLGenerator.simpleNode (   self,
  tag,
  value,
  attr = {} 
)

Definition at line 37 of file util.py.

00037 
00038     def simpleNode(self, tag, value, attr={}):
00039         self.startNode(tag, attr)
00040         if value:
00041             self.characters(value)
00042         self.endNode(tag)

Here is the call graph for this function:

Reimplemented in MoinMoin.wikixml.util.RssGenerator.

Definition at line 43 of file util.py.

00043 
00044     def startDocument(self):
00045         saxutils.XMLGenerator.startDocument(self)
00046         for prefix, uri in self.xmlns.items():
00047             self.startPrefixMapping(prefix or None, uri)

def MoinMoin.wikixml.util.XMLGenerator.startNode (   self,
  tag,
  attr = {} 
)

Definition at line 29 of file util.py.

00029 
00030     def startNode(self, tag, attr={}):
00031         tag, qname = self._build_tag(tag)
00032         self.startElementNS(tag, qname, attr)

Here is the call graph for this function:

Here is the caller graph for this function:


Member Data Documentation

Reimplemented in MoinMoin.wikixml.util.RssGenerator.

Definition at line 14 of file util.py.

Definition at line 18 of file util.py.


The documentation for this class was generated from the following file: