Hi. I have a few questions, please be patient and tolerant ;-) I am only beginning:
1. what is the use of
jsp:text standard action? the JSP 2.0 specs (point 6.3.9) says it must be used when I want to display template text in JSP documents (XML syntax), but actually I have been able to print text without using this action at all, just by putting it in the file, for example within the <body> tags. The only thing that is different that I noticed is that when the jsp:text has only whitespace characters, they are preserved in the output. For exanmple: "<body> </body>" is output as "<body />", and "<body><jsp:text> </jsp:text></body>" is output as "<body> </body>". Is there any other use?
2, point 1.14.2.1 in the specs (page 96), there is a table of possible conversion sources and targets, and its says at the very top, for Bean Property: "As converted by the corresponding PropertyEditor, if any,
using PropertyEditor.setAsText(string-literal) and PropertyEditor.
getValue(). If there is no corresponding PropertyEditor
or the PropertyEditor throws an exception, �null� if the
string is empty, otherwise error." So, if there is no property editor, and the string value which is used to set the attribute is empty (""), it should set null to the property. However,
tomcat 5.5.26 throws an exception complaining no editor can be found. Is this a violation of the specs, or have I misunderstood something? (I am using jsp:setProperty with value="" to
test this.)
3. when I have JSP pages, I can create a
servlet element in web.xml for the page, to supply init-params for example. However, there is also an implicit mapping *.jsp(x) in the container, so I can actually access the same page in two ways, using both urls: from the servlet mapping, and the implicit mapping. If the resource is constrained, I would have to create two url-patterns for it or sth? To fix that I came up with two options: use the same url-mapping for the servelt as the actual path to the jsp file in the webapp, or hide the page in WEB-INF. However, the second may be a nuisance, as in this way I would have to explicitly create servlet elements for (possibly many many) all my JSP pages, as resources within WEB-INF and META-INF are protected. How is this problem dealt with?
Thank you.