|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object atg.nucleus.logging.VariableArgumentApplicationLoggingImpl atg.nucleus.GenericService atg.adapter.gsa.SQLProcessorEngine
public class SQLProcessorEngine
This class is designed to assist with database table manipulation such as adding tables. Parts copied from atg.service.idgen.?? by mgk
Field Summary | |
---|---|
static java.lang.String |
APACHE_DERBY
|
Fields inherited from class atg.nucleus.GenericService |
---|
CLASS_VERSION, SERVICE_INFO_KEY |
Fields inherited from interface atg.nucleus.logging.TraceApplicationLogging |
---|
DEFAULT_LOG_TRACE_STATUS |
Fields inherited from interface atg.nucleus.logging.ApplicationLogging |
---|
DEFAULT_LOG_DEBUG_STATUS, DEFAULT_LOG_ERROR_STATUS, DEFAULT_LOG_INFO_STATUS, DEFAULT_LOG_WARNING_STATUS |
Constructor Summary | |
---|---|
SQLProcessorEngine()
empty constructor |
|
SQLProcessorEngine(atg.adapter.gsa.GSARepository pRep)
Construct a generator |
Method Summary | |
---|---|
boolean |
createTables(java.util.List<java.lang.String> pStatements,
boolean pDrop)
This method is used to create tables in a database. |
void |
doStartService()
method to execute when starting this component |
void |
dropTablesFromCreateStatements(java.util.List<java.lang.String> pCreateStatements)
This method is used to iteratively drop tables. |
java.lang.String |
getCreateTableBeginDelimiter()
|
java.lang.String |
getCreateTableEndDelimiter()
|
java.lang.String |
getDetermineTableExistsSQL()
|
java.lang.String |
getDropTableSQL()
|
atg.adapter.gsa.GSARepository |
getRepository()
|
boolean |
isDerby()
Returns true if the current database is Apache Derby. |
void |
setCreateTableBeginDelimiter(java.lang.String pStr)
|
void |
setCreateTableEndDelimiter(java.lang.String pStr)
|
void |
setDetermineTableExistsSQL(java.lang.String pStr)
|
void |
setDropTableSQL(java.lang.String pStr)
|
void |
setRepository(atg.adapter.gsa.GSARepository pRep)
|
Methods inherited from class atg.nucleus.GenericService |
---|
addLogListener, createAdminServlet, doStopService, getAbsoluteName, getAdminServlet, getLoggingForVlogging, getLogListenerCount, getLogListeners, getName, getNameContext, getNucleus, getRoot, getServiceConfiguration, getServiceInfo, isLoggingDebug, isLoggingError, isLoggingInfo, isLoggingTrace, isLoggingWarning, isRunning, logDebug, logDebug, logDebug, logError, logError, logError, logInfo, logInfo, logInfo, logTrace, logTrace, logTrace, logWarning, logWarning, logWarning, nameContextElementBound, nameContextElementUnbound, removeLogListener, resolveName, resolveName, resolveName, resolveName, sendLogEvent, setLoggingDebug, setLoggingError, setLoggingInfo, setLoggingTrace, setLoggingWarning, setNucleus, setServiceInfo, startService, stopService |
Methods inherited from class atg.nucleus.logging.VariableArgumentApplicationLoggingImpl |
---|
vlogDebug, vlogDebug, vlogDebug, vlogDebug, vlogError, vlogError, vlogError, vlogError, vlogInfo, vlogInfo, vlogInfo, vlogInfo, vlogTrace, vlogTrace, vlogTrace, vlogTrace, vlogWarning, vlogWarning, vlogWarning, vlogWarning |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final java.lang.String APACHE_DERBY
Constructor Detail |
---|
public SQLProcessorEngine()
public SQLProcessorEngine(atg.adapter.gsa.GSARepository pRep)
Method Detail |
---|
public void setRepository(atg.adapter.gsa.GSARepository pRep)
public atg.adapter.gsa.GSARepository getRepository()
public void setDetermineTableExistsSQL(java.lang.String pStr)
public java.lang.String getDetermineTableExistsSQL()
public void setDropTableSQL(java.lang.String pStr)
public java.lang.String getDropTableSQL()
public void setCreateTableBeginDelimiter(java.lang.String pStr)
public java.lang.String getCreateTableBeginDelimiter()
public void setCreateTableEndDelimiter(java.lang.String pStr)
public java.lang.String getCreateTableEndDelimiter()
public void doStartService() throws atg.nucleus.ServiceException
doStartService
in class atg.nucleus.GenericService
atg.nucleus.ServiceException
public boolean createTables(java.util.List<java.lang.String> pStatements, boolean pDrop) throws SQLProcessorException
String
- pStr - the String containing the CREATE TABLE statementsboolean
- pDrop - indicates whether to drop tables and recreate them
if the tables already exist in the database
SQLProcessorException
- if an error occurs trying to create the tablespublic boolean isDerby() throws SQLProcessorException
SQLProcessorException
public void dropTablesFromCreateStatements(java.util.List<java.lang.String> pCreateStatements) throws SQLProcessorException
Vector
- of CREATE TABLE statements indicating which tables to drop
SQLProcessorException
- thrown if all tables can not be dropped
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |