"The value for the useBean class attribute is invalid" 错误。

来源:互联网 发布:淘宝助理需要花钱吗 编辑:程序博客网 时间:2024/06/11 19:38


"The value for the useBean class attribute is invalid" 错误。
原因:Bean中没有默认构造函数,

其实应该从出现这个错误的常见原因去找:
"The value for the useBean class attribute is invalid" 错误也就是
useBean 标签的 class 属性的值无效
可见错误可能的原因包括:

1. 在编译 JSP 时(不是运行时),指定的 Bean 类没找到

2. Bean 虽然找到了,但是它不是 public 的,或者找到的 class 文件是 interface 或抽象类

3. Bean 类中没有 public 的默认构建函数  

原创粉丝点击