/** * Returns the URL to the resource of this bean (mapped and with the appropriate extension). * * @see LinkUtil#getUrl(SlingHttpServletRequest, String) */ public String getUrl() { if (url == null) { RequestHandle request = getRequest(); url = LinkUtil.getUrl(request, getPath(), request.getSelectors(), null); } return url; }
public String getThumbnailUrl() { if (thumbnailUrl == null) { StringBuilder builder = new StringBuilder(); try { String path = PackageUtil.getThumbnailPath(pckgDef); if (StringUtils.isNotBlank(path)) { builder.append(LinkUtil.getUrl(request, path)); } } catch (RepositoryException rex) { LOG.error(rex.getMessage(), rex); } thumbnailUrl = builder.toString(); } return thumbnailUrl; }
public String getAuditLogUrl() { if (auditLogUrl == null) { auditLogUrl = LinkUtil.getUrl(getRequest(), AUDIT_LOG_BASE + getPath()); } return auditLogUrl; }
public String getDownloadUrl() { if (downloadUrl == null) { downloadUrl = LinkUtil.getUrl(getRequest(), PackageUtil.getDownloadUrl(pckg)); } return downloadUrl; }
@Override public String getUrl() { return LinkUtil.getUrl(getRequest(), PackagesServlet.SERVLET_PATH + getPath()); }