org.mmbase.storage.implementation.database
Class RelationalDatabaseStorageManager

java.lang.Object
  extended by org.mmbase.storage.implementation.database.DatabaseStorageManager
      extended by org.mmbase.storage.implementation.database.RelationalDatabaseStorageManager
All Implemented Interfaces:
StorageManager<DatabaseStorageManagerFactory>
Direct Known Subclasses:
PostgresqlLargeObjectStorageManager

public class RelationalDatabaseStorageManager
extends DatabaseStorageManager

A JDBC implementation of a storage manager for relational databases.

Since:
MMBase-1.7
Version:
$Id: RelationalDatabaseStorageManager.java 40659 2010-01-21 14:56:30Z michiel $
Author:
Pierre van Rooden
Javadoc:

Nested Class Summary
 
Nested classes/interfaces inherited from class org.mmbase.storage.implementation.database.DatabaseStorageManager
DatabaseStorageManager.InputStreamBlob
 
Field Summary
 
Fields inherited from class org.mmbase.storage.implementation.database.DatabaseStorageManager
activeConnection, changes, factory, inTransaction, OBJ2TYPE_MAX_SIZE, sequenceKeys, transactionIsolation, typeCache
 
Constructor Summary
RelationalDatabaseStorageManager()
           
 
Method Summary
 void change(MMObjectNode node, MMObjectBuilder builder)
          Changes a node in the passed builder and all its parent builders
 void create(MMObjectNode node, MMObjectBuilder builder)
          Adds a node to the passed builder and all its parent builders.
 void delete(MMObjectNode node, MMObjectBuilder builder)
          Deletes a node in the passed builder and all its parent builders.
 double getVersion()
          Returns the version of this factory implementation.
protected  void simpleCreate(MMObjectNode node, MMObjectBuilder builder)
          Actual implementation of create(MMObjectNode, MMObjectBuilder) which wraps this in a transction only, now.
protected  boolean tablesInheritFields()
          Returns whether tables inherit fields form parent tables.
 
Methods inherited from class org.mmbase.storage.implementation.database.DatabaseStorageManager
addToTableNameCache, appendDirectory, appendField, beginTransaction, change, change, change, change, checkFile, commit, commitChange, convertLegacyBinaryFiles, create, create, create, create, create, create, createIndex, createIndices, createKey, createSequence, createTable, delete, delete, delete, delete, delete, deleteIndices, executeQuery, executeUpdate, executeUpdateCheckConnection, exists, exists, exists, exists, exists, fillNode, getActiveConnection, getBinaryFile, getBinaryValue, getBlobFromDatabase, getBlobValue, getBlobValue, getBlobValue, getBooleanValue, getConstraintDefinition, getDateTimeValue, getFactory, getFieldDefinition, getFieldList, getFieldTypeDefinition, getInputStreamValue, getJDBCtoField, getLogStartTime, getNode, getNodeType, getStringValue, getStringValue, getValue, getXMLValue, init, isBinaryColumnType, isNull, isPartOfBuilderDefinition, isVerified, logQuery, refresh, releaseActiveConnection, rollback, setBinaryValue, setBooleanValue, setDateTimeValue, setDecimalValue, setListValue, setNodeType, setNodeTypeLeaveRelations, setNodeTypeRememberRelations, setNodeValue, setNullValue, setNumericValue, setStringValue, setValue, setXMLValue, shorten, size, size, storeBinaryAsFile, unloadShortedFields, verify, verifyTables
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

RelationalDatabaseStorageManager

public RelationalDatabaseStorageManager()
Method Detail

getVersion

public double getVersion()
Description copied from interface: StorageManager
Returns the version of this factory implementation. The factory uses this number to verify whether it can handle storage configuration files that list version requirements.

Specified by:
getVersion in interface StorageManager<DatabaseStorageManagerFactory>
Overrides:
getVersion in class DatabaseStorageManager
Returns:
the version as an integer

tablesInheritFields

protected boolean tablesInheritFields()
Description copied from class: DatabaseStorageManager
Returns whether tables inherit fields form parent tables. this determines whether fields that are inherited in mmbase builders are redefined in the database tables.

Overrides:
tablesInheritFields in class DatabaseStorageManager
Returns:
tables inherit fields form parent tables

simpleCreate

protected void simpleCreate(MMObjectNode node,
                            MMObjectBuilder builder)
                     throws StorageException
Actual implementation of create(MMObjectNode, MMObjectBuilder) which wraps this in a transction only, now.

Throws:
StorageException
Since:
MMBase-1.9.1

create

public void create(MMObjectNode node,
                   MMObjectBuilder builder)
            throws StorageException
Adds a node to the passed builder and all its parent builders.

Overrides:
create in class DatabaseStorageManager
Parameters:
node - The node to insert. The node already needs to have a (new) number assigned
builder - the builder to store the node
Throws:
StorageException - if an error occurred during creation

change

public void change(MMObjectNode node,
                   MMObjectBuilder builder)
            throws StorageException
Changes a node in the passed builder and all its parent builders

Overrides:
change in class DatabaseStorageManager
Parameters:
node - The node to change
builder - the builder to change the node in
Throws:
StorageException - if an error occurred during change

delete

public void delete(MMObjectNode node,
                   MMObjectBuilder builder)
            throws StorageException
Deletes a node in the passed builder and all its parent builders.

Overrides:
delete in class DatabaseStorageManager
Parameters:
node - The node to delete
builder - the builder to delete the node in
Throws:
StorageException - if an error occurred during delete


MMBase 2.0-SNAPSHOT - null