/**
* @see org.olat.core.gui.components.form.flexible.FormComponent#setErrorController(org.olat.core.gui.control.Controller)
*/
public void setErrorComponent(FormItem errorFormItem, FormLayouter container) {
if(errorFormItem == null){
throw new AssertException("do not clear error by setting null, instead use showError(false).");
}
//initialize root form of form item
FormLayoutContainer flc = (FormLayoutContainer)container;//TODO:pb: fix this hierarchy mismatch
flc.register(errorFormItem);//errorFormItem must be part of the composite chain, that it gets dispatched