you need to import java.io.IOException.... probably in previous versions
of tomcat the generated code imported this method, thus masking the fact
that you didn't import it.... they now (I guess) dont do this, and so the
compiler is looking for IOException in the package of the code, which is
org.apache.jsp (default jsp package).

in summary  page import="java.io.IOException"  shoudl fix it.

cheers
dim

On Mon, 24 Sep 2001, chris brown wrote:

> Hello,
> 
> In a JSP page, I have a method a bit like this:
> 
> void myMethod(Object someParam, JspWriter out)
> throws IOException
> {
>   ...
> }
> 
> The use of "out" is for some quick debugging.  Anyway, this code works fine
> under Tomcat 3.2.3, but porting it over to TC4 final produced the following
> compilation errors :
> 
> "Class org.apache.jsp.IOException not found in throws"
> 
> It would seem that although I'm using standard API classes/interfaces
> (JspWriter, IOException), the "import" statements in the generated ".java"
> files based on the ".jsp" files are too vague... "java.io.IOException" is
> getting mixed up with "org.apache.jsp.IOException".
> 
> This may be in turn related to some confusion between the public "JspWriter"
> class and some underlying implementation class with the same unqualified
> name.
> 
> As it happens, I don't need to use JspWriter, as it was only for debugging.
> However, this sort of ambiguity could be much more annoying for some other
> applications!
> 
> Hope this helps!
> Chris Brown
> 
> 

Reply via email to