9 |
from xml.sax.xmlreader import AttributesImpl |
from xml.sax.xmlreader import AttributesImpl |
10 |
from StringIO import StringIO |
from StringIO import StringIO |
11 |
import xml.sax._exceptions |
import xml.sax._exceptions |
12 |
|
import xml.sax.handler |
13 |
import sys |
import sys |
14 |
|
|
15 |
class OPML(dict): |
class OPML(dict): |
91 |
def roots(self): |
def roots(self): |
92 |
return self._roots |
return self._roots |
93 |
|
|
94 |
class OPMLHandler(saxutils.DefaultHandler): |
class OPMLHandler(xml.sax.handler.ContentHandler): |
95 |
def __init__(self): |
def __init__(self): |
96 |
self._outlines = OutlineList() |
self._outlines = OutlineList() |
97 |
self._opml = None |
self._opml = None |