/** * @see org.opencms.file.CmsResource#isTemporaryFile() */ @Override public boolean isTemporaryFile() { return ((getFlags() & CmsResource.FLAG_TEMPFILE) > 0) || isTemporaryFileName(getName()); }
/** * Creates a new data source for the given VFS resource.<p> * * @param cms the current users OpenCms context * @param resource the resource to use * * @throws CmsException in case of errors accessing the resource in the VFS */ public CmsVfsDataSource(CmsObject cms, CmsResource resource) throws CmsException { m_file = cms.readFile(resource); // identify the mime-type for the data source m_contentType = OpenCms.getResourceManager().getMimeType( m_file.getName(), cms.getRequestContext().getEncoding()); }
title = templateFile.getName();
/** * Creates a new data source for the given VFS resource.<p> * * @param cms the current users OpenCms context * @param resource the resource to use * * @throws CmsException in case of errors accessing the resource in the VFS */ public CmsVfsDataSource(CmsObject cms, CmsResource resource) throws CmsException { m_file = cms.readFile(resource); // identify the mime-type for the data source m_contentType = OpenCms.getResourceManager().getMimeType( m_file.getName(), cms.getRequestContext().getEncoding()); }
title = templateFile.getName();
m_macroResolver.setResourceName(file.getName());
+ "_" + System.currentTimeMillis() + getSuffix(tempFile.getName()); CmsObject adminCms = OpenCms.initCmsObject(m_adminCms); CmsProject tempProject = adminCms.createTempfileProject();
file.getName(), exportCms.getRequestContext().getEncoding()); if (wrapRes != null) {