/** * Creates a new publish job.<p> * * @param dbc the current database context * @param publishJob the publish job to create * * @throws CmsException if something goes wrong */ public void createPublishJob(CmsDbContext dbc, CmsPublishJobInfoBean publishJob) throws CmsException { m_projectDriver.createPublishJob(dbc, publishJob); }
/** * Deletes all entries in the published resource table.<p> * * @param dbc the current database context * @param linkType the type of resource deleted (0= non-paramter, 1=parameter) * * @throws CmsException if something goes wrong */ public void deleteAllStaticExportPublishedResources(CmsDbContext dbc, int linkType) throws CmsException { m_projectDriver.deleteAllStaticExportPublishedResources(dbc, linkType); }
/** * Deletes a publish job identified by its history id.<p> * * @param dbc the current database context * @param publishHistoryId the history id identifying the publish job * * @throws CmsException if something goes wrong */ public void deletePublishJob(CmsDbContext dbc, CmsUUID publishHistoryId) throws CmsException { m_projectDriver.deletePublishJob(dbc, publishHistoryId); }
dbc.getRequestContext().setAttribute(CmsProjectDriver.DBC_ATTR_READ_PROJECT_FOR_RESOURCE, Boolean.TRUE); I_CmsProjectDriver projectDriver = m_driverManager.getProjectDriver(dbc); Iterator<CmsProject> itProjects = projectDriver.readProjects(dbc, deletedResourceRootPath).iterator(); while (itProjects.hasNext()) { CmsProject project = itProjects.next(); projectDriver.deleteProjectResource(dbc, project.getUuid(), deletedResourceRootPath); projectDriver.createProjectResource(dbc, project.getUuid(), destinationPath);
/** * Creates the project for the temporary workplace files.<p> * * @param dbc the current database context * * @return the created project for the temporary workplace files * * @throws CmsException if something goes wrong */ public CmsProject createTempfileProject(CmsDbContext dbc) throws CmsException { // read the needed groups from the cms CmsGroup projectUserGroup = readGroup(dbc, dbc.currentProject().getGroupId()); CmsGroup projectManagerGroup = readGroup(dbc, dbc.currentProject().getManagerGroupId()); CmsProject tempProject = m_projectDriver.createProject( dbc, new CmsUUID(), dbc.currentUser(), projectUserGroup, projectManagerGroup, I_CmsProjectDriver.TEMP_FILE_PROJECT_NAME, Messages.get().getBundle(dbc.getRequestContext().getLocale()).key( Messages.GUI_WORKPLACE_TEMPFILE_PROJECT_DESC_0), CmsProject.PROJECT_FLAG_HIDDEN, CmsProject.PROJECT_TYPE_NORMAL); m_projectDriver.createProjectResource(dbc, tempProject.getUuid(), "/"); OpenCms.fireCmsEvent(new CmsEvent(I_CmsEventListener.EVENT_PROJECT_MODIFIED, Collections.singletonMap( "project", tempProject))); return tempProject; }
List projectResources = m_projectDriver.readProjectResources(dbc, dbc.currentProject()); for (int i = 0; i < projectResources.size(); i++) { String resname = (String)projectResources.get(i); if (resname.startsWith(resource.getRootPath())) { m_projectDriver.deleteProjectResource(dbc, dbc.currentProject().getUuid(), resname); m_projectDriver.createProjectResource(dbc, dbc.currentProject().getUuid(), resource.getRootPath()); } catch (CmsException exc) {
dbc.getRequestContext().setAttribute(CmsProjectDriver.DBC_ATTR_READ_PROJECT_FOR_RESOURCE, Boolean.TRUE); I_CmsProjectDriver projectDriver = m_driverManager.getProjectDriver(dbc); Iterator<CmsProject> itProjects = projectDriver.readProjects(dbc, deletedResourceRootPath).iterator(); while (itProjects.hasNext()) { CmsProject project = itProjects.next(); projectDriver.deleteProjectResource(dbc, project.getUuid(), deletedResourceRootPath);
List projectResources = m_projectDriver.readProjectResources(dbc, dbc.currentProject()); for (int i = 0; i < projectResources.size(); i++) { String resname = (String)projectResources.get(i); if (resname.startsWith(resource.getRootPath())) { m_projectDriver.deleteProjectResource(dbc, dbc.currentProject().getUuid(), resname); m_projectDriver.deleteProjectResource(dbc, dbc.currentProject().getUuid(), resource.getRootPath()); } catch (CmsException exc) {
getProjectDriver().publishProject(dbc, report, onlineProject, publishList, publishTag); getProjectDriver().deleteProject(dbc, dbc.currentProject()); } catch (CmsException e) { LOG.error(Messages.get().getBundle().key(
m_driverManager.getProjectDriver(dbc).createProjectResource( dbc, orgUnit.getProjectId(),
m_driverManager.getProjectDriver().deleteProjectResource( dbc, orgUnit.getProjectId(),
/** * Deletes the publish list assigned to a publish job.<p> * * @param dbc the current database context * @param publishHistoryId the history id identifying the publish job * @throws CmsException if something goes wrong */ public void deletePublishList(CmsDbContext dbc, CmsUUID publishHistoryId) throws CmsException { m_projectDriver.deletePublishList(dbc, publishHistoryId); }
/** * Deletes an entry in the published resource table.<p> * * @param dbc the current database context * @param resourceName The name of the resource to be deleted in the static export * @param linkType the type of resource deleted (0= non-parameter, 1=parameter) * @param linkParameter the parameters of the resource * * @throws CmsException if something goes wrong */ public void deleteStaticExportPublishedResource( CmsDbContext dbc, String resourceName, int linkType, String linkParameter) throws CmsException { m_projectDriver.deleteStaticExportPublishedResource(dbc, resourceName, linkType, linkParameter); }
getProjectDriver(dbc).deleteProject(dbc, deleteProject); m_monitor.uncacheProject(deleteProject);
CmsGroup managergroup = readGroup(dbc, managergroupname); return m_projectDriver.createProject( dbc, new CmsUUID(),
if (m_projectDriver != null) { try { m_projectDriver.destroy(); } catch (Throwable t) { LOG.error(Messages.get().getBundle().key(Messages.ERR_CLOSE_PROJECT_DRIVER_0), t);
dbc.getRequestContext().setAttribute(CmsProjectDriver.DBC_ATTR_READ_PROJECT_FOR_RESOURCE, Boolean.TRUE); I_CmsProjectDriver projectDriver = m_driverManager.getProjectDriver(dbc); Iterator<CmsProject> itProjects = projectDriver.readProjects(dbc, deletedResourceRootPath).iterator(); while (itProjects.hasNext()) { CmsProject project = itProjects.next(); projectDriver.deleteProjectResource(dbc, project.getUuid(), deletedResourceRootPath); projectDriver.createProjectResource(dbc, project.getUuid(), destinationPath);
CmsGroup projectManagerGroup = readGroup(dbc, dbc.currentProject().getManagerGroupId()); CmsProject tempProject = getProjectDriver(dbc).createProject( dbc, new CmsUUID(), CmsProject.PROJECT_FLAG_HIDDEN, CmsProject.PROJECT_TYPE_NORMAL); getProjectDriver(dbc).createProjectResource(dbc, tempProject.getUuid(), "/");
List<String> projectResources = projectDriver.readProjectResources(dbc, dbc.currentProject()); for (int i = 0; i < projectResources.size(); i++) { String resname = projectResources.get(i); if (resname.startsWith(resource.getRootPath())) { projectDriver.deleteProjectResource(dbc, dbc.currentProject().getUuid(), resname); projectDriver.createProjectResource(dbc, dbc.currentProject().getUuid(), resource.getRootPath()); } catch (CmsException exc) {
dbc.getRequestContext().setAttribute(CmsProjectDriver.DBC_ATTR_READ_PROJECT_FOR_RESOURCE, Boolean.TRUE); I_CmsProjectDriver projectDriver = m_driverManager.getProjectDriver(dbc); Iterator<CmsProject> itProjects = projectDriver.readProjects(dbc, deletedResourceRootPath).iterator(); while (itProjects.hasNext()) { CmsProject project = itProjects.next(); projectDriver.deleteProjectResource(dbc, project.getUuid(), deletedResourceRootPath);