OptSwitch cs = opts.getSwitch((Character) names.nextElement()); System.out.println("args[" + i + "] : " + (char) cs.sw + " " + cs.type + " " +
OptSwitch cs = opts.getSwitch((Character) names.nextElement()); System.out.println("args[" + i + "] : " + (char) cs.sw + " " + cs.type + " " +
while(optenum.hasMoreElements()) { Character c = (Character)optenum.nextElement(); OptSwitch sw = getSwitch(c); if(sw.set) { if(sw.acceptVal()) {
while(optenum.hasMoreElements()) { Character c = (Character)optenum.nextElement(); OptSwitch sw = getSwitch(c); if(sw.set) { if(sw.acceptVal()) {
try { opts = new Getopts("v", args); if (opts.getSwitch(new Character('v')).set) { validation = true;
try { opts = new Getopts("v", args); if (opts.getSwitch(new Character('v')).set) { validation = true;
if (opts.getSwitch(new Character('d')).set) get_dds = true; if (opts.getSwitch(new Character('x')).set) get_ddx = true; if (opts.getSwitch(new Character('a')).set) get_das = true; if (opts.getSwitch(new Character('D')).set) get_data = true; if (opts.getSwitch(new Character('X')).set) get_dataX = true; if (opts.getSwitch(new Character('p')).set) dump_data = get_data = true; if (opts.getSwitch(new Character('V')).set) { System.err.println("geturl version: " + VERSION); System.exit(0); if (opts.getSwitch(new Character('v')).set) verbose = true; if (opts.getSwitch(new Character('g')).set) gui = true; optVal = opts.getSwitch(new Character('c')).val; if (optVal != null) { cexpr = true; optVal = opts.getSwitch(new Character('m')).val; if (optVal != null) { multi = true;
public static void main(String args[]) throws Exception { Getopts opts = null; try { opts = new Getopts("d", args); if (opts.getSwitch('d').set) { debug = true; } } catch (InvalidSwitch is) { throw new Exception(is); } String testdir = null; if (opts.argList().length > 0) testdir = opts.argList()[0]; else testdir = "."; new TestDConnect2().testDConnect2(); }