There is a difference between adding to the classpath and importing.
The class path helps the JVM find the .class file for a particular class.
The import statements allow a developer to use the short class-only name
(i.e. Vector) instead of the fully qualified class name (i.e.
java.util.Vector). These are two entirely different concepts and one really
has not bearing on the other.
Randy
> -----Original Message-----
> From: Andrew [mailto:[EMAIL PROTECTED]]
> Sent: Thursday, May 17, 2001 11:54 AM
> To: [EMAIL PROTECTED]
> Subject: Re: Static filed reference BUG since( Tomcat 4b2-b5)
>
>
> Thanks a lot, it works! But I was thinking that tomcat
> 4b1 import(add to
> classpath) all the classes for every .JSP from WEB-INF\classes.
> Is it reasonable(why WEB-INF\classpath dir)?
>
> ----- Original Message -----
> From: "Randy Layman" <[EMAIL PROTECTED]>
> To: <[EMAIL PROTECTED]>
> Sent: Thursday, May 17, 2001 3:26 PM
> Subject: RE: Static filed reference BUG since( Tomcat 4b2-b5)
>
>
> >
> > Just a thought - have you imported that class? You need to remember
> > that all generated classes are placed into a package
> corresponding to
> their
> > location in the webapp (prefixed by jsp, I believe), so classes that
> aren't
> > in any package aren't in the same package as the JSP file.
> I believe that
> > if you import the class (and I think you'll have to do each
> separate class
> > explicitly) this should solve your problem.
> >
> > Randy
> >
> > -----Original Message-----
> > From: Andrew [mailto:[EMAIL PROTECTED]]
> > Sent: Thursday, May 17, 2001 5:44 AM
> > To: [EMAIL PROTECTED]
> > Subject: Static filed reference BUG since( Tomcat 4b2-b5)
> >
> >
> > Hi, every time I try to reference static field(from jsp page) in
> > nonpackaged class I've got jasper error:
> > Undefined variable or class name: Myclass, but I've put that in
> > \WEB-INF\classes dir of my app and Tomcat4b1 process my
> page without any
> > errors.
> >
> > What could be wrong?
> >
>