@Override protected void processOptions(LinkedList<String> args) throws IOException { CommandFormat cf = new CommandFormat(2, Integer.MAX_VALUE, "w"); cf.parse(args); waitOpt = cf.getOpt("w"); try { newLength = Long.parseLong(args.removeFirst()); } catch(NumberFormatException nfe) { displayWarning("Illegal length, a non-negative integer expected"); throw nfe; } if(newLength < 0) { throw new IllegalArgumentException("length must be >= 0"); } }
@Override protected void processOptions(LinkedList<String> args) throws IOException { CommandFormat cf = new CommandFormat(2, Integer.MAX_VALUE, "w"); cf.parse(args); waitOpt = cf.getOpt("w"); try { newLength = Long.parseLong(args.removeFirst()); } catch(NumberFormatException nfe) { displayWarning("Illegal length, a non-negative integer expected"); throw nfe; } if(newLength < 0) { throw new IllegalArgumentException("length must be >= 0"); } }
@Override protected void processOptions(LinkedList<String> args) throws IOException { CommandFormat cf = new CommandFormat(2, Integer.MAX_VALUE, "w"); cf.parse(args); waitOpt = cf.getOpt("w"); try { newLength = Long.parseLong(args.removeFirst()); } catch(NumberFormatException nfe) { displayWarning("Illegal length, a non-negative integer expected"); throw nfe; } if(newLength < 0) { throw new IllegalArgumentException("length must be >= 0"); } }
@Override protected void processOptions(LinkedList<String> args) throws IOException { CommandFormat cf = new CommandFormat(2, Integer.MAX_VALUE, "w"); cf.parse(args); waitOpt = cf.getOpt("w"); try { newLength = Long.parseLong(args.removeFirst()); } catch(NumberFormatException nfe) { displayWarning("Illegal length, a non-negative integer expected"); throw nfe; } if(newLength < 0) { throw new IllegalArgumentException("length must be >= 0"); } }
@Override protected void processOptions(LinkedList<String> args) throws IOException { CommandFormat cf = new CommandFormat(2, Integer.MAX_VALUE, "w"); cf.parse(args); waitOpt = cf.getOpt("w"); try { newLength = Long.parseLong(args.removeFirst()); } catch(NumberFormatException nfe) { displayWarning("Illegal length, a non-negative integer expected"); throw nfe; } if(newLength < 0) { throw new IllegalArgumentException("length must be >= 0"); } }