Java Doc for CmsHistoryDriver.java in  » Content-Management-System » opencms » org » opencms » db » generic » Java Source Code / Java DocumentationJava Source Code and Java Documentation

Java Source Code / Java Documentation
1. 6.0 JDK Core
2. 6.0 JDK Modules
3. 6.0 JDK Modules com.sun
4. 6.0 JDK Modules com.sun.java
5. 6.0 JDK Modules sun
6. 6.0 JDK Platform
7. Ajax
8. Apache Harmony Java SE
9. Aspect oriented
10. Authentication Authorization
11. Blogger System
12. Build
13. Byte Code
14. Cache
15. Chart
16. Chat
17. Code Analyzer
18. Collaboration
19. Content Management System
20. Database Client
21. Database DBMS
22. Database JDBC Connection Pool
23. Database ORM
24. Development
25. EJB Server geronimo
26. EJB Server GlassFish
27. EJB Server JBoss 4.2.1
28. EJB Server resin 3.1.5
29. ERP CRM Financial
30. ESB
31. Forum
32. GIS
33. Graphic Library
34. Groupware
35. HTML Parser
36. IDE
37. IDE Eclipse
38. IDE Netbeans
39. Installer
40. Internationalization Localization
41. Inversion of Control
42. Issue Tracking
43. J2EE
44. JBoss
45. JMS
46. JMX
47. Library
48. Mail Clients
49. Net
50. Parser
51. PDF
52. Portal
53. Profiler
54. Project Management
55. Report
56. RSS RDF
57. Rule Engine
58. Science
59. Scripting
60. Search Engine
61. Security
62. Sevlet Container
63. Source Control
64. Swing Library
65. Template Engine
66. Test Coverage
67. Testing
68. UML
69. Web Crawler
70. Web Framework
71. Web Mail
72. Web Server
73. Web Services
74. Web Services apache cxf 2.0.1
75. Web Services AXIS2
76. Wiki Engine
77. Workflow Engines
78. XML
79. XML UI
Java
Java Tutorial
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
Photoshop Tutorials
Maya Tutorials
Flash Tutorials
3ds-Max Tutorials
Illustrator Tutorials
GIMP Tutorials
C# / C Sharp
C# / CSharp Tutorial
C# / CSharp Open Source
ASP.Net
ASP.NET Tutorial
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
Ruby
PHP
Python
Python Tutorial
Python Open Source
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
VBA / Excel / Access / Word
XML
XML Tutorial
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
Java Source Code / Java Documentation » Content Management System » opencms » org.opencms.db.generic 
Source Cross Reference  Class Diagram Java Document (Java Doc) 


java.lang.Object
   org.opencms.db.generic.CmsHistoryDriver

All known Subclasses:   org.opencms.db.generic.CmsBackupDriver,  org.opencms.db.hsqldb.CmsHistoryDriver,  org.opencms.db.as400.CmsHistoryDriver,  org.opencms.db.db2.CmsHistoryDriver,  org.opencms.db.oracle.CmsHistoryDriver,  org.opencms.db.postgresql.CmsHistoryDriver,  org.opencms.db.mysql.CmsHistoryDriver,  org.opencms.db.mssql.CmsHistoryDriver,
CmsHistoryDriver
public class CmsHistoryDriver implements I_CmsDriver,I_CmsHistoryDriver(Code)
Generic (ANSI-SQL) database server implementation of the history driver methods.


author:
   Thomas Weckert
author:
   Michael Emmerich
author:
   Carsten Weinholz
author:
   Michael Moossen
version:
   $Revision: 1.9 $
since:
   6.9.1



Field Summary
protected  CmsDriverManagerm_driverManager
     The driver manager instance.
protected  org.opencms.db.generic.CmsSqlManagerm_sqlManager
     The SQL manager instance.


Method Summary
public  CmsPropertyDefinitioncreatePropertyDefinition(CmsDbContext dbc, String name, CmsPropertyDefinition.CmsPropertyType type)
    
