Rule 689: Watch out for those break statements Eugene.
Ladies and gentlemen the break statement (known as Billy) marked in bold below was not in this afternoon. We have reason to believe that he was hiding in the stationary cuboard. His absence has caused all manner of problems; obviously the fact that the code fell thru his case to the TEXT_TYPE below but perhaps more importantly led directly to Monkey Programmer Boy climbing on the roof and singing songs from Andrew Lloyd Webber musicals.
In his defence he argues that he was never there in the first place and he is just a victim of rank bad programming by someone who should have never been taken off dBase III.
No one believes him tho.
break ;
switch(currentQuestion.getType()) {
case SurveyQuestion.NUMBER_TYPE :
pdaNumberUI = new PDANumberUI(this, currentSurvey) ;
pdaNumberUI.show(currentQuestion) ;
case SurveyQuestion.TEXT_TYPE :
pdaTextUI = new PDATextUI(this , currentSurvey) ;
pdaTextUI.show(currentQuestion) ;
break ;
case SurveyQuestion.RADIO_TYPE :
pdaRadioUI = new PDARadioUI(this , currentSurvey) ;
pdaRadioUI.show(currentQuestion) ;
break ;
case SurveyQuestion.COMBO_TYPE :
pdaTextUI = new PDATextUI(this, currentSurvey) ;
pdaTextUI.show(currentQuestion) ;
break ;
case SurveyQuestion.CHECKBOX_TYPE:
pdaCheckBoxUI = new PDACheckBoxUI(this, currentSurvey) ;
pdaCheckBoxUI.show(currentQuestion) ;
break ;
case SurveyQuestion.LISTBOX_TYPE :
pdaRadioUI = new PDARadioUI(this, currentSurvey) ;
pdaRadioUI.show(currentQuestion) ;
break ;
case SurveyQuestion.MESSAGE_TYPE :
pdaMessageUI = new PDAMessageUI(this, currentSurvey) ;
pdaMessageUI.show(currentQuestion) ;
break ;
}