Java Forums

Main Menu
Home
Today's Posts
FAQ
Search
Contact Us

Java Network
Linux Archive
Java Tips
Java Tips Blog

Sponsored Links





Welcome to the Java Forums.

You are currently viewing our boards as a guest which gives you limited access to view most discussions and access our other features. By joining our free community, you will:

  • have access to post topics
  • communicate privately with other members (PM)
  • not see advertisements between posts
  • have the possibility to earn one of our surprises if you are an active member
  • access many other special features that will be introduced later.

Registration is fast, simple and absolutely free so please, join our community today!

If you have any problems with the registration process or your account login, please contact us.

Reply
 
LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 06-22-2007, 06:00 PM
Senior Member
 
Join Date: Jun 2007
Posts: 111
Eric is on a distinguished road
Problems with Eclipse and MyEclipse
Hello, I write to ask if somebody knows the way to configurate MyEclipse with Tomcat 5, to execute Servlets and JSPs altogether, but in addition takes into a Java Project (with Classes, Beans, Exceptions).

Eric
Bookmark Post in Technorati
Reply With Quote
Sponsored Links
  #2 (permalink)  
Old 07-05-2007, 10:10 PM
Senior Member
 
Join Date: Jun 2007
Posts: 114
Albert is on a distinguished road
In the first place you must observe that the versions are compatible.

The eclipse that I recommend to you is 3.1.2 version download it, and then configure the JRE. (C:\Program Files\Java\jdk1.5 .0_01 \ jre), it must be the same one of the tomcat (I used jakarta-tomcat-5.5.9.exe version), is configured when tomcat5 installs. Finally you must construct build.xml and do deploy…

this is an example

Code:
<project name="out0" basedir="../" default="copywar"> <!-- Project settings --> <property name="project.distname" value="out0"/> <!-- Local system paths --> <property file="${basedir}/ant/build.properties"/> <property name="webroot.dir" value="${basedir}/WebContent"/> <property name="webinf.dir" value="${webroot.dir}/WEB-INF"/> <property name="build.dir" value="build"/> <!-- classpath for JSF 1.0 --> <path id="compile.classpath"> <pathelement path ="${webinf.dir}/lib/commons-beanutils.jar"/> <pathelement path ="${webinf.dir}/lib/commons-collections.jar"/> <pathelement path ="${webinf.dir}/lib/commons-digester.jar"/> <pathelement path ="${webinf.dir}/lib/commons-logging.jar"/> <pathelement path ="${webinf.dir}/lib/jsf-api.jar"/> <pathelement path ="${webinf.dir}/lib/jsf-impl.jar"/> <pathelement path ="${webinf.dir}/lib/jstl.jar"/> <pathelement path ="${webinf.dir}/lib/standard.jar"/> <pathelement path ="${webinf.dir}/classes"/> <pathelement path ="${classpath.external}"/> <pathelement path ="${classpath}"/> </path> <!-- define your folder for deployment --> <property name="deploy.dir" value="deploy"/> <!-- Local system paths --> <property file="${basedir}/ant/build.properties"/> <property name="webroot.dir" value="${basedir}/WebContent"/> <property name="webinf.dir" value="${webroot.dir}/WEB-INF"/> <property name="build.dir" value="build"/> <!-- Check timestamp on files --> <target name="prepare"> <tstamp/> </target> <!-- Copy any resource or configuration files --> <target name="resources"> <copy todir="${webinf.dir}/classes" includeEmptyDirs="no"> <fileset dir="JavaSource"> <patternset> <include name="**/*.conf"/> <include name="**/*.properties"/> <include name="**/*.xml"/> </patternset> </fileset> </copy> </target> <!-- Normal build of application --> <target name="compile" depends="prepare,resources"> <javac srcdir="JavaSource" destdir="${webinf.dir}/classes"> <classpath refid="compile.classpath"/> </javac> </target> <!-- Remove classes directory for clean build --> <target name="clean" description="Prepare for clean build"> <delete dir="${webinf.dir}/classes"/> <mkdir dir="${webinf.dir}/classes"/> </target> <!-- Build entire project --> <target name="build" depends="prepare,compile"/> <target name="rebuild" depends="clean,prepare,compile"/> <!-- Create binary distribution --> <target name="war" depends="build"> <mkdir dir="${build.dir}"/> <war basedir="${webroot.dir}" warfile="${build.dir}/${project.distname}.war" webxml="${webinf.dir}/web.xml"> <exclude name="WEB-INF/${build.dir}/**"/> <exclude name="WEB-INF/src/**"/> <exclude name="WEB-INF/web.xml"/> </war> </target> <target name="deploy" depends="war"> <delete file="${deploy.dir}/${project.distname}.war"/> <delete dir="${deploy.dir}/${project.distname}"/> <copy file="${build.dir}/${project.distname}.war" todir="${deploy.dir}"/> </target> <target name="copywar" depends="deploy"> <copyfile dest="D:/Tomcat5/webapps/${project.distname}.war" src="${build.dir}/${project.distname}.war"/> </target> </project>
Albert
Bookmark Post in Technorati
Reply With Quote
Sponsored Links
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Problems with hibernate and eclipse Albert Database 2 06-05-2008 05:34 PM
GUI problems. saytri New To Java 1 12-17-2007 12:27 AM
Problems with Eclipse Daniel Eclipse 1 07-06-2007 06:23 PM
Problems with the jar Freddie NetBeans 2 05-29-2007 05:50 PM
Problems with the jar Freddie NetBeans 0 05-09-2007 04:18 PM


All times are GMT +3. The time now is 01:42 PM.


VBulletin, Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.
Copyright ©2006 - 2007, www.java-forums.org