Is it possible to store web content (such as JSPs, HTML, images, CSS etc) in a JAR file?
I've been looking at various options at modularising our web applications and this is one possibility.
We are currently using JSF and Facelets for our view technology - I'm thinking it may be possible to write some form of custom view resolver which would examine the classpath rather than a filesystem directory, but I'm not sure this would work.
Any ideas would be appreciated! :)
Update: I should probably clarify. How do you get the web container (such as Tomcat) to load resources from a JAR file? For example, I deploy a .war file with my web application. If I access /index.jsp, the container will try to look in the web content directory for a file named index.jsp.
Is there an easy way to configure your own resource loader using Tomcat or the like so that it searches the classpath as well as the filesystem?