m00hk00h Posted June 22, 2015 Posted June 22, 2015 I have a report report.jrxml. All of the resources that the report uses are located in the same directory. Images, subreports and styles, etc.The directory might be: classpath:path/to/report/.All resources are referenced in the report design by filename only - no directories are given.e.g.<imageExpression><![CDATA["logo.png"]]></imageExpression><template><![CDATA["style.jrtx"]]></template>Reports are compiled by using the maven plug-in.The application is delivered as a single jar file. It is a webapp running on an embedded tomcat (via java -jar app.jar). It not classically deployed and not unpacked into any kind of known directory structure. All resources are loaded directly from the jar. It works fine with images referenced this way. It doesn't work at all for styles or subreports.JasperReports expects me to implement the FileResolver to help it find resources it cannot resolve itself. Problem is that the return type is file which does not support loading files from archives...And this is where I'm stuck. Why can the Jasper engine find images this ways but not other resources?What can I do now? Any ideas?
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now