コード例 #1
0
  public void mainLoop() {
    System.out.println("===================");
    System.out.println("  EXPENSE MANAGER  ");
    System.out.println("===================\n");

    System.out.println("2. Show last expense");
    System.out.println("3. Show expenses of the week");
    System.out.println("0. Exit\n\n");

    int option = Console.readInteger("Please choose a option");
    switch (option) {
      case 0:
        System.out.println("bye bye ...");
        return;
      case 1:
        ExpenseRegisterUI ui = new ExpenseRegisterUI();
        ui.mainLoop();
        break;
      case 2:
        ExpensesUI eui = new ExpensesUI();
        break;
      case 3:
        ExpensesUI temp = new ExpensesUI();
        break;
    }
  }
コード例 #2
0
 private String readDescription() {
   return Console.readLine("Description:");
 }
コード例 #3
0
 private String readName() {
   return Console.readLine("Name:");
 }