Reputation: 1
How to get the full path of file located in /src/reportpackage/daysheet.jasper in the spring mvc application?. How to get the string format of the path?
Upvotes: 0
Views: 987
Reputation: 9102
You need to understand that after the build your file would end up in classpath and what you would be loading through Spring resource loading mechanism is a classpath resource. You can use spring notation for it like this
appContext.getResource("classpath:reportpackage/daysheet.jasper");
where appContext is the spring application context which can be autowired in any Spring bean
Upvotes: 3