tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Michael E. Locasto" <loca...@cs.columbia.edu>
Subject Re: Quick Question
Date Tue, 13 Aug 2002 13:43:26 GMT
Alex,

Probably the current working directory, which is whatever directory Tomcat
was started out of (probably bin/, but not necessarily so). You can provide
a full file name in the code, or use your web.xml to set a context parameter
that indicates a base path to do read/write relative to in your servlet.

You could also put that file somewhere your web application's Classloader
will see it and load it via a findResource() or getResourceAsStream().

Regards,
Michael

----- Original Message -----
From: "Isabel Lameda" <ILAMEDA@bancofederal.com>
To: "'Tomcat Users List'" <tomcat-user@jakarta.apache.org>
Sent: Tuesday, August 13, 2002 8:50 AM
Subject: RE: Quick Question


> Try to create a file in your bean and see where Tomcat stores it
>
> -----Mensaje original-----
> De: TOMITA_ALEX_NONLILLY@LILLY.COM
> [mailto:TOMITA_ALEX_NONLILLY@LILLY.COM]
> Enviado el: Lunes, 12 de Agosto de 2002 06:00 p.m.
> Para: Tomcat Users List
> Asunto: Quick Question
>
>
> Hi all,
>
> I wrote a simple java bean that reads a txt file, the problem is where do
> I need to put the txt file??...
> What is the default directory in Tomcat??....
>
> when I put something like this in my java bean :
> FileReader("config.txt")....
> Where does tomcat look for that file?....
>
> thanks
> Alex
>
> --
> To unsubscribe, e-mail:
<mailto:tomcat-user-unsubscribe@jakarta.apache.org>
> For additional commands, e-mail:
<mailto:tomcat-user-help@jakarta.apache.org>


--
To unsubscribe, e-mail:   <mailto:tomcat-user-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:tomcat-user-help@jakarta.apache.org>


Mime
View raw message