Buggy code:
public class Form extends WebMarkupContainer implements IFormSubmitListener { private abstract static class ValidationVisitor implements FormComponent . IVisitor { public void formComponent ( FormComponent formComponent ) { } public abstract void validate ( FormComponent formComponent ) { } } private static final String UPLOAD_TOO_LARGE_RESOURCE_KEY = "uploadTooLarge" ; private static final String UPLOAD_FAILED_RESOURCE_KEY = "uploadFailed" ; private static final long serialVersionUID = 1L ; private static Log log = LogFactory . getLog ( Form . class ) ; private Bytes maxSize = Bytes . MAX ; private boolean multiPart = false ; private String javascriptId ; public Form ( final String id ) { } public Form ( final String id , IModel model ) { } public Bytes getMaxSize ( ) { } public final void loadPersistentFormComponentValues ( ) { } public final void onFormSubmitted ( ) { } public void removePersistentFormComponentValues ( final boolean disablePersistence ) { } public void setMaxSize ( final Bytes maxSize ) { } public void setMultiPart ( boolean multiPart ) { } public final Component setVersioned ( final boolean isVersioned ) { } public boolean isVersioned ( ) { } public final void visitFormComponents ( final FormComponent . IVisitor visitor ) { } protected void beforeUpdateFormComponentModels ( ) { } protected void delegateSubmit ( Button submittingButton ) { } protected final Button findSubmittingButton ( ) { } protected IValuePersister getValuePersister ( ) { } protected final boolean hasError ( ) { } protected void internalOnModelChanged ( ) { } protected final void markFormComponentsInvalid ( ) { } protected final void markFormComponentsValid ( ) { } protected final String getHiddenFieldId ( ) { } protected final String getJavascriptId ( ) { } protected void onComponentTagBody ( final MarkupStream markupStream , final ComponentTag openTag ) { } protected void onComponentTag ( final ComponentTag tag ) { } protected void onError ( ) { } protected void onRender ( final MarkupStream markupStream ) { } protected void onSubmit ( ) { } public boolean process ( ) { } protected final void updateFormComponentModels ( ) { } protected void clearInput ( ) { } protected void validate ( ) { visitFormComponents ( new Form . ValidationVisitor ( ) { public void validate ( final FormComponent formComponent ) { formComponent . validateRequired ( ) ; } } ) ; visitFormComponents ( new Form . ValidationVisitor ( ) { public void validate ( final FormComponent formComponent ) { <START_BUG> formComponent . convertAndValidate ( ) ; <END_BUG> } } ) ; visitFormComponents ( new Form . ValidationVisitor ( ) { public void validate ( final FormComponent formComponent ) { formComponent . validate ( ) ; } } ) ; } private boolean anyFormComponentError ( ) { } private final boolean handleMultiPart ( ) { } private void persistFormComponentData ( ) { } private void dispatchEvent ( final Page page , final String url ) { } private void registerNewUserInput ( ) { } public final String getJsForInterfaceUrl ( String url ) { } class FormDispatchRequest extends Request { private final Request realRequest ; private final String url ; private final Map params = new HashMap ( 4 ) ; public FormDispatchRequest ( final Request realRequest , final String url ) { } public Locale getLocale ( ) { } public String getParameter ( String key ) { } public Map getParameterMap ( ) { } public String [ ] getParameters ( String key ) { } public String getPath ( ) { } public String getRelativeURL ( ) { } public String getURL ( ) { } } }

Fix:
formComponent . validateTypeConversion ( ) ;