'Execute the parse expression with the given string.
This is the main interface to the client code, once the complete
expression has been built.
If you want the grammar to require that the entire input string be
successfully parsed, then set parseAll to True (equivalent to ending
the grammar with StringEnd()).
Note: parseString implicitly calls expandtabs() on the input string,
in order to report proper column numbers in parse actions.
If the input string contains tabs and
the grammar uses parse actions that use the loc argument to index into the
string being parsed, you can ensure you have a consistent view of the input
string by:
- calling parseWithTabs on your grammar before calling parseString
(see L{I{parseWithTabs}<parseWithTabs>})
- define your parse action using the full (s,loc,toks) signature, and
reference the input string using the parse action\'s s argument
- explictly expand the tabs in your input string before calling
parseString'

def parseString(self, instring, parseAll=False):

    ParserElement.resetCache()
    if (not self.streamlined):
        self.streamline()
    for e in self.ignoreExprs:
        e.streamline()
    if (not self.keepTabs):
        instring = instring.expandtabs()
    try:
        (loc, tokens) = self._parse(instring, 0)
        if parseAll:
            se = StringEnd()
            se._parse(instring, loc)
    except ParseBaseException:
        if ParserElement.verbose_stacktrace:
            raise
        else:
            exc = sys.exc_info()[1]
        raise exc
    else:
        return tokens
