protected void loop() {
        boolean looping=true;
        while(looping) {
            try {
                int c=Util.keyPress(String.format(format, num, oob, dont_bundle));
                switch(c) {
                    case '1':
                        invokeRpcs();
                        break;
                    case '2':
                        num=Util.readIntFromStdin("num: ");
                        break;
                    case 'o':
                        oob=!oob;
                        break;
                    case 'b':
                        dont_bundle=!dont_bundle;
                        break;
                    case 'x':
                        looping=false;
                        break;
                }
            }
            catch(Exception e) {
                e.printStackTrace();
            }
        }
    }