/** * The shape as a string using the given request cycle; will be used for rendering. * * @return The shape as a string */ @Override public String toString() { // Add any popup script final String popupJavaScript; if (link.getPopupSettings() != null) { popupJavaScript = link.getPopupSettings().getPopupJavaScript(); } else { popupJavaScript = null; } return "<area shape=\"" + getType() + "\"" + " coords=\"" + getCoordinates() + "\"" + " href=\"" + link.getURL() + "\"" // Output the markup ID if that was specified, so we can link tooltips, etc. to // it. + (link.getOutputMarkupId() ? " id=\"" + link.getMarkupId() + "\"" : "") + ((popupJavaScript == null) ? "" : (" onClick = \"" + popupJavaScript + "\"")) + ">"; }
/** * The shape as a string using the given request cycle; will be used for rendering. * * @return The shape as a string */ public String toString() { // Add any popup script final String popupJavaScript; if (link.getPopupSettings() != null) { popupJavaScript = link.getPopupSettings().getPopupJavaScript(); } else { popupJavaScript = null; } return "<area shape=\"" + getType() + "\"" + " coords=\"" + getCoordinates() + "\"" + " href=\"" + link.getURL() + "\"" // Output the markup ID if that was specified, so we can link tooltips, etc. to // it. + (link.getOutputMarkupId() ? " id=\"" + link.getMarkupId() + "\"" : "") + ((popupJavaScript == null) ? "" : (" onClick = \"" + popupJavaScript + "\"")) + ">"; }