# Could make this the base class; will need to add 'publish'
class WriteXmlMixin:
- def write_xml(self, outfile, encoding = "utf-8"):
+ def write_xml(self, outfile, encoding = "iso-8859-1"):
from xml.sax import saxutils
handler = saxutils.XMLGenerator(outfile, encoding)
handler.startDocument()
self.publish(handler)
handler.endDocument()
- def to_xml(self, encoding = "utf-8"):
+ def to_xml(self, encoding = "iso-8859-1"):
try:
import cStringIO as StringIO
except ImportError: