Skip to main content



      Home
Home » Language IDEs » ServerTools (WTP) » specify transitive dependency in eclipse?(how to do i avoid configuation duplication?)
icon5.gif  specify transitive dependency in eclipse? [message #741370] Wed, 19 October 2011 09:18 Go to next message
Eclipse UserFriend
hi..

let's say i have a web project which depends on a java project which depends on a jar in it's class path.

if i try to use a class from java project that uses the jar, i will get a ClassNotFoundsException, is there anyway to have eclipse include that jar in the web class path? without actually inserting in the lib folder? i've tried everything, including specify order and export and use deployment assembly..

the only thing i can think of is include the jar in the server class path launcher..(which does work).
Re: specify transitive dependency in eclipse? [message #741393 is a reply to message #741370] Wed, 19 October 2011 09:37 Go to previous message
Eclipse UserFriend
On 19-Oct-11 07:18, elhanan wrote:
> hi..
>
> let's say i have a web project which depends on a java project which
> depends on a jar in it's class path.
>
> if i try to use a class from java project that uses the jar, i will get
> a ClassNotFoundsException, is there anyway to have eclipse include that
> jar in the web class path? without actually inserting in the lib folder?
> i've tried everything, including specify order and export and use
> deployment assembly..
> the only thing i can think of is include the jar in the server class
> path launcher..(which does work).

You should be able to consume that other project as a Web App Library.
Do this:

1) Right-click your (Dynamic Web) project.
2) Choose Build Path -> Configure Build Path...
3) Click the Libraries tab.
4) Click Add Library...
5) Select Web App Libraries and click Next.
6) Select the project whose libraries (JARs) you wish to consume.

It should be obvious from there.

Hope this answers your question.
Previous Topic:Re: Easy SOAP client code in java?
Next Topic:Can't run tomcat 7 on eclipse helios 3.6
Goto Forum:
  


Current Time: Wed Jul 23 13:56:52 EDT 2025

Powered by FUDForum. Page generated in 0.04876 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top