Thank you very much for your response Paul,

     At the end I created a Java class to launch my jelly script inside it.

     I have applied the suggested change and it works, but now I have 
encountered another problemm:
     - when I launch jelly from my java programm it works fine
     - when I launch jelly using JellyTask, some classes used inside jelly 
script are not found (for example 
org.apache.commons.jelly.tags.log.LogTagLibrary or other classes developed by 
myself). I know that it is something related with the classpath used in the 
jelly tag but I don't know if it is possible to specify the classpath in an 
attribute or something like that.

     - Snippets:
          - The script works fine 
              <target name="main">
                 <java classname="com.ejie.jelly.Launcher" 
classpathref="project.class.path">
                    <arg value="value1"/>
                    <arg value="value2"/>
                    <arg value="value3"/>
                 </java>
              </target>

          - The script doesn't fine some classes inside the script
              <taskdef name="jelly"
                  classname="org.apache.commons.jelly.task.JellyTask"
                  classpathref="project.class.path"/>
              <target name="main">
                  <jelly script="d:\tools\jelly\transformFile.jelly" />
              </target>  

Best Regards,
     Oscar Guadilla

----- Original Message -----
From: "Paul Libbrecht" <[EMAIL PROTECTED]>
To: "Jakarta Commons Users List" <[email protected]>
Subject: Re: Ant + Jelly
Date: Tue, 22 Feb 2005 20:55:18 +0100

> 
> Hi Oscar,
> 
> Sorry to answer so late... just change typedef into taskdef...
> maybe you've done it already...
> 
> paul
> 
> 
> 
> Le 18 f�vr. 05, � 19:16, Oscar Guadilla a �crit :
> 
> > Good afternoon,
> >
> >     I have an application building procedure which is based on 
> > ant. It is fine but it is a language a bit limited (loop, if 
> > clause...). I have played a bit with Maven which supports Jelly 
> > and I think it is very powerfull and that's why I have decided to 
> > choose jelly to solve my problemm, but I am encountering a 
> > problemm I don't know how to solve:
> >
> >     - ant script
> >    <typedef name="jelly"
> >         classname="org.apache.commons.jelly.task.JellyTask"
> >         classpath="${classpath}"/>
> >    <target name="jelly_integ">
> >       <echo message="Hello from inside Ant"/>
> >       <jelly 
> > script="/usr/j2se/jakarta-ant-1.5.3-1/jelly/transformFile.jelly"/>
> >    </target>
> >
> >     - jelly script
> > <?xml version="1.0"?>
> > <j:jelly trim="false" xmlns:j="jelly:core" xmlns:x="jelly:xml" 
> > xmlns:html="jelly:html" xmlns:ant="jelly:ant" >
> >      <ant:echo>Hello from inside Jelly</ant:echo>
> > </j:jelly>
> >
> >     - standard output
> >     jelly_integ:
> >       [echo] Hello from inside Ant
> >     BUILD SUCCESSFUL
> >
> >     - debug output
> >     jelly_integ:
> >      [echo] Hello from inside Ant
> >      Class java.io.File loaded from parent loader
> >      Class java.net.URL loaded from parent loader
> >      Finding class org.apache.commons.jelly.XMLOutput
> >      Class org.xml.sax.ContentHandler loaded from parent loader
> >      Class org.xml.sax.ext.LexicalHandler loaded from parent loader
> >      Class org.apache.commons.jelly.XMLOutput loaded from ant loader
> >      Finding class org.apache.commons.jelly.XMLOutput$1
> >      Class org.apache.commons.jelly.XMLOutput$1 loaded from ant loader
> >      Class java.lang.NullPointerException loaded from parent loader
> >      Class org.xml.sax.Attributes loaded from parent loader
> >      Class org.apache.tools.ant.Project loaded from parent loader
> >      BUILD SUCCESSFUL
> >      Total time: 6 seconds
> >
> >
> >     Any idea why doesn't apper Hello from inside Jelly? What am I 
> > doing wrong?
> >
> > Thank you very much for your help,
> >     Oscar Guadilla
> > -- ___________________________________________________________
> > Sign-up for Ads Free at Mail.com
> > http://promo.mail.com/adsfreejump.htm
> >
> >
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > For additional commands, e-mail: [EMAIL PROTECTED]
> >
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]

-- 
___________________________________________________________
Sign-up for Ads Free at Mail.com
http://promo.mail.com/adsfreejump.htm



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to