public  intdeleteEntries(CmsDbContext dbc, I_CmsHistoryResource resource, int versionsToKeep, long time)
    
public  voiddeletePropertyDefinition(CmsDbContext dbc, CmsPropertyDefinition metadef)
    
public  voiddestroy()
    
public  ListgetAllDeletedEntries(CmsDbContext dbc, CmsUUID parentId)
    
public  ListgetAllNotDeletedEntries(CmsDbContext dbc, CmsUUID parentId)
    
public  CmsSqlManagergetSqlManager()
    
public  voidinit(CmsDbContext dbc, CmsConfigurationManager configurationManager, List successiveDrivers, CmsDriverManager driverManager)
    
public  org.opencms.db.generic.CmsSqlManagerinitSqlManager(String classname)
    
protected  voidinternalAddToPropMap(Map propertyMap, I_CmsHistoryResource resource, String propertyKey, String propertyValue, int mappingType)
    
protected  voidinternalCleanup(CmsDbContext dbc, I_CmsHistoryResource resource)
    
protected  intinternalCountProperties(CmsDbContext dbc, CmsPropertyDefinition metadef, CmsUUID projectId)
    
protected  CmsHistoryProjectinternalCreateProject(ResultSet res, List resources)
    
protected  I_CmsHistoryResourceinternalCreateResource(ResultSet res)
    
protected  ListinternalFilterParentId(CmsUUID parentId, List resources)
    
protected  I_CmsHistoryResourceinternalMergeResource(I_CmsHistoryResource histRes, ResultSet res, int versionOffset)
    
protected  booleaninternalValidateResource(CmsDbContext dbc, CmsResource resource, int publishTag)
    
public  ListreadAllAvailableVersions(CmsDbContext dbc, CmsUUID structureId)
    
public  byte[]readContent(CmsDbContext dbc, CmsUUID resourceId, int publishTag)
    
public  ListreadDeletedResources(CmsDbContext dbc, CmsUUID structureId, CmsUUID userId)
    
public  I_CmsHistoryResourcereadFile(CmsDbContext dbc, CmsUUID structureId, int tagId)
    
public  intreadLastVersion(CmsDbContext dbc, CmsUUID structureId)
    
public  intreadMaxPublishTag(CmsDbContext dbc, CmsUUID resourceId)
    
public  intreadNextPublishTag(CmsDbContext dbc)
    
public  CmsHistoryPrincipalreadPrincipal(CmsDbContext dbc, CmsUUID principalId)
    
public  CmsHistoryProjectreadProject(CmsDbContext dbc, int publishTag)
    
public  ListreadProjectResources(CmsDbContext dbc, int publishTag)
    
public  ListreadProjects(CmsDbContext dbc)
    
public  ListreadProperties(CmsDbContext dbc, I_CmsHistoryResource resource)
    
public  CmsPropertyDefinitionreadPropertyDefinition(CmsDbContext dbc, String name)
    
public  intreadPublishTag(CmsDbContext dbc, long maxdate)
    
public  I_CmsHistoryResourcereadResource(CmsDbContext dbc, CmsUUID structureId, int version)
    
public  voidwritePrincipal(CmsDbContext dbc, I_CmsPrincipal principal)
    
public  voidwriteProject(CmsDbContext dbc, int publishTag, long publishDate)
    
public  voidwriteProperties(CmsDbContext dbc, CmsResource resource, List properties, int publishTag)
    
public  voidwriteResource(CmsDbContext dbc, CmsResource resource, List properties, int publishTag)
    

Field Detail
m_driverManager
protected CmsDriverManager m_driverManager(Code)
The driver manager instance.



m_sqlManager
protected org.opencms.db.generic.CmsSqlManager m_sqlManager(Code)
The SQL manager instance.





