| org.opencms.db.I_CmsProjectDriver
All known Subclasses: org.opencms.db.generic.CmsProjectDriver,
I_CmsProjectDriver | public interface I_CmsProjectDriver (Code) | | Definitions of all required project driver methods.
author: Thomas Weckert author: Michael Emmerich version: $Revision: 1.80 $ since: 6.0.0 |
Method Summary | |
CmsProject | createProject(CmsDbContext dbc, CmsUUID id, CmsUser owner, CmsGroup group, CmsGroup managergroup, String name, String description, int flags, CmsProjectType type) | void | createProjectResource(CmsDbContext dbc, CmsUUID projectId, String resourceName) | void | createPublishJob(CmsDbContext dbc, CmsPublishJobInfoBean publishJob) | void | deleteAllStaticExportPublishedResources(CmsDbContext dbc, int linkType) | void | deleteProject(CmsDbContext dbc, CmsProject project) Deletes a project from the cms.
Therefore it deletes all files, resources and properties. | void | deleteProjectResource(CmsDbContext dbc, CmsUUID projectId, String resourceName) | void | deleteProjectResources(CmsDbContext dbc, CmsProject project) | void | deletePublishHistory(CmsDbContext dbc, CmsUUID projectId, int maxPublishTag) Deletes all publish history entries with publish tags >=0 and < the specified max. | void | deletePublishHistoryEntry(CmsDbContext dbc, CmsUUID publishHistoryId, CmsPublishedResource publishResource) Deletes a publish history entry with publish tags >=0 and < the specified max. | void | deletePublishJob(CmsDbContext dbc, CmsUUID publishHistoryId) | void | deletePublishList(CmsDbContext dbc, CmsUUID publishHistoryId) | void | deleteStaticExportPublishedResource(CmsDbContext dbc, String resourceName, int linkType, String linkParameter) | void | destroy() | void | fillDefaults(CmsDbContext dbc) | CmsSqlManager | getSqlManager() | org.opencms.db.generic.CmsSqlManager | initSqlManager(String classname) | void | publishDeletedFolder(CmsDbContext dbc, I_CmsReport report, int m, int n, CmsProject onlineProject, CmsFolder offlineFolder, CmsUUID publishHistoryId, int publishTag) | void | publishFile(CmsDbContext dbc, I_CmsReport report, int m, int n, CmsProject onlineProject, CmsResource offlineResource, Set publishedContentIds, CmsUUID publishHistoryId, int publishTag) | CmsFile | publishFileContent(CmsDbContext dbc, CmsProject offlineProject, CmsProject onlineProject, CmsResource offlineFileHeader, Set publishedResourceIds, boolean needToUpdateContent, int publishTag) Publishes the content record of a file.
The content record is only published unless it's UUID is not contained in publishedContentIds. | void | publishFolder(CmsDbContext dbc, I_CmsReport report, int m, int n, CmsProject onlineProject, CmsFolder currentFolder, CmsUUID publishHistoryId, int publishTag) | void | publishProject(CmsDbContext dbc, I_CmsReport report, CmsProject onlineProject, CmsPublishList publishList, int publishTag) | List | readLocks(CmsDbContext dbc) | CmsProject | readProject(CmsDbContext dbc, CmsUUID id) | CmsProject | readProject(CmsDbContext dbc, String name) | String | readProjectResource(CmsDbContext dbc, CmsUUID projectId, String resourcename) | List | readProjectResources(CmsDbContext dbc, CmsProject project) | List | readProjects(CmsDbContext dbc, String ouFqn) | List | readProjectsForGroup(CmsDbContext dbc, CmsGroup group) | List | readProjectsForManagerGroup(CmsDbContext dbc, CmsGroup group) | List | readProjectsForUser(CmsDbContext dbc, CmsUser user) | CmsPublishJobInfoBean | readPublishJob(CmsDbContext dbc, CmsUUID publishHistoryId) | List | readPublishJobs(CmsDbContext dbc, long startTime, long endTime) Reads all publish jobs finished in the given time range.
If (0L, 0L) is passed as time range, all pending jobs are returned. | CmsPublishList | readPublishList(CmsDbContext dbc, CmsUUID publishHistoryId) | byte[] | readPublishReportContents(CmsDbContext dbc, CmsUUID publishHistoryId) | List | readPublishedResources(CmsDbContext dbc, CmsUUID publishHistoryId) | String | readStaticExportPublishedResourceParameters(CmsDbContext dbc, String rfsName) | List | readStaticExportResources(CmsDbContext dbc, int parameterResources, long timestamp) | void | unmarkProjectResources(CmsDbContext dbc, CmsProject project) | void | writeLocks(CmsDbContext dbc, List locks) | void | writeProject(CmsDbContext dbc, CmsProject project) | void | writePublishHistory(CmsDbContext dbc, CmsUUID publishId, CmsPublishedResource resource) | void | writePublishJob(CmsDbContext dbc, CmsPublishJobInfoBean publishJob) | void | writePublishReport(CmsDbContext dbc, CmsUUID publishId, byte[] content) | void | writeStaticExportPublishedResource(CmsDbContext dbc, String resourceName, int linkType, String linkParameter, long timestamp) |
DRIVER_TYPE_ID | int DRIVER_TYPE_ID(Code) | | The type ID to identify project driver implementations.
|
SETUP_PROJECT_NAME | String SETUP_PROJECT_NAME(Code) | | Name of the setup project.
|
TEMP_FILE_PROJECT_NAME | String TEMP_FILE_PROJECT_NAME(Code) | | The name of the temp file project.
|
createProject | CmsProject createProject(CmsDbContext dbc, CmsUUID id, CmsUser owner, CmsGroup group, CmsGroup managergroup, String name, String description, int flags, CmsProjectType type) throws CmsDataAccessException(Code) | | Creates a new project.
Parameters: dbc - the current database context Parameters: id - the project id Parameters: owner - the owner of the project Parameters: group - the group for the project Parameters: managergroup - the manager group for the project Parameters: name - the name of the project to create Parameters: description - the description for the project Parameters: flags - the flags for the project Parameters: type - the type for the project the created CmsProject instance throws: CmsDataAccessException - if something goes wrong |
createProjectResource | void createProjectResource(CmsDbContext dbc, CmsUUID projectId, String resourceName) throws CmsDataAccessException(Code) | | Creates a new projectResource from a given CmsResource object.
Parameters: dbc - the current database context Parameters: projectId - The project in which the resource will be used Parameters: resourceName - The resource to be written to the Cms throws: CmsDataAccessException - if something goes wrong |
deleteAllStaticExportPublishedResources | void deleteAllStaticExportPublishedResources(CmsDbContext dbc, int linkType) throws CmsDataAccessException(Code) | | Deletes all entries in the published resource table.
Parameters: dbc - the current database context Parameters: linkType - the type of resource deleted (0= non-paramter, 1=parameter) throws: CmsDataAccessException - if something goes wrong |
deleteProjectResource | void deleteProjectResource(CmsDbContext dbc, CmsUUID projectId, String resourceName) throws CmsDataAccessException(Code) | | Delete a projectResource from an given CmsResource object.
Parameters: dbc - the current database context Parameters: projectId - id of the project in which the resource is used Parameters: resourceName - name of the resource to be deleted from the Cms throws: CmsDataAccessException - if something goes wrong |
deletePublishHistory | void deletePublishHistory(CmsDbContext dbc, CmsUUID projectId, int maxPublishTag) throws CmsDataAccessException(Code) | | Deletes all publish history entries with publish tags >=0 and < the specified max. publish tag.
Parameters: dbc - the current database context Parameters: projectId - the ID of the current project Parameters: maxPublishTag - entries with publish tags >=0 and < this max. publish tag get deleted throws: CmsDataAccessException - if something goes wrong |
deletePublishHistoryEntry | void deletePublishHistoryEntry(CmsDbContext dbc, CmsUUID publishHistoryId, CmsPublishedResource publishResource) throws CmsDataAccessException(Code) | | Deletes a publish history entry with publish tags >=0 and < the specified max. publish tag.
Parameters: dbc - the current database context Parameters: publishHistoryId - the id of the history to delete the entry from Parameters: publishResource - the entry to delete throws: CmsDataAccessException - if something goes wrong |
deletePublishJob | void deletePublishJob(CmsDbContext dbc, CmsUUID publishHistoryId) throws CmsDataAccessException(Code) | | Deletes a publish job identified by its history id.
Parameters: dbc - the current database context Parameters: publishHistoryId - the history id identifying the publish job throws: CmsDataAccessException - if something goes wrong |
deletePublishList | void deletePublishList(CmsDbContext dbc, CmsUUID publishHistoryId) throws CmsDataAccessException(Code) | | Deletes the publish list assigned to a publish job.
Parameters: dbc - the current database context Parameters: publishHistoryId - the history id identifying the publish job throws: CmsDataAccessException - if something goes wrong |
deleteStaticExportPublishedResource | void deleteStaticExportPublishedResource(CmsDbContext dbc, String resourceName, int linkType, String linkParameter) throws CmsDataAccessException(Code) | | Deletes an entry in the published resource table.
Parameters: dbc - the current database context Parameters: resourceName - The name of the resource to be deleted in the static export Parameters: linkType - the type of resource deleted (0= non-paramter, 1=parameter) Parameters: linkParameter - the parameters of the resource throws: CmsDataAccessException - if something goes wrong |
getSqlManager | CmsSqlManager getSqlManager()(Code) | | Returns the SqlManager of this driver.
the SqlManager of this driver |
initSqlManager | org.opencms.db.generic.CmsSqlManager initSqlManager(String classname)(Code) | | Initializes the SQL manager for this driver.
To obtain JDBC connections from different pools, further
{online|offline|history} pool Urls have to be specified.
Parameters: classname - the classname of the SQL manager the SQL manager for this driver |
publishDeletedFolder | void publishDeletedFolder(CmsDbContext dbc, I_CmsReport report, int m, int n, CmsProject onlineProject, CmsFolder offlineFolder, CmsUUID publishHistoryId, int publishTag) throws CmsDataAccessException(Code) | | Publishes a deleted folder.
Parameters: dbc - the current database context Parameters: report - the report to log the output to Parameters: m - the number of the folder to publish Parameters: n - the number of all folders to publish Parameters: onlineProject - the online project Parameters: offlineFolder - the offline folder to publish Parameters: publishHistoryId - the publish history id Parameters: publishTag - the publish tag throws: CmsDataAccessException - if something goes wrong |
publishFile | void publishFile(CmsDbContext dbc, I_CmsReport report, int m, int n, CmsProject onlineProject, CmsResource offlineResource, Set publishedContentIds, CmsUUID publishHistoryId, int publishTag) throws CmsDataAccessException(Code) | | Publishes a new, changed or deleted file.
Parameters: dbc - the current database context Parameters: report - the report to log the output to Parameters: m - the number of the file to publish Parameters: n - the number of all files to publish Parameters: onlineProject - the online project Parameters: offlineResource - the offline file to publish Parameters: publishedContentIds - contains the UUIDs of already published content records Parameters: publishHistoryId - the publish history id Parameters: publishTag - the publish tag throws: CmsDataAccessException - if something goes wrong |
publishFileContent | CmsFile publishFileContent(CmsDbContext dbc, CmsProject offlineProject, CmsProject onlineProject, CmsResource offlineFileHeader, Set publishedResourceIds, boolean needToUpdateContent, int publishTag) throws CmsDataAccessException(Code) | | Publishes the content record of a file.
The content record is only published unless it's UUID is not contained in publishedContentIds.
The calling method has to take care about whether an existing content record has to be deleted
before or not.
The intention of this method is to get overloaded in a project driver
for a specific DB server to shift the binary content from the offline into the online table
in a more sophisticated way than in the generic ANSI-SQL implementation of this interface.
Parameters: dbc - the current database context Parameters: offlineProject - the offline project to read data Parameters: onlineProject - the online project to write data Parameters: offlineFileHeader - the offline header of the file of which the content gets published Parameters: publishedResourceIds - a Set with the UUIDs of the already published content records Parameters: needToUpdateContent - true if the content record has to be updated Parameters: publishTag - the publish tag the published file (online) throws: CmsDataAccessException - if something goes wrong |
publishFolder | void publishFolder(CmsDbContext dbc, I_CmsReport report, int m, int n, CmsProject onlineProject, CmsFolder currentFolder, CmsUUID publishHistoryId, int publishTag) throws CmsDataAccessException(Code) | | Publishes a new or changed folder.
Parameters: dbc - the current database context Parameters: report - the report to log the output to Parameters: m - the number of the folder to publish Parameters: n - the number of all folders to publish Parameters: onlineProject - the online project Parameters: currentFolder - the offline folder to publish Parameters: publishHistoryId - the publish history id Parameters: publishTag - the publish tag throws: CmsDataAccessException - if something goes wrong |
publishProject | void publishProject(CmsDbContext dbc, I_CmsReport report, CmsProject onlineProject, CmsPublishList publishList, int publishTag) throws CmsException(Code) | | Publishes a specified project to the online project.
Parameters: dbc - the current database context Parameters: report - an I_CmsReport instance to print output messages Parameters: onlineProject - the online project Parameters: publishList - a Cms publish list Parameters: publishTag - the publish tag throws: CmsException - if something goes wrong |
readProjectResource | String readProjectResource(CmsDbContext dbc, CmsUUID projectId, String resourcename) throws CmsDataAccessException(Code) | | Reads the project resource path for a given project and resource path,
to validate if a resource path for a given project already exists.
Parameters: dbc - the current database context Parameters: projectId - the ID of the project for which the resource path is read Parameters: resourcename - the project's resource path String the project's resource path throws: CmsDataAccessException - if something goes wrong |
readProjectResources | List readProjectResources(CmsDbContext dbc, CmsProject project) throws CmsDataAccessException(Code) | | Reads the project resources for a specified project.
Parameters: dbc - the current database context Parameters: project - the project for which the resource path is read a list of all project resource paths throws: CmsDataAccessException - if something goes wrong |
readPublishJobs | List readPublishJobs(CmsDbContext dbc, long startTime, long endTime) throws CmsDataAccessException(Code) | | Reads all publish jobs finished in the given time range.
If (0L, 0L) is passed as time range, all pending jobs are returned.
Parameters: dbc - the current database context Parameters: startTime - the start of the time range for finish time Parameters: endTime - the end of the time range for finish time a list of objects of type CmsPublishJobInfoBean throws: CmsDataAccessException - if something goes wrong |
readPublishReportContents | byte[] readPublishReportContents(CmsDbContext dbc, CmsUUID publishHistoryId) throws CmsDataAccessException(Code) | | Reads the publish report assigned to a publish job.
Parameters: dbc - the current database context Parameters: publishHistoryId - the history id identifying the publish job the content of the assigned publish report throws: CmsDataAccessException - if something goes wrong |
readStaticExportPublishedResourceParameters | String readStaticExportPublishedResourceParameters(CmsDbContext dbc, String rfsName) throws CmsDataAccessException(Code) | | Returns the parameters of a resource in the table of all published template resources.
Parameters: dbc - the current database context Parameters: rfsName - the rfs name of the resource the paramter string of the requested resource throws: CmsDataAccessException - if something goes wrong |
readStaticExportResources | List readStaticExportResources(CmsDbContext dbc, int parameterResources, long timestamp) throws CmsDataAccessException(Code) | | Returns a list of all template resources which must be processed during a static export.
Parameters: dbc - the current database context Parameters: parameterResources - flag for reading resources with parameters (1) or without (0) Parameters: timestamp - the timestamp information a list of template resources as String objects throws: CmsDataAccessException - if something goes wrong |
unmarkProjectResources | void unmarkProjectResources(CmsDbContext dbc, CmsProject project) throws CmsDataAccessException(Code) | | Removes the project id from all resources within a project.
This must be done when a project will deleted
Parameters: dbc - the current database context Parameters: project - the project to delete throws: CmsDataAccessException - if something goes wrong |
writeProject | void writeProject(CmsDbContext dbc, CmsProject project) throws CmsDataAccessException(Code) | | Writes an already existing project.
The project id has to be a valid OpenCms project id.
The project with the given id will be completely overriden
by the given data.
Parameters: dbc - the current database context Parameters: project - the project that should be written throws: CmsDataAccessException - if operation was not successful |
writePublishHistory | void writePublishHistory(CmsDbContext dbc, CmsUUID publishId, CmsPublishedResource resource) throws CmsDataAccessException(Code) | | Inserts an entry in the publish history for a published VFS resource.
Parameters: dbc - the current database context Parameters: publishId - the ID of the current publishing process Parameters: resource - the state of the resource *before* it was published throws: CmsDataAccessException - if something goes wrong |
writePublishReport | void writePublishReport(CmsDbContext dbc, CmsUUID publishId, byte[] content) throws CmsDataAccessException(Code) | | Writes a publish report for a publish job.
Parameters: dbc - the current database context Parameters: publishId - the ID of the current publishing process Parameters: content - the report output throws: CmsDataAccessException - if something goes wrong |
writeStaticExportPublishedResource | void writeStaticExportPublishedResource(CmsDbContext dbc, String resourceName, int linkType, String linkParameter, long timestamp) throws CmsDataAccessException(Code) | | Inserts an entry in the published resource table.
This is done during static export.
Parameters: dbc - the current database context Parameters: resourceName - The name of the resource to be added to the static export Parameters: linkType - the type of resource exported (0= non-paramter, 1=parameter) Parameters: linkParameter - the parameters added to the resource Parameters: timestamp - a timestamp for writing the data into the db throws: CmsDataAccessException - if something goes wrong |
|
|