• Post Reply Bookmark Topic Watch Topic
  • New Topic

Must classes be packaged?

 
Jose Ortuno
Ranch Hand
Posts: 39
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Is it true that I "have to" put my classes into packages for tomcat to find them?

I know it is a good aproach but... I am interested in knowing how Tomcat resolve the claaspath in JSPs since the compilated class is kept in a location other that myapp/WB-INF/classes


Thanks,


[Bear edit: added meaningful topic title]
[ April 28, 2005: Message edited by: Bear Bibeault ]
 
Bear Bibeault
Author and ninkuma
Marshal
Posts: 65524
105
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Yes it is true.

And please use meaningful subjects for your topics. Thanks.
 
Bear Bibeault
Author and ninkuma
Marshal
Posts: 65524
105
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
compilated class is kept in a location other that myapp/WB-INF/classes


There are only certain locations that Tomcat will use to load classes. WEB-INF/classes (not WB-INF) is one of them. Another is any jar files in WEB-INF/lib. Tomcat also has some locations where jars can be shared among all web apps it is serving.

Your compiled classes must be placed according to these rules. Tomcat will not look at classes elsewhere, not even on any CLASSPATH environment variables.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!