struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Dave Newton <newton.d...@yahoo.com>
Subject Re: OutputStreamPath
Date Thu, 01 Mar 2007 19:01:40 GMT
--- Daniel Chacón Sánchez <danielccss@gmail.com>
wrote:
> Someone?

Sorry it took me so long.

> I have a question, how I can set the path for the
> OutputStream like i get it for the InputStream with 
> getResourceAsStream?

I'm not sure you can do that, particularly since a
resource might be inside a JAR file or be located in a
place you do not have write acess to.

If you know that the properties file is in a specific
place and that it makes sense to write to it then I
would think you'd use typical file i/o and determine
the path via getRealPath.

It confuses me why you'd want to do this in a webapp,
though. Settings you are likely to modify from within
the app should be in a database, not a properties file
(IMO, anyway).

d.



 
____________________________________________________________________________________
Sucker-punch spam with award-winning protection. 
Try the free Yahoo! Mail Beta.
http://advision.webevents.yahoo.com/mailbeta/features_spam.html

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org


Mime
View raw message