You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by Gabriel Belingueres <be...@gmail.com> on 2010/01/12 22:35:07 UTC

Re: Can I implement interface of another project in a struts 2 project?

Seems it is not S2 related. This exception is raised when some
dependency is not found by the JVM. Note that in addition to be
available in your build path, the dependency must be available at
runtime too (usually inside the WEB-INF/lib folder)

2010/1/12 fireapple <ta...@gmail.com>:
>
> In project1, I include project2 in order to use interfaces (interface A, B,
> C, D.....) of project2.
> However, the system always claim java.lang.NoClassDefFoundError for
> interface of project2.
>
> I also exported project2 to a JAR and include it in project1's build path,
> still no luck.
>
> I tried 3 of my projects, all fail with the same error. I was wondering if
> it's a struts 2 issue of my configuration problem.
>
> Thanks
> --
> View this message in context: http://old.nabble.com/Can-I-implement-interface-of-another-project-in-a-struts-2-project--tp27131976p27131976.html
> Sent from the Struts - User mailing list archive at Nabble.com.
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
> For additional commands, e-mail: user-help@struts.apache.org
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org


Re: Can I implement interface of another project in a struts 2 project?

Posted by Gabriel Belingueres <be...@gmail.com>.
the build path is considered only by the java compiler, not by your
executing application server. The WEB-INF/lib is the folder the web
apps put required run time dependencies, so that the app server can
found them.

2010/1/13 fireapple <ta...@gmail.com>:
>
> It solved the problem. Thanks!
>
> I wonder what's the difference between putting jar in build path and putting
> jar in WEB-INF/lib. Appreciate
>
>
> Gabriel Belingueres-2 wrote:
>>
>> Seems it is not S2 related. This exception is raised when some
>> dependency is not found by the JVM. Note that in addition to be
>> available in your build path, the dependency must be available at
>> runtime too (usually inside the WEB-INF/lib folder)
>>
>> 2010/1/12 fireapple <ta...@gmail.com>:
>>>
>>> In project1, I include project2 in order to use interfaces (interface A,
>>> B,
>>> C, D.....) of project2.
>>> However, the system always claim java.lang.NoClassDefFoundError for
>>> interface of project2.
>>>
>>> I also exported project2 to a JAR and include it in project1's build
>>> path,
>>> still no luck.
>>>
>>> I tried 3 of my projects, all fail with the same error. I was wondering
>>> if
>>> it's a struts 2 issue of my configuration problem.
>>>
>>> Thanks
>>> --
>>> View this message in context:
>>> http://old.nabble.com/Can-I-implement-interface-of-another-project-in-a-struts-2-project--tp27131976p27131976.html
>>> Sent from the Struts - User mailing list archive at Nabble.com.
>>>
>>>
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
>>> For additional commands, e-mail: user-help@struts.apache.org
>>>
>>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
>> For additional commands, e-mail: user-help@struts.apache.org
>>
>>
>>
>
> --
> View this message in context: http://old.nabble.com/Can-I-implement-interface-of-another-project-in-a-struts-2-project--tp27131976p27151209.html
> Sent from the Struts - User mailing list archive at Nabble.com.
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
> For additional commands, e-mail: user-help@struts.apache.org
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org


Re: Can I implement interface of another project in a struts 2 project?

Posted by fireapple <ta...@gmail.com>.
It solved the problem. Thanks!

I wonder what's the difference between putting jar in build path and putting
jar in WEB-INF/lib. Appreciate


Gabriel Belingueres-2 wrote:
> 
> Seems it is not S2 related. This exception is raised when some
> dependency is not found by the JVM. Note that in addition to be
> available in your build path, the dependency must be available at
> runtime too (usually inside the WEB-INF/lib folder)
> 
> 2010/1/12 fireapple <ta...@gmail.com>:
>>
>> In project1, I include project2 in order to use interfaces (interface A,
>> B,
>> C, D.....) of project2.
>> However, the system always claim java.lang.NoClassDefFoundError for
>> interface of project2.
>>
>> I also exported project2 to a JAR and include it in project1's build
>> path,
>> still no luck.
>>
>> I tried 3 of my projects, all fail with the same error. I was wondering
>> if
>> it's a struts 2 issue of my configuration problem.
>>
>> Thanks
>> --
>> View this message in context:
>> http://old.nabble.com/Can-I-implement-interface-of-another-project-in-a-struts-2-project--tp27131976p27131976.html
>> Sent from the Struts - User mailing list archive at Nabble.com.
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
>> For additional commands, e-mail: user-help@struts.apache.org
>>
>>
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
> For additional commands, e-mail: user-help@struts.apache.org
> 
> 
> 

-- 
View this message in context: http://old.nabble.com/Can-I-implement-interface-of-another-project-in-a-struts-2-project--tp27131976p27151209.html
Sent from the Struts - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org