/** * Returns the system information.<p> * * @return the system information */ public CmsSystemInfo getSystemInfo() { return OpenCms.getSystemInfo(); }
/** * Creates a new cache instance.<p> */ public CmsPdfThumbnailCache() { super(OpenCms.getSystemInfo().getWebInfRfsPath(), PDF_CACHE_FOLDER); }
/** * Returns if the given URI is pointing to the OpenCms workplace UI.<p> * * @param uri the URI * * @return <code>true</code> if the given URI is pointing to the OpenCms workplace UI */ public static boolean isWorkplaceUri(URI uri) { return (uri != null) && uri.getPath().startsWith(OpenCms.getSystemInfo().getWorkplaceContext()); }
/** * Creates a SAX event handler that generates XML / HTML Strings from the events caught * using a new <code>{@link StringWriter}</code> and the given encoding.<p> * * @param writer the Writer to write to output to */ public CmsXmlSaxWriter(Writer writer) { this(writer, OpenCms.getSystemInfo().getDefaultEncoding()); }
/** * Gets the log file for the given module name.<p> * * @param moduleName the module * * @return the log file */ public File getLogFile(String moduleName) { return new File( OpenCms.getSystemInfo().getAbsoluteRfsPathRelativeToWebInf("packages/_modulelogs/" + moduleName + ".log")); }
/** * Returns the path to the skin resources.<p> * * @return the path to the skin resources */ public static String getSkinUri() { if (m_skinUri == null) { m_skinUri = OpenCms.getSystemInfo().getContextPath() + RFS_PATH_RESOURCES; } return m_skinUri; }
/** * Returns the OpenCms request context path.<p> * * This is a convenience method to use in the editor.<p> * * @return the OpenCms request context path */ public String getOpenCmsContext() { return OpenCms.getSystemInfo().getOpenCmsContext(); }
/** * Creates a new cache instance.<p> */ public CmsPdfCache() { super(OpenCms.getSystemInfo().getWebInfRfsPath(), PDF_CACHE_FOLDER); }
/** * Sets the servlet container specific setting.<p> * * @param configValue the configuration value */ public void setPreventResponseFlush(String configValue) { OpenCms.getSystemInfo().getServletContainerSettings().setPreventResponseFlush( Boolean.valueOf(configValue).booleanValue()); }
/** * Returns the context path for embedded dialogs.<p> * * @return the context path for embedded dialogs */ public static String getEmbeddedDialogsContextPath() { return CmsStringUtil.joinPaths(OpenCms.getSystemInfo().getWorkplaceContext(), DIALOGS_PATH); }
/** * Sets the servlet container specific setting.<p> * * @param configValue the configuration value */ public void setRequestErrorPageAttribute(String configValue) { OpenCms.getSystemInfo().getServletContainerSettings().setRequestErrorPageAttribute(configValue); }
/** * Gets the link to the (new) workplace.<p> * * @return the link to the workplace */ public static String getWorkplaceLink() { return CmsStringUtil.joinPaths("/", OpenCms.getSystemInfo().getContextPath(), "workplace"); }
/** * Sets the encoding.<p> * * @param encoding the encoding to set * * @see CmsRequestContext#setEncoding(String) */ public void setEncoding(String encoding) { checkFrozen(); m_encoding = CmsEncoder.lookupEncoding(encoding, OpenCms.getSystemInfo().getDefaultEncoding()); }
/** * @see javax.servlet.jsp.tagext.Tag#doEndTag() */ @Override public int doEndTag() { if (OpenCms.getSystemInfo().getServletContainerSettings().isReleaseTagsAfterEnd()) { // need to release manually, JSP container may not call release as required (happens with Tomcat) release(); } return EVAL_PAGE; }
/** * Default constructor of a CmsHtmlMail.<p> * * The mail host name and the mail from address are set to the OpenCms * default values of the configuration.<p> * */ public CmsMultiPartMail() { // call super constructor super(); CmsMailUtil.configureMail(OpenCms.getSystemInfo().getMailSettings().getDefaultMailHost(), this); }
/** * @see javax.servlet.ServletResponseWrapper#flushBuffer() */ @Override public void flushBuffer() throws IOException { if (OpenCms.getSystemInfo().getServletContainerSettings().isPreventResponseFlush()) { // Websphere does not allow to set headers afterwards, so we have to prevent this call return; } super.flushBuffer(); }
/** * Sets the rfs export Path after normalizing.<p> * * @param exportPath the rfs export Path to set */ public void setExportPath(String exportPath) { if (exportPath.equals(OpenCms.getSystemInfo().getWebApplicationRfsPath())) { // not allowed because a full static export would delete the opencms directory throw new CmsIllegalArgumentException(Messages.get().container(Messages.ERR_INVALID_EXPORT_PATH_1, m_name)); } m_exportPath = exportPath; }
/** * Default constructor of a CmsSimpleMail.<p> * * The mail host name and the mail from address are set to the OpenCms * default values of the configuration.<p> * */ public CmsSimpleMail() { // call super constructor super(); CmsMailUtil.configureMail(OpenCms.getSystemInfo().getMailSettings().getDefaultMailHost(), this); }
/** * @see javax.servlet.jsp.tagext.Tag#doEndTag() */ @Override public int doEndTag() { if (OpenCms.getSystemInfo().getServletContainerSettings().isReleaseTagsAfterEnd()) { // need to release manually, JSP container may not call release as required (happens with Tomcat) release(); } return EVAL_PAGE; }
/** * @see javax.servlet.jsp.tagext.Tag#doEndTag() */ @Override public int doEndTag() { if (OpenCms.getSystemInfo().getServletContainerSettings().isReleaseTagsAfterEnd()) { // need to release manually, JSP container may not call release as required (happens with Tomcat) release(); } return EVAL_PAGE; }