Hi,
I am developing a plugin and have some trouble in debugging my plugin.jelly
script
Can any one suggest how to develop maven script in an easy way and also how
to debug them?
Example:
1. Getting the schema or dtd for the jelly and maven tags ?
2. List all the properties in the context from project.properties etc ?
3. Examples in using jelly tags, like a tutorial or samples ?
Ps.
One technique I am using is when perhaps I want to debug the part below
<ant:wtkjad autoversion="{maven.j2me.jad.autoversion}"
jadfile="${maven.build.dir}/${pom.artifactId}.jad"
jarfile="${maven.build.dir}/${pom.artifactId}.jar"
name="${suitename}"
update="update"
vendor="${vendor}"
version="${version}">
<j:forEach items="${midlets}" var="midlet">
<x:set select="$midlet.name" var="name"/>
<j:if test="${empty (name)}">
<fail message="Name attribute must be "/>
</j:if>
<x:set select="$midlet.class" var="class"/>
<j:if test="${empty (class)}">
<fail message="Class attribute must be set!"/>
</j:if>
<x:set select="$midlet.icon" var="icon"/>
< ant:midlet class="${class}" icon="${icon}" name="${name}"/>
</j:forEach>
<j:forEach items="${attributes}" var="attribute">
<x:set select="$attribute.name" var="name"/>
<j:if test="${empty (name)}">
<fail message="Name attribute must be set!"/>
</j:if>
<ant:attribute name="${attribute.name}"
value="${attribute.value}"/>
</j:forEach>
</ant:wtkjad>
You can "switch on/off" the different part of the scripts by renaming the
xmlns spaces in order to
see the results of the different jelly tag types.
Example: by renaming
xmlns:ant="jelly:ant"
to
xmlns:ant="tmp_jelly:ant"
and put the above code between <echo></echo> you can see the ant script that
is dynamically generated
by the j and x jelly tags. Example echo out:
<ant:wtkjad
autoversion="false"
jarfile="C:\java\javasoft\wtk_midp2.1\apps\example/target/example.jar"
jadfile="C:\java\javasoft\wtk_midp2.1\apps\example/target/ example.jad"
update="update">
<midlet class="com.xdin.mobilitet.Example" icon=""
name="ExamlpeDemo"></midlet>
<attribute value="http://localhost/example/example.jsp"
name="SERVERURL"></attribute>
<attribute value="my_value" name="my_key"></attribute>
</ant:wtkjad>
The same can be done wirh j and x.