For type attribute it works:
<%@page import="si.test.*" %>
<jsp:useBean id="dog1" type="Dog" scope="session"></jsp:useBean>
For class attribute above does not work even with import.
jsp 2.0 spec says:
- class attribute
The fully qualiﬁed name of the class that deﬁnes the
implementation of the object. The class name is case
sensitive. If the class and beanName attributes are not speciﬁed the object must be present in the given scope.
- type attribute
If speciﬁed, it deﬁnes the type of the scripting variable
This allows the type of the scripting variable to be distinct
from, but related to, the type of the implementation class
The type is required to be either the class itself, a superclass
of the class, or an interface implemented by the class
The object referenced is required to be of this type,
otherwise a java.lang.ClassCastException shall occur at
request time when the assignment of the object referenced
to the scripting variable is attempted.
If unspeciﬁed, the value is the same as the value of the class
could you please help me to read API in correct way. I mean where I find the JSP spec that describe the requirments of using JSP standard action and so???
I have the API but i dont know where to find the related details like if I want to know about the required attributes of a particular directive or action tag OR what kind of value they can accept etc...??