About Question enthuware.jwpv6.2.997 :
Moderators: Site Manager, fjwalraven
-
- Posts: 1
- Joined: Fri Mar 29, 2013 5:13 pm
- Contact:
About Question enthuware.jwpv6.2.997 :
The attribute class no need a fully qualified name?
-
- Site Admin
- Posts: 10053
- Joined: Fri Sep 10, 2010 9:26 pm
- Contact:
Re: About Question enthuware.jwpv6.2.997 :
Not if it is imported. Or if it is in default package.
-Paul.
-Paul.
If you like our products and services, please help us by posting your review here.
-
- Posts: 19
- Joined: Mon Sep 01, 2014 9:45 pm
- Contact:
Re: About Question enthuware.jwpv6.2.997 :
Why 2 and 5 are valid?
To be visible for Jsp servlet Java Bean should have a package otherwise the page will not compile. I cannot navigate where I read about probaly is related to how compileer is looking for classes. If bean is in default package the compiller will try to find the class in same package as generated servlet class. But the problem is that the generated jsp class is in its own package which is not default.
When code is tested there is a compilattion error.
To be visible for Jsp servlet Java Bean should have a package otherwise the page will not compile. I cannot navigate where I read about probaly is related to how compileer is looking for classes. If bean is in default package the compiller will try to find the class in same package as generated servlet class. But the problem is that the generated jsp class is in its own package which is not default.
When code is tested there is a compilattion error.
-
- Site Admin
- Posts: 10053
- Joined: Fri Sep 10, 2010 9:26 pm
- Contact:
Re: About Question enthuware.jwpv6.2.997 :
I couldn't find anywhere where such requirement is mentioned. Anyway, the question is not really about this so I have added a package statement to avoid this confusion altogether.
thank you for your feedback!
thank you for your feedback!
If you like our products and services, please help us by posting your review here.
Who is online
Users browsing this forum: No registered users and 22 guests