Package org.dbunit.ant
Class AbstractStep
java.lang.Object
org.apache.tools.ant.ProjectComponent
org.dbunit.ant.AbstractStep
- All Implemented Interfaces:
Cloneable,DbUnitTaskStep
public abstract class AbstractStep
extends org.apache.tools.ant.ProjectComponent
implements DbUnitTaskStep
- Since:
- 2.1 (Apr 3, 2004)
- Version:
- $Revision$ $Date$
- Author:
- Manuel Laflamme, Last changed by: $Author$
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final StringFields inherited from class org.apache.tools.ant.ProjectComponent
description, location, project -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected voidcheckDataFormat(String format) Checks if the given data format is a valid one according to the methodisDataFormat(String).protected IDataSetgetDatabaseDataSet(IDatabaseConnection connection, List tables) static InputSourcegetInputSource(File file) Creates and returns anInputSourceprotected IDataSetgetSrcDataSet(File src, String format, boolean forwardonly) booleanisDataFormat(String format) Checks if the given format is a format which contains tabular data.booleanvoidsetOrdered(boolean ordered) toString()Methods inherited from class org.apache.tools.ant.ProjectComponent
clone, getDescription, getLocation, getProject, log, log, setDescription, setLocation, setProjectMethods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface org.dbunit.ant.DbUnitTaskStep
execute, getLogMessage
-
Field Details
-
FORMAT_FLAT
- See Also:
-
FORMAT_XML
- See Also:
-
FORMAT_DTD
- See Also:
-
FORMAT_CSV
- See Also:
-
FORMAT_XLS
- See Also:
-
FORMAT_YML
- See Also:
-
-
Constructor Details
-
AbstractStep
public AbstractStep()
-
-
Method Details
-
getDatabaseDataSet
protected IDataSet getDatabaseDataSet(IDatabaseConnection connection, List tables) throws DatabaseUnitException - Throws:
DatabaseUnitException
-
getSrcDataSet
protected IDataSet getSrcDataSet(File src, String format, boolean forwardonly) throws DatabaseUnitException - Throws:
DatabaseUnitException
-
isDataFormat
Checks if the given format is a format which contains tabular data.- Parameters:
format- The format to check- Returns:
trueif the given format is a data format. A data format is a format which holds tabular data that can be loaded via dbunit. An example for a data format is "xml" or "flat". A non-data format is "dtd" which holds only metadata information.- Since:
- 2.4
-
checkDataFormat
Checks if the given data format is a valid one according to the methodisDataFormat(String). If it is not anIllegalArgumentExceptionis thrown.- Parameters:
format- The format to check- Throws:
IllegalArgumentException- If the given format is not a valid data format- Since:
- 2.4
-
getInputSource
Creates and returns anInputSource- Parameters:
file- The file for which anInputSourceshould be created- Returns:
- The input source for the given file
- Throws:
MalformedURLException
-
isOrdered
public boolean isOrdered() -
setOrdered
public void setOrdered(boolean ordered) -
toString
-