You also could use the AntLib-Props.
There is no official release, but you could use the CI-build.
https://builds.apache.org/view/All/job/AntLib-props/lastSuccessfulBuild/artifact/distribution/binaries/
For usage you should have a look at the unit tests
https://git-wip-us.apache.org/repos/asf?p=an
Use
Jan
${time}
* inheritall="false" *
* inheritall="true" *
${nr}: ${time}
-Ursprüngliche N
Main problem was having the nested classes as 'static.
Jan
import java.util.ArrayList;
import java.util.List;
import org.apache.tools.ant.Project;
import org.apache.tools.ant.Task;
import org.apache.tools.ant.types.DataType;
public class MyTask extends Task {
// Hold a list of real Things-
Jan,
Thanks for the help.
Following your suggestion, this is what I have:
public class MyTask extends Task {
private String a;
private String b;
private List things = new ArrayList();
public void execute() {
for (String t : things)
System.out.println (t)
You have several things:
- add to
class MyTask extends Task { addThings(Things t)
- add to
class Things extends DataType { addThing(Thing t)
- add text to
class Thing extends DataType { addText(String t)
For documentation:
* Tutorial about writing tasks
http://ant.apache.org/manual/t
Problem solved.
I just have to delete the default attribute.
thx thx thx. now everything works fine i hope
Tamer Demirel schrieb:
Thx very much. Exactly what i need.
Just one question.
I become a failure:
Target dist does not exist in the project.
But everything works fine? Can i ignore this
Thx very much. Exactly what i need.
Just one question.
I become a failure:
Target dist does not exist in the project.
But everything works fine? Can i ignore this???
Thx,
Tamer
jan.mate...@rzf.fin-nrw.de schrieb:
Short build file for starting point
Short build file for starting point
Jan
>-Ursprüngliche Nachricht-
>Von: Tamer Demirel [mailto:demi...@in.tum.de]
>Gesendet: Donnerstag, 17. Dezember 2009 11:11
>An: Ant Users List
>Betreff: Re: Question ant script --> extract RAR-File
>I am trying to use the clearcase
>org.apache.tools.ant.taskdefs.optional.clearcase.CCCheckout tool and I
>get a null pointer error on line 43 "ckout.execute();". The code is
>attached below.
>
>
>
>Here is the Exception:
>
>
>
>Exception in thread "main" java.lang.NullPointerException
>
>
You could write a which takes the arguments and implements the
"standard" rest.
With AntContrib you could do a loop over lists.
Jan
> -Ursprüngliche Nachricht-
> Von: Duhra, Sarab Singh [mailto:[EMAIL PROTECTED]
> Gesendet: Freitag, 29. August 2008 00:28
> An: user@ant.apache.org
>
H a simple
@
works for me ...
In you have to mask the @ sign because it's starting the reference
to an attribute name.
@{foo} prints value of attribute foo
@@ prints simple at-sign
Jan
>-Ursprüngliche Nachricht-
>Von: Rebhan
I would write a custom task which stores the listener-adresses as property.
Inside your code you could reuse the Ant classes if you need ...
(oata.taskdefs, oata.util)
Jan
...
class GetOracleListenerTask extends Task {
String property; // setter
public execute() {
List
Because extends this example from the manual should help
zips all files in the htdocs/manual directory into the docs/user-guide
directory in
the archive, adds the file ChangeLog27.txt in the current directory as
docs/ChangeLog.txt, and includes all the html files i
>I want to exclude a package, common, in my java application
>and then execute javancss from ant.
>
>How can I exclude the common package in my source tree and
>then run my javancss.
>
-
+
Jan
-
We have a build.bat in our source distro, but this only for building Ant itself.
For building your own projects you dont need that file. Just start Ant with
your buildfile
ProjectDir> ant -f myBuildFile.xml
or with common buildfile name build.xml
ProjectDir> ant
Why do you think you need that
?
Jan
> -Ursprüngliche Nachricht-
> Von: rakesh mailgroups [mailto:[EMAIL PROTECTED]
> Gesendet am: Dienstag, 15. März 2005 11:38
> An: Ant Users List
> Betreff: question
>
> Hi,
>
> I would like my build file to abort if a file does not exist.
>
> I couldn't find a way to find out if
16 matches
Mail list logo