if (formComponents != null && formComponents.length > 0)
{
Map args = new HashMap(formComponents.length * 3);
for (int i = 0; i < formComponents.length; i++)
{
final FormComponent formComponent = formComponents[i];
String arg = "label" + i;
IModel label = formComponent.getLabel();
if (label != null)
{
args.put(arg, label.getObject());
}
else
{
args.put(arg, formComponent.getLocalizer().getString(formComponent.getId(),
formComponent.getParent(), formComponent.getId()));
}
args.put("input" + i, formComponent.getInput());
args.put("name" + i, formComponent.getId());
}
return args;
}
else
{