def main(self, args):
if args.action:<EOL><INDENT>self.runcmd(args.action, args.arguments)<EOL><DEDENT>else:<EOL><INDENT>self.cmdloop()<EOL><DEDENT>
Run a single command, or else the main shell loop.

        `args` should be the :class:`argparse.Namespace` object after
        being set up via :meth:`add_arguments`.