Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

debugger cannot access the parent page variable in the included page

I have parent page named userCreated and I include another page in it named confirmationUser using

 <%@include file="confirmationUser.jsp" %>

in the parent page (userCreated) I have the variable registerUser and I am trying to see its value in intellij but I am getting the error when I am using evaluate expression Local variable '' not found in class closure

I am using latest version of intellij

I can see any local variable that I defined in the confirmationUser , what should I do to see registerUser in confirmationUser

when I run the page there is no problem and it is working but I need to debug because sometims I am getting null pointer exception and I want to directly know what is the problem.

Parent Page

  RegisterUser registerUser = null;

Child Page

    <% 
String x = "blabla";

  Boolean developer = registerUser.getPackage()!=null && registerUser.getPackage().getName().equals("Developer");%>

here I cannot see the registerUser variable However I can see x variable in the debugger

enter image description here

like image 553
Mohammed Subhi Sheikh Quroush Avatar asked Oct 20 '22 22:10

Mohammed Subhi Sheikh Quroush


1 Answers

Most likely you need to:

  1. Configure web facet for your project if you haven't done it;

  2. Configure the directory containing your JSP pages as 'Web Resource Directory'.

I suspect (2) is not done and thus IntelliJ has trouble to resolve relative path of the included page.

like image 144
Scanner.js Receipt Invoice OCR Avatar answered Oct 27 '22 09:10

Scanner.js Receipt Invoice OCR