public void nonStaticMain(String[] args) {

        if (args.length == 0)
            args = new String[] { "help" };

        String command = args[0];
        String[] args2 = new String[args.length - 1];
        for (int i = 1; i < args.length; i++)
            args2[i - 1] = args[i];

        // Figure out which handler handles this command.
        CommandHandler handler = null;
        List<CommandHandler> allHandlers = new ArrayList<CommandHandler>();
        allHandlers.addAll(handlers);
        for (CommandHandler h : allHandlers) {
            if (h.handles(command)) {
                handler = h;
                break;
            }
        }

        // If there was no handler for the command, print error message and
        // exit.
        if (handler == null) {
            System.out.println("Unrecognized command: " + command + ".");
            System.out.println("For more help, invoke Randoop "
                    + "with \"help\" as its sole argument.");
            System.exit(1);
        }

        boolean success = false;
        try {

            success = handler.handle(args2);

            if (!success) {
                System.err
                        .println("The command you issued returned a failing status flag.");
            }

        }
        catch (RandoopTextuiException e) {

            System.out.println(e.getMessage());
            System.out
                    .println("To get help on this command, invoke Randoop with");
            System.out.println("`help " + handler.fcommand + "' as arguments.");
            System.exit(1);

        }
        catch (Throwable e) {

            System.out.println("Throwable thrown while handling command:" + e);
            e.printStackTrace();
            System.err.flush();
            success = false;

        }
        finally {

            if (!success) {
                System.out.println("Randoop failed.");
                System.out.println("Last sequence under execution:"
                        + AbstractGenerator.currSeq);
                System.exit(1);
            }
        }
    }