Getting started > How to run it? > The Integration into Ant > The Jacson Ant Task | 2005-10-04 00:11:20 v0.90 | |
Jacson, say Jackson, think J-ScanThe Jacson Ant Task |
Download Jacson | Sourceforge Project Summary | Jacson Home | SourceForge Home |
What is Jacson? Getting started Download instructions How to install? Configuration How to run it? The Commandline The Integration into Ant The Jacson Ant Task Embed in a Java Program How it works? Contact How to Contribute? Developer Information Other information |
DescriptionProcess a set of documents with the Jacson engine.
This tasks depends on jar files not included in
Ant distribution. You need at least <taskdef name="jacson" classname="de.spieleck.app.jacson.ant.JacsonTask"/>You might use optional classpath attributes or elements to load Jacson from a special classpath. Below documentation (as well as the task itself) contains quoted material from the Ant Core task Style. It is possible to refine the set of files that are being processed. This can be done with the includes, includesfile, excludes, excludesfile and defaultexcludes attributes. With the includes or includesfile attribute you specify the files you want to have included by using patterns. The exclude or excludesfile attribute is used to specify the files you want to have excluded. This is also done with patterns. And finally with the defaultexcludes attribute, you can specify whether you want to use default exclusions or not. See the section on directory based tasks, on how the inclusion/exclusion of files works, and how to write patterns. This task forms an implicit FileSet and supports all attributes of <fileset> (dir becomes basedir) as well as the nested <include>, <exclude> and <patternset> elements. This task is aware of the surrounding Ant environment: Ant properties are mapped into <se:param/> parameters in the Jacson configuration. An <se:param/> in a Jacson configuration will actually create the corresponding property in the Ant project. This task supports the use of nested <param/> elements which set values in an <se:param/> declaration. <param/> elements override values of properties with the same name and disable Jacson from overriding the corresponding property in the Ant project.
ParametersJacsonTask is a subclass of Ant's MatchingTask and can work on complex filesets. These should be described elsewhere in the Ant documentation.
Nested Elementsdirectory basedparamParam is used to pass a <se:param/> parameters to the Jacson configuration. param Parameters
Examples
This example uses the Jacson configuration <target name="topfilter"> <jacson config="head.conf" out="topfilter.properties" in="data/access.log.gz" /> </target>If head.conf used Jacsons PrintingReport
then subsequent ant task can refer to the results of Jacson by
reading the topfilter.properties file.
This uses the <target name="demo1" depends="taskdemo-prepare"> <jacson config="loganalysis.conf"> <include name="logfiles/**"/> </jacson> </target>Since no <out> is specified the output files are controlled by the configuration. It might still be controlled by Ant properties which map to parameters in the configuration. | ||||||||||||||||||||||||||||||||||||||||||||||||||
| |||||||||||||||||||||||||||||||||||||||||||||||||||
top |