persistence
Class AbstractSQLFactoryImpl

java.lang.Object
  extended bypersistence.AbstractSQLFactoryImpl
All Implemented Interfaces:
AbstractSQLFactory

public class AbstractSQLFactoryImpl
extends java.lang.Object
implements AbstractSQLFactory

Implementatie van AbstractSQLFactory.

Author:
bram 16-okt-2003

Nested Class Summary
 
Nested classes inherited from class persistence.AbstractSQLFactory
AbstractSQLFactory.Registry, AbstractSQLFactory.TreeInfo
 
Field Summary
private  java.lang.String connectionExpression
           
private  java.lang.String fullPrincipalClassName
           
private  TableComponent persistenceTree
           
private static persistence.script.DBScript script
           
 
Fields inherited from interface persistence.AbstractSQLFactory
registry
 
Constructor Summary
AbstractSQLFactoryImpl(org.w3c.dom.Node involvedNode, java.lang.String fullPrincipalClassName, java.lang.String connectionExpression)
           
 
Method Summary
 void addToScript()
          Adds this class's create/drop code to script.
static void createScript()
           
 java.lang.String getCreateStatement(java.lang.String dialectVariableName)
          One has to establish a Connection named conn, and to catch Exceptions.
 java.lang.String getDeleteStatement()
          Create String with all needed statements for deletion of object whose persistence properties are described in NodeList.
 java.lang.String getDropStatement(java.lang.String dialectVariableName)
          One has to establish a Connection named conn, and to catch Exceptions.
 java.lang.String getInsertStatement()
          Create String with all needed statements for insertion of object whose persistence properties are described in NodeList.
private  java.lang.String getQueryCompTypeStatement()
           
private  java.lang.String getQueryJoinStatement()
           
private  java.lang.String getQueryRegisterStatement()
           
 java.lang.String getQueryStatements()
           
 java.lang.String getReadStatement()
          Create String with all needed statements for reading object whose persistence properties are described in NodeList.
 java.lang.String getUpdateStatement()
          Create String with all needed statements for update of object whose persistence properties are described in NodeList.
static void setAllClassesToPersist(java.util.Collection coll)
          coll contains all classes which will have to be persisted.
 void setCurrentNodeList(org.w3c.dom.Node node, java.lang.String fullPrincipalClassName)
          Sets a NodeList of <persistentClass>-elements as the current one and extraction of useful info happens.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

persistenceTree

private TableComponent persistenceTree

fullPrincipalClassName

private java.lang.String fullPrincipalClassName

connectionExpression

private java.lang.String connectionExpression

script

private static persistence.script.DBScript script
Constructor Detail

AbstractSQLFactoryImpl

public AbstractSQLFactoryImpl(org.w3c.dom.Node involvedNode,
                              java.lang.String fullPrincipalClassName,
                              java.lang.String connectionExpression)
                       throws CompTypeRequiredException,
                              MissingContentTagException
Method Detail

setAllClassesToPersist

public static void setAllClassesToPersist(java.util.Collection coll)
coll contains all classes which will have to be persisted. This is needed for inheritance checks.


setCurrentNodeList

public void setCurrentNodeList(org.w3c.dom.Node node,
                               java.lang.String fullPrincipalClassName)
                        throws CompTypeRequiredException,
                               MissingContentTagException
Sets a NodeList of <persistentClass>-elements as the current one and extraction of useful info happens.

Specified by:
setCurrentNodeList in interface AbstractSQLFactory
Parameters:
node -
fullPrincipalClassName -
Throws:
CompTypeRequiredException
MissingContentTagException

getInsertStatement

public java.lang.String getInsertStatement()
Description copied from interface: AbstractSQLFactory
Create String with all needed statements for insertion of object whose persistence properties are described in NodeList.

Specified by:
getInsertStatement in interface AbstractSQLFactory
Returns:
See Also:
persistence.AbstractSQLFactory#getInsertStatement(String)

getReadStatement

public java.lang.String getReadStatement()
Description copied from interface: AbstractSQLFactory
Create String with all needed statements for reading object whose persistence properties are described in NodeList.

Specified by:
getReadStatement in interface AbstractSQLFactory
Returns:
See Also:
persistence.AbstractSQLFactory#getReadStatement(String)

getUpdateStatement

public java.lang.String getUpdateStatement()
Description copied from interface: AbstractSQLFactory
Create String with all needed statements for update of object whose persistence properties are described in NodeList.

Specified by:
getUpdateStatement in interface AbstractSQLFactory
Returns:

getDeleteStatement

public java.lang.String getDeleteStatement()
Description copied from interface: AbstractSQLFactory
Create String with all needed statements for deletion of object whose persistence properties are described in NodeList.

Specified by:
getDeleteStatement in interface AbstractSQLFactory
Returns:

getCreateStatement

public java.lang.String getCreateStatement(java.lang.String dialectVariableName)
One has to establish a Connection named conn, and to catch Exceptions.

Specified by:
getCreateStatement in interface AbstractSQLFactory
Parameters:
dialectVariableName -
Returns:
See Also:
AbstractSQLFactory.getCreateStatement(String)

getDropStatement

public java.lang.String getDropStatement(java.lang.String dialectVariableName)
One has to establish a Connection named conn, and to catch Exceptions.

Specified by:
getDropStatement in interface AbstractSQLFactory
Parameters:
dialectVariableName -
Returns:
See Also:
AbstractSQLFactory.getDropStatement(String)

createScript

public static void createScript()

addToScript

public void addToScript()
Description copied from interface: AbstractSQLFactory
Adds this class's create/drop code to script.

Specified by:
addToScript in interface AbstractSQLFactory

getQueryJoinStatement

private java.lang.String getQueryJoinStatement()

getQueryRegisterStatement

private java.lang.String getQueryRegisterStatement()

getQueryCompTypeStatement

private java.lang.String getQueryCompTypeStatement()

getQueryStatements

public java.lang.String getQueryStatements()
Specified by:
getQueryStatements in interface AbstractSQLFactory
See Also:
AbstractSQLFactory.getQueryStatements()