Hi,
Please confirm me this ..
Suppose that I have a value in my constant file,Constants.java :
public
String OUTPUT_KEY = "output" ;
.....
After some processing of the request,
the response handler creates a valid viewBean object,say, 'info' and sets it's attributre value as :
info.setAttribute(Constants.OUTPUT_KEY,someValidObject) ...
....
Now , in the success.jsp where I want to display the details of the viewBean,
I generally get the response bean by saying...
<
jsp:useBean id="output" scope="someScope" type="validClassType" />
While setting the value of 'id' as above,we should remember the value of OUTPUT_KEY in constants file and set 'id' to this same value,means we are hardcodng it.
I do not want to hardcode id="output" here..
I want to use the Constants.OUTPUT_KEY value directly to set value of 'id'.
If not,whenever a change is made to OUTPUT_KEY in Constants.java,we need to change the value that 'id' is set to in the jsp.
Any answers on this please....?
Constants.OUTPUT_KEYid="output" [ May 28, 2005: Message edited by: rk motorola ]