vendredi 2 août 2019

XML file location when parsing in Java Web app

I have a Java Web app that parses an XML file. I'm running it on glassfish 5 server.

This is the code I'm using to parse the XML file:

Document doc = db.parse("dictionary.xml");

It works fine when the XML file is located in:

C:\glassfish5\glassfish\domains\domain1\config

How can I make it work if the file is in another location, for example in the app project folder?




Aucun commentaire:

Enregistrer un commentaire