static 2 « Development « JSP-Servlet Q&A





1. Wether Declaration is used to create Static variables or instance variables    coderanch.com

public class MyTranslatedJSP extends HttpServlet{ int a = 20; int b = 30; public void service(HttpServletRequest request, HttpServletResponse response){ int a = 10; out.println("The value of b multiplied by a is " + (b * a)); } } That is an approximation of what your JSP will produce in servlet code. No, you should not have had to ask this question. ...

2. Two war files in a single ear file and each war files has a static variable    coderanch.com

Hi Suresh, Jeanne is correct. In summary: * Default behaviour for application server * For 1 EAR file with 2 WAR files within same VM, the class loader tree looks like this: 1. System class loader (JDK and application server libraries) 2. Parent class loader (EAR file) 2.1 Child class loader 1 (WAR file #1) 2.2 Child class loader 2 (WAR ...

3. JSP static include issue    coderanch.com

Hi, I have a JSP named ui_init.jsp which uses the string constants defined in another class named AppConstants.java The ui_init.jsp is included in the home.jsp using the following tag <%@ include file="ui_init.jsp" %> Now I am adding a new constant in the AppConstants.java and using it in ui_init.jsp as AppConstants.REPORT_URL I am compiling the AppConstants.java to class file and copying it ...

5. Static Code Analyzer for JSP files    coderanch.com

Hi Bill - Let me exploring the work directory and figure out further. Thanks for the response. And sorry about posting this query in WebServices forum. Being away from ranch for a while I was lost - how to move my question to appropriate forum and had to leave it webservices forum. Shall make sure does not happen again. Thanks again. ...

6. Call a static method from JSP    coderanch.com

7. Static variables in servlets    java-forums.org

8. using a static variable in a servlet    java-forums.org





10. About static and dynamic display in JSP    forums.oracle.com