Java Mailing List Archive

http://www.ant-tasks.com/

Home » Ant Users List »

Nested type as an Integer

Mansour Al Akeel

2012-01-10


Author LoginPost Reply
In a custom task, I need to use a nested element to set the port number.
The nested element looks like this:

<c:myCustomTask>
<port>9090</port>
<context>myApplication</context>
</c:myCustomTask>

The problem I am getting is:

build.xml:76: class java.lang.String doesn't support nested text data
("myApplication").

at
org.apache.tools.ant.IntrospectionHelper.addText (IntrospectionHelper.java:464)
    at
org.apache.tools.ant.ProjectHelper.addText (ProjectHelper.java:384)
    at
org.apache.tools.ant.RuntimeConfigurable.maybeConfigure (RuntimeConfigurable.java:413)
    at
org.apache.tools.ant.RuntimeConfigurable.maybeConfigure (RuntimeConfigurable.java:344)


And the same thing for the port.What type of objects I need to use to set
these values ?
Thank you.
©2008 ant-tasks.com - Jax Systems, LLC, U.S.A.