I am using this code to read a file in a tomcat project, called Project1 and now I want to get this path in different tomcat project, called Project2, using java.
getServlet().getServletConfig().getServletContext()
.getResourceAsStream("pdf/invoice.jasper");
How can I do this?