Method Detail
createPropertyDefinition
public CmsPropertyDefinition createPropertyDefinition(CmsDbContext dbc, String name, CmsPropertyDefinition.CmsPropertyType type) throws CmsDataAccessException(Code)

See Also:   org.opencms.db.I_CmsHistoryDriver.createPropertyDefinition(org.opencms.db.CmsDbContextjava.lang.Stringorg.opencms.file.CmsPropertyDefinition.CmsPropertyType)



deleteEntries
public int deleteEntries(CmsDbContext dbc, I_CmsHistoryResource resource, int versionsToKeep, long time) throws CmsDataAccessException(Code)

See Also:   org.opencms.db.I_CmsHistoryDriver.deleteEntries(CmsDbContextI_CmsHistoryResourceintlong)



deletePropertyDefinition
public void deletePropertyDefinition(CmsDbContext dbc, CmsPropertyDefinition metadef) throws CmsDataAccessException(Code)

See Also:   org.opencms.db.I_CmsHistoryDriver.deletePropertyDefinition(org.opencms.db.CmsDbContextorg.opencms.file.CmsPropertyDefinition)



destroy
public void destroy() throws Throwable(Code)

See Also:   org.opencms.db.I_CmsHistoryDriver.destroy



getAllDeletedEntries
public List getAllDeletedEntries(CmsDbContext dbc, CmsUUID parentId) throws CmsDataAccessException(Code)

See Also:   org.opencms.db.I_CmsHistoryDriver.getAllDeletedEntries(CmsDbContextCmsUUID)



getAllNotDeletedEntries
public List getAllNotDeletedEntries(CmsDbContext dbc, CmsUUID parentId) throws CmsDataAccessException(Code)

See Also:   org.opencms.db.I_CmsHistoryDriver.getAllNotDeletedEntries(CmsDbContextCmsUUID)



getSqlManager
public CmsSqlManager getSqlManager()(Code)

See Also:   org.opencms.db.I_CmsHistoryDriver.getSqlManager



init
public void init(CmsDbContext dbc, CmsConfigurationManager configurationManager, List successiveDrivers, CmsDriverManager driverManager)(Code)

See Also:   org.opencms.db.I_CmsDriver.init(org.opencms.db.CmsDbContextorg.opencms.configuration.CmsConfigurationManagerjava.util.Listorg.opencms.db.CmsDriverManager)



initSqlManager
public org.opencms.db.generic.CmsSqlManager initSqlManager(String classname)(Code)

See Also:   org.opencms.db.I_CmsHistoryDriver.initSqlManager(String)



internalAddToPropMap
protected void internalAddToPropMap(Map propertyMap, I_CmsHistoryResource resource, String propertyKey, String propertyValue, int mappingType) throws CmsDbConsistencyException(Code)
Updates the property map for the given resource with the given property data.


Parameters:
  propertyMap - the map to update
Parameters:
  resource - the resource the properties belong to
Parameters:
  propertyKey - the property key
Parameters:
  propertyValue - the property value
Parameters:
  mappingType - the mapping type
throws:
  CmsDbConsistencyException - if the mapping type is wrong




internalCleanup
protected void internalCleanup(CmsDbContext dbc, I_CmsHistoryResource resource) throws CmsDataAccessException(Code)
Deletes all historical entries of subresources of a folder without any historical netry left.


Parameters:
  dbc - the current database context
Parameters:
  resource - the resource to check
throws:
  CmsDataAccessException - if something goes wrong




internalCountProperties
protected int internalCountProperties(CmsDbContext dbc, CmsPropertyDefinition metadef, CmsUUID projectId) throws CmsDataAccessException(Code)
Returns the amount of properties for a propertydefinition.


Parameters:
  dbc - the current database context
Parameters:
  metadef - the propertydefinition to test
Parameters:
  projectId - the ID of the current project the amount of properties for a propertydefinition
throws:
  CmsDataAccessException - if something goes wrong




internalCreateProject
protected CmsHistoryProject internalCreateProject(ResultSet res, List resources) throws SQLException(Code)
Creates a historical project from the given result set and resources.


