(self, line)
Interpret the argument as though it had been typed in response
        to the prompt.

        This may be overridden, but should not normally need to be;
        see the precmd() and postcmd() methods for useful execution hooks.
        The return value is a flag indicating whether interpretation of
        commands by the interpreter should stop.
Interpret the argument as though it had been typed in response
        to the prompt.
Interpret the argument as though it had been typed in response to the prompt .
def onecmd(self, line):
        """Interpret the argument as though it had been typed in response
        to the prompt.

        This may be overridden, but should not normally need to be;
        see the precmd() and postcmd() methods for useful execution hooks.
        The return value is a flag indicating whether interpretation of
        commands by the interpreter should stop.

        """
        cmd, arg, line = self.parseline(line)
        if not line:
            return self.emptyline()
        if cmd is None:
            return self.default(line)
        self.lastcmd = line
        if line == 'EOF' :
            self.lastcmd = ''
        if cmd == '':
            return self.default(line)
        else:
            try:
                func = getattr(self, 'do_' + cmd)
            except AttributeError:
                return self.default(line)
            return func(arg)
def onecmd ( self , line ) : cmd , arg , line = self . parseline ( line ) if not line : return self . emptyline ( ) if cmd is None : return self . default ( line ) self . lastcmd = line if line == 'EOF' : self . lastcmd = '' if cmd == '' : return self . default ( line ) else : try : func = getattr ( self , 'do_' + cmd ) except AttributeError : return self . default ( line ) return func ( arg )