Using a return value from a boolean function in JSP
866972Jul 18 2011 — edited Jul 18 2011Hi,
I have a java class and a function is defined there as :
public boolean getX(String a) throws Exception {
some code...
try {
....
Y=false;
}
return Y
}
}// endclass
Now i want to use the result in my JSP. From my JSP i am calling:
mvp= class.getX(String a)
<%=
if (mvp==true)
do
this
else
%>
Is this the right way to do this ? If no, please let me know how we will be handling this.