Parameters:
  res - the resource set
Parameters:
  resources - the historical resources the historical project
throws:
  SQLException - if something goes wrong




internalCreateResource
protected I_CmsHistoryResource internalCreateResource(ResultSet res) throws SQLException(Code)
Creates a valid I_CmsHistoryResource instance from a JDBC ResultSet.


Parameters:
  res - the JDBC result set the new historical resource instance
throws:
  SQLException - if a requested attribute was not found in the result set




internalFilterParentId
protected List internalFilterParentId(CmsUUID parentId, List resources)(Code)
Filters all resources in the subtree of the folder identified by the given id.


Parameters:
  parentId - the id of the folder to filter
Parameters:
  resources - the resources to filter the filtered list of resource




internalMergeResource
protected I_CmsHistoryResource internalMergeResource(I_CmsHistoryResource histRes, ResultSet res, int versionOffset) throws SQLException(Code)
Merges an historical entry for a sibling, based on the structure data from the given historical resource and result set for the resource entry.


Parameters:
  histRes - the original historical entry
Parameters:
  res - the result set of the resource entry
Parameters:
  versionOffset - the offset for the structure version a merged historical entry for the sibling
throws:
  SQLException - if something goes wrong




internalValidateResource
protected boolean internalValidateResource(CmsDbContext dbc, CmsResource resource, int publishTag) throws CmsDataAccessException(Code)
Tests if a history resource does exist.


Parameters:
  dbc - the current database context
Parameters:
  resource - the resource to test
Parameters:
  publishTag - the publish tag of the resource to test true if the resource already exists, false otherwise
throws:
  CmsDataAccessException - if something goes wrong




readAllAvailableVersions
public List readAllAvailableVersions(CmsDbContext dbc, CmsUUID structureId) throws CmsDataAccessException(Code)

See Also:   org.opencms.db.I_CmsHistoryDriver.readAllAvailableVersions(CmsDbContextCmsUUID)



readContent
public byte[] readContent(CmsDbContext dbc, CmsUUID resourceId, int publishTag) throws CmsDataAccessException(Code)

See Also:   org.opencms.db.I_CmsHistoryDriver.readContent(org.opencms.db.CmsDbContextorg.opencms.util.CmsUUIDint)



readDeletedResources
public List readDeletedResources(CmsDbContext dbc, CmsUUID structureId, CmsUUID userId) throws CmsDataAccessException(Code)

See Also:   org.opencms.db.I_CmsHistoryDriver.readDeletedResources(CmsDbContextCmsUUIDCmsUUID)



readFile
public I_CmsHistoryResource readFile(CmsDbContext dbc, CmsUUID structureId, int tagId) throws CmsDataAccessException(Code)

See Also:   org.opencms.db.I_CmsHistoryDriver.readFile(CmsDbContextCmsUUIDint)



readLastVersion
public int readLastVersion(CmsDbContext dbc, CmsUUID structureId) throws CmsDataAccessException(Code)

See Also:   org.opencms.db.I_CmsHistoryDriver.readLastVersion(org.opencms.db.CmsDbContextorg.opencms.util.CmsUUID)



readMaxPublishTag
public int readMaxPublishTag(CmsDbContext dbc, CmsUUID resourceId) throws CmsDataAccessException(Code)

See Also:   org.opencms.db.I_CmsHistoryDriver.readMaxPublishTag(CmsDbContextCmsUUID)



readNextPublishTag
public int readNextPublishTag(CmsDbContext dbc)(Code)

See Also:   org.opencms.db.I_CmsHistoryDriver.readNextPublishTag(org.opencms.db.CmsDbContext)



readPrincipal
public CmsHistoryPrincipal readPrincipal(CmsDbContext dbc, CmsUUID principalId) throws CmsDataAccessException(Code)

