Ludwig Magnusson wrote:
> Hello!
> 
> We are a team developing a webapp running on a tomcat server. We need to
> list the files in a certain directory in our application, but we cannot find
> a way to always get the correct path on the different platforms and
> environments. Is this solvable through some IO-function or do we need to
> specify the path to our project in each environment?

This is probably better suited to the Tomcat users list.

That said, as a general rule it is not safe to assume that your web
application is deployed on a file system. Your app could be packaged as
a WAR file sitting on a database.

That said, there are some Servlet API calls that can tell you if you or
on a file system and if you are, where you are on the file system.

Follow up on the Tomcat users list if you need more info.

Mark




---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscr...@commons.apache.org
For additional commands, e-mail: user-h...@commons.apache.org

Reply via email to