org.databene.benerator.maven
Class DBSnapshotMojo

java.lang.Object
  extended by org.apache.maven.plugin.AbstractMojo
      extended by org.databene.benerator.maven.AbstractBeneratorMojo
          extended by org.databene.benerator.maven.DBSnapshotMojo
All Implemented Interfaces:
org.apache.maven.plugin.ContextEnabled, org.apache.maven.plugin.Mojo

public class DBSnapshotMojo
extends AbstractBeneratorMojo

Creates a database snapshot in DbUnit data file format.

Created: 09.07.2008 18:50:23

Since:
0.5.4
Author:
Volker Bergmann

Field Summary
protected  java.lang.String dbDriver
          The fully qualified name of the JDBC database driver.
protected  java.lang.String dbPassword
          The database password.
protected  java.lang.String dbSchema
          The database schema to use.
protected  java.lang.String dbUrl
          The JDBC database url.
protected  java.lang.String dbUser
          The database user name.
protected  java.lang.String snapshotDialect
          The database dialect to use in a snapshot file of SQL format.
protected  java.lang.String snapshotFilename
          The file name to use for the snapshot file.
protected  java.lang.String snapshotFormat
          The file format to use in the export file.
 
Fields inherited from class org.databene.benerator.maven.AbstractBeneratorMojo
encoding, runtimeClasspathElements, scope, testClasspathElements
 
Fields inherited from interface org.apache.maven.plugin.Mojo
ROLE
 
Constructor Summary
DBSnapshotMojo()
           
 
Method Summary
 void execute()
          'Main' method of the Mojo which calls the DbSnapshotTool using the pom's benerator configuration.
protected  void setSystemProperties()
          Maps all attributes to System properties of the same name.
 
Methods inherited from class org.databene.benerator.maven.AbstractBeneratorMojo
getClasspathElements, getClasspathURLs, setSystemProperty, setupClasspath
 
Methods inherited from class org.apache.maven.plugin.AbstractMojo
getLog, getPluginContext, setLog, setPluginContext
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

dbDriver

protected java.lang.String dbDriver
The fully qualified name of the JDBC database driver.


dbUrl

protected java.lang.String dbUrl
The JDBC database url.


dbUser

protected java.lang.String dbUser
The database user name.


dbPassword

protected java.lang.String dbPassword
The database password.


dbSchema

protected java.lang.String dbSchema
The database schema to use.


snapshotFormat

protected java.lang.String snapshotFormat
The file format to use in the export file. Available values: dbunit, sql, xls. If left blank, dbunit is used.


snapshotDialect

protected java.lang.String snapshotDialect
The database dialect to use in a snapshot file of SQL format. If left blank, the database's own dialect will be used.


snapshotFilename

protected java.lang.String snapshotFilename
The file name to use for the snapshot file. If left blank, 'export' + file type suffix is used.

Constructor Detail

DBSnapshotMojo

public DBSnapshotMojo()
Method Detail

setSystemProperties

protected void setSystemProperties()
Description copied from class: AbstractBeneratorMojo
Maps all attributes to System properties of the same name.

Overrides:
setSystemProperties in class AbstractBeneratorMojo

execute

public void execute()
'Main' method of the Mojo which calls the DbSnapshotTool using the pom's benerator configuration.



Copyright © 2010. All Rights Reserved.