Lines Matching defs:size
34 int size = parseSize(args[1]);
35 int incr = (args.length > 2 ? parseSize(args[2]) : size);
45 while (size >= incr) {
47 size -= incr;
71 private static int parseSize(String size) throws Exception {
73 if (size.equals("DEFAULT"))
75 if (size.equals("DEFAULT+1"))
77 if (size.equals("DEFAULT+1M"))
79 if (size.equals("DEFAULT-1"))
81 if (size.equals("DEFAULT/2"))
84 int idx = 0, len = size.length();
88 if (Character.isDigit(size.charAt(i))) idx++;
93 throw new RuntimeException("No digits detected: " + size);
95 result = Integer.parseInt(size.substring(0, idx));
99 switch(size.charAt(i)) {
106 throw new RuntimeException("Unrecognized size: " + size);