I have questions about import
java class in
JSP,like the following structure
test |
|__WEB-INF
|
|__classes
|
|_ Dog.class
In classes directory,I put a java class named Dog.class,and I put a JSP file
in test directory,named index.jsp ,and In index.jsp called Dog class,but I
don't use "import",I think JSP can find it.
/*Dog.java*/
public class Dog{
String name;
public Dog(String a){
this.name=name;
}
public String getName(
return name;
}
}
But when I run index.jsp,it raised error:
cannot resolve symbol : class Dog
Then I copy hello class into test directory,it still raise above errors.
My questions are:
1.I want to know what default path which JSP use class
2.I don't want to use "package" in Dog.java, If I use import in JSP,how to
write this import statement?
Thanks in Advance.