See Also:   org.opencms.db.I_CmsHistoryDriver.readPrincipal(org.opencms.db.CmsDbContextorg.opencms.util.CmsUUID)



readProject
public CmsHistoryProject readProject(CmsDbContext dbc, int publishTag) throws CmsDataAccessException(Code)

See Also:   org.opencms.db.I_CmsHistoryDriver.readProject(org.opencms.db.CmsDbContextint)



readProjectResources
public List readProjectResources(CmsDbContext dbc, int publishTag) throws CmsDataAccessException(Code)

See Also:   org.opencms.db.I_CmsHistoryDriver.readProjectResources(org.opencms.db.CmsDbContextint)



readProjects
public List readProjects(CmsDbContext dbc) throws CmsDataAccessException(Code)

See Also:   org.opencms.db.I_CmsHistoryDriver.readProjects(org.opencms.db.CmsDbContext)



readProperties
public List readProperties(CmsDbContext dbc, I_CmsHistoryResource resource) throws CmsDataAccessException(Code)

See Also:   org.opencms.db.I_CmsHistoryDriver.readProperties(org.opencms.db.CmsDbContextorg.opencms.file.history.I_CmsHistoryResource)



readPropertyDefinition
public CmsPropertyDefinition readPropertyDefinition(CmsDbContext dbc, String name) throws CmsDataAccessException(Code)

See Also:   org.opencms.db.I_CmsHistoryDriver.readPropertyDefinition(org.opencms.db.CmsDbContextjava.lang.String)



readPublishTag
public int readPublishTag(CmsDbContext dbc, long maxdate) throws CmsDataAccessException(Code)

See Also:   org.opencms.db.I_CmsHistoryDriver.readPublishTag(org.opencms.db.CmsDbContextlong)



readResource
public I_CmsHistoryResource readResource(CmsDbContext dbc, CmsUUID structureId, int version) throws CmsDataAccessException(Code)

See Also:   org.opencms.db.I_CmsHistoryDriver.readResource(CmsDbContextCmsUUIDint)



writePrincipal
public void writePrincipal(CmsDbContext dbc, I_CmsPrincipal principal) throws CmsDataAccessException(Code)

See Also:   org.opencms.db.I_CmsHistoryDriver.writePrincipal(CmsDbContextorg.opencms.security.I_CmsPrincipal)



writeProject
public void writeProject(CmsDbContext dbc, int publishTag, long publishDate) throws CmsDataAccessException(Code)

See Also:   org.opencms.db.I_CmsHistoryDriver.writeProject(org.opencms.db.CmsDbContextintlong)



writeProperties
public void writeProperties(CmsDbContext dbc, CmsResource resource, List properties, int publishTag) throws CmsDataAccessException(Code)

See Also:   org.opencms.db.I_CmsHistoryDriver.writeProperties(org.opencms.db.CmsDbContextorg.opencms.file.CmsResourcejava.util.Listint)



writeResource
public void writeResource(CmsDbContext dbc, CmsResource resource, List properties, int publishTag) throws CmsDataAccessException(Code)

See Also:   org.opencms.db.I_CmsHistoryDriver.writeResource(org.opencms.db.CmsDbContextorg.opencms.file.CmsResourcejava.util.Listint)



Methods inherited from java.lang.Object
native protected Object clone() throws CloneNotSupportedException(Code)(Java Doc)
public boolean equals(Object obj)(Code)(Java Doc)
protected void finalize() throws Throwable(Code)(Java Doc)
final native public Class getClass()(Code)(Java Doc)
native public int hashCode()(Code)(Java Doc)
final native public void notify()(Code)(Java Doc)
final native public void notifyAll()(Code)(Java Doc)
public String toString()(Code)(Java Doc)
final native public void wait(long timeout) throws InterruptedException(Code)(Java Doc)
final public void wait(long timeout, int nanos) throws InterruptedException(Code)(Java Doc)
final public void wait() throws InterruptedException(Code)(Java Doc)

www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.