|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.tools.ant.ProjectComponent
org.apache.tools.ant.Task
org.apache.ddlutils.task.DatabaseTaskBase
Base class for DdlUtils Ant tasks that operate on a database.
| Field Summary |
| Fields inherited from class org.apache.tools.ant.Task |
description, location, target, taskName, taskType, wrapper |
| Fields inherited from class org.apache.tools.ant.ProjectComponent |
project |
| Constructor Summary | |
DatabaseTaskBase()
|
|
| Method Summary | |
protected void |
addCommand(Command command)
Adds a command. |
void |
addConfiguredDatabase(org.apache.commons.dbcp.BasicDataSource dataSource)
Adds the data source to use for accessing the database. |
void |
execute()
|
protected void |
executeCommands(Database model)
Executes the commands. |
protected Iterator |
getCommands()
Returns the commands. |
String |
getDatabaseType()
Returns the database type. |
org.apache.commons.dbcp.BasicDataSource |
getDataSource()
Returns the data source. |
protected Platform |
getPlatform()
Creates the platform for the configured database. |
protected boolean |
hasCommands()
Determines whether there are commands to perform. |
boolean |
isUseDelimitedSqlIdentifiers()
Determines whether delimited SQL identifiers shall be used (the default). |
protected abstract Database |
readModel()
Reads the database model on which the commands will work. |
void |
setDatabaseType(String type)
Sets the database type. |
void |
setUseDelimitedSqlIdentifiers(boolean useDelimitedSqlIdentifiers)
Specifies whether delimited SQL identifiers shall be used. |
| Methods inherited from class org.apache.tools.ant.Task |
getDescription, getLocation, getOwningTarget, getRuntimeConfigurableWrapper, getTaskName, getTaskType, getWrapper, handleErrorFlush, handleErrorOutput, handleFlush, handleInput, handleOutput, init, isInvalid, log, log, maybeConfigure, perform, reconfigure, setDescription, setLocation, setOwningTarget, setRuntimeConfigurableWrapper, setTaskName, setTaskType |
| Methods inherited from class org.apache.tools.ant.ProjectComponent |
getProject, setProject |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
public DatabaseTaskBase()
| Method Detail |
public String getDatabaseType()
public void setDatabaseType(String type)
type - The database typepublic org.apache.commons.dbcp.BasicDataSource getDataSource()
public void addConfiguredDatabase(org.apache.commons.dbcp.BasicDataSource dataSource)
dataSource - The data sourcepublic boolean isUseDelimitedSqlIdentifiers()
true if delimited SQL identifiers shall be usedpublic void setUseDelimitedSqlIdentifiers(boolean useDelimitedSqlIdentifiers)
useDelimitedSqlIdentifiers - true if delimited SQL identifiers shall be usedprotected void addCommand(Command command)
command - The commandprotected boolean hasCommands()
true if there are commandsprotected Iterator getCommands()
protected Platform getPlatform()
protected abstract Database readModel()
protected void executeCommands(Database model)
throws org.apache.tools.ant.BuildException
model - The database model
org.apache.tools.ant.BuildException
public void execute()
throws org.apache.tools.ant.BuildException
org.apache.tools.ant.BuildException
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||