'Loads a document into the parser and parses it.
The argument can either be a filename or a document in memory.'

def load(self, odffile):

    self.lines = []
    self._wfunc = self._wlines
    if (isinstance(odffile, basestring) or hasattr(odffile, 'read')):
        self.document = load(odffile)
    else:
        self.document = odffile
    self._walknode(self.document.topnode)
