public void goToWizardStep(WizardStep step) { currentStep = step; view.showPrevButton(step.hasPrev()); view.showNextButton(step.hasNext()); switch (step) { case START: view.showStartStep(budget); break; case INCOMES: view.showIncomesStep(budget); break; case EXPENSES: view.showExpensesStep(budget); break; case FINISH: view.showFinishStep(budget); break; default: break; } }
public void goPrevStep() { if (currentStep.hasPrev()) { goToWizardStep(currentStep.getPrev()); } }