You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@click.apache.org by Paul <pa...@kywb.uscourts.gov> on 2008/11/13 20:27:45 UTC

How to upgrade from Click version 1.4.2 to version 1.5 and build.xml source parameter

I downloaded Click 1.5 and did the following:

ant get-deps
ant build-all
ant project-quick-start

Following is a part of the build.xml that was created for the new application:

      <javac srcdir="src" 
             destdir="WebContent/WEB-INF/classes" 
             debug="true"
             encoding="ISO-8859-1"
             source="1.4">
         <classpath refid="classpath"/>
      </javac> 

Shouldn't the line 'source="1.4">' be 'source="1.5>"' or does it not make any
difference?

I looked at the instructions on the "Upgrade Path" web page, but it's not clear
to me which files need to be replaced before I recompile an application that was
created using Click 1.4.2.

Do I only need to replace "click-1.4.2.jar" and "click-extras-1.4.2.jar" in
folder "...\WebContent\Web-INF\lib" with "click-1.5.jar" and
"click-extras-1.5.jar"?  My application did build okay, but are there other
changes that should be made?

Thanks,
Paul


Re: How to upgrade from Click version 1.4.2 to version 1.5 and build.xml source parameter

Posted by Bob Schellink <sa...@gmail.com>.
Hi Paul,


Paul wrote:
> 
> Shouldn't the line 'source="1.4">' be 'source="1.5>"' or does it not make any
> difference?


source=1.4 refers to the Java version, not Click. If you are running 
under JDK5 or JDK6 you can change that to source="1.5" or 1.6. You can 
even remove the source attribute :)


> I looked at the instructions on the "Upgrade Path" web page, but it's not clear
> to me which files need to be replaced before I recompile an application that was
> created using Click 1.4.2.
> 
> Do I only need to replace "click-1.4.2.jar" and "click-extras-1.4.2.jar" in
> folder "...\WebContent\Web-INF\lib" with "click-1.5.jar" and
> "click-extras-1.5.jar"?  My application did build okay, but are there other
> changes that should be made?


Yep just replace the jars with the new ones. If your app compiles, you 
should be good to go. The one tricky area of upgrading is if you 
created custom components and overrode the toString() method. In those 
cases you'll need to move that logic to the *render* method as indicated.

That should be it really.

kind regards

bob