writer.write(StringUtils.toString(getLinkValue(helper.hasColumn()), ""));
writer.endElement(tag);
}
else
{ // Add component
HtmlOutcomeTargetLink linkComponent = null;
if (getChildCount() > 0)
{
UIComponent c = getChildren().get(0);
if (c instanceof HtmlOutcomeTargetLink)
linkComponent = (HtmlOutcomeTargetLink)c;
else
log.info("TODO: handle Child nodes!");
}
if (linkComponent == null)
{
linkComponent = new HtmlOutcomeTargetLink();
this.getChildren().add(linkComponent);
}
// set params
setLinkProperties(linkComponent);
addOrSetParam(linkComponent, "idparam", "id");
// encode link
linkComponent.setRendered(true);
linkComponent.encodeAll(context);
linkComponent.setRendered(false); // Don't render twice!
}
}