Opened 16 years ago

Closed 16 years ago

#163 closed enhancement (fixed)

rationalize the command-line interface and class MiniMP

Reported by: Stephen Siegel Owned by: ywei
Priority: major Milestone: Release 1.0
Component: User Interface Version: 1.0
Keywords: options command line Cc:

Description

The command line interface should be changed to be more consistent.

All options should have the form -name=value. The one exception will be one of the form -name which is syntactic sugar for -name=true. Option values can be either boolean (true or false), integer, double, or String.

To deal with the case of compare, in which two values of np need to be given, we could call the one for the spec np1 and one for the impl np2.

The order in which options appear should make no difference.

The MiniMP class code can also be cleaned up and streamlined considerably. Instead of throwing a RuntimeException when a command line syntax error is encountered, a method should be called that explains the error and prints the usage message before exiting gracefully.

Change History (5)

comment:1 by ywei, 16 years ago

Owner: set to ywei
Status: newaccepted

comment:2 by ywei, 16 years ago

Since I have finished fixing the bug on fib example. I will start working on this ticket from now on.

comment:3 by ywei, 16 years ago

There is a -verbose and a -debug options. I think -debug option is used internally for development purpose. But I didn't find a corresponding option in RunConfiguration class. Do we still need the -debug option in command line?

comment:4 by Stephen Siegel, 16 years ago

In the RunConfiguration there is a PrintWriter field called debugOut. The idea is that if you want debugging information, you should set this to any non-null PrintWriter. So if the command line option debug is false, this field should just be null (that is what it is by default), and if debug is true, it should probably be set to out, at least, that is what I have found the most useful. debug usually provides even more information than verbose.

comment:5 by ywei, 16 years ago

Resolution: fixed
Status: acceptedclosed

Done.

Note: See TracTickets for help on using tickets.