public void populate(FormItemRepresentation rep) throws FormBuilderException {
if (!(rep instanceof AbsolutePanelRepresentation)) {
throw new FormBuilderException(i18n.RepNotOfType(rep.getClass().getName(), "AbsolutePanelRepresentation"));
}
super.populate(rep);
AbsolutePanelRepresentation arep = (AbsolutePanelRepresentation) rep;
panel.clear();
getItems().clear();
if (arep.getItems() != null) {
for (Map.Entry<AbsolutePanelRepresentation.Position, FormItemRepresentation> entry : arep.getItems().entrySet()) {
FBFormItem item = super.createItem(entry.getValue());
item.setDesiredPosition(entry.getKey().getX(), entry.getKey().getY());
this.add(item);
}
}