examples/src/main/java/io/github/agentsoz/jill/example/greeter/Greeter.java
public static void parse(String[] args) {
    for (int i = 0; i < args.length; i++) {
      switch (args[i]) {
        case "-seed":
          if (i + 1 < args.length) {
            i++;
            int seed = 0;
            try {
              seed = Integer.parseInt(args[i]);
              rand = new Random(seed);
            } catch (NumberFormatException e) {
              Log.warn("Seed value '" + args[i] + "' is not a number");
            }
          }
          break;
        case "-neighbourhoodSize":
          if (i + 1 < args.length) {
            i++;
            try {
              numNeighbours = Integer.parseInt(args[i]);
            } catch (NumberFormatException e) {
              Log.warn("Neighbourhood size value '" + args[i] + "' is not a number");
            }
          }
          break;
        default:
          // Ignore any other arguments
          break;
      }
    }
  }
public static void parse(String[] args) {
    for (int i = 0; i < args.length; i++) {
      switch (args[i]) {
        case "-seed":
          if (i + 1 < args.length) {
            i++;
            int seed = 0;
            try {
              seed = Integer.parseInt(args[i]);
              rand = new Random(seed);
            } catch (NumberFormatException e) {
              Log.warn("Seed value '" + args[i] + "' is not a number");
            }
          }
          break;
        case "-neighbourhoodSize":
          if (i + 1 < args.length) {
            i++;
            try {
              numNeighbours = Integer.parseInt(args[i]);
            } catch (NumberFormatException e) {
              Log.warn("Neighbourhood size value '" + args[i] + "' is not a number");
            }
          }
          break;
        default:
          // Ignore any other arguments
          break;
      }
    }
  }
public static void parse ( String [ ] args ) { for ( int i = 0 ; i < args . length ; i ++ ) { switch ( args [ i ] ) { case "-seed" : if ( i + 1 < args . length ) { i ++ ; int seed = 0 ; try { seed = Integer . parseInt ( args [ i ] ) ; rand = new Random ( seed ) ; } catch ( NumberFormatException e ) { Log . warn ( "Seed value '" + args [ i ] + "' is not a number" ) ; } } break ; case "-neighbourhoodSize" : if ( i + 1 < args . length ) { i ++ ; try { numNeighbours = Integer . parseInt ( args [ i ] ) ; } catch ( NumberFormatException e ) { Log . warn ( "Neighbourhood size value '" + args [ i ] + "' is not a number" ) ; } } break ; default : // Ignore any other arguments break ; } } }
Parses the command line arguments.

@param args arguments passed to this program
Parses the command line arguments .