Reputation: 415
So I have a functioning eclipse/hibernate/spring webservice with some SOAP services, one of which is sayHello()
wich returns a string
Calling sayHello with http://localhost:8080/myWebService/soapServices/sayHello
yields:
<soap:Envelope>
<soap:Body>
<ns2:sayHelloResponse>
<return>greetings from the web service! time is 2015-09-06T14:39:23.375
</return>
</ns2:sayHelloResponse>
</soap:Body>
</soap:Envelope>
I've also created a companion webappp (the client) to access the web service.
It needs an XSLT stylesheet to format this response, but where should I put myStylesheet.xsl
within the project structure of my client webapp? Under new directory WEB-INF/stylesheets
?
Upvotes: 0
Views: 242
Reputation: 57169
Under new directory WEB-INF/stylesheets?
Yes, you are allowed to do so. The WEB-INF
directory is hidden from requests by default, but is accessible by code with getResource
and the like. See this post on structure and WEB-INF
for some hints on what your options are.
Bottom line: it is up to your gut-feeling to what location you find most convenient. If you want the files to be accessible by browsing, it is probably better not to put them inside WEB-INF
.
As an alternative, you can also compile the resources directly into your Java application as a compiled resource. But often it is easier to use a (configurable) location on disk, which allows post-compilation updates to your file.
Upvotes: 2