Cayenne ships with Ant tasks that provide Ant frontend to a number of useful operations in Cayenne. These tasks are part of the cayenne-tools JAR. The following tasks are included:
- cgen - Java class generator
- cdbgen - Database schema generator
- cdeploy - Deployment configurator (deprecated; will be removed after 3.0)
- cdataport - Data porting tool.
- cdbimport - Database schema importer.
All Cayenne tasks above can be imported at once with "typedef". First a user needs to define Classpath structure to include cayenne-tools and a few depdendencies. Here they are shown relative to the Cayenne distro folder. In a real project they may be copied to the appropriate project folders and referenced accordingly:
And then import all tasks with "typedef", referencing Antlib descriptor in Cayenne: