tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Antony Paul" <>
Subject What is accepted way to read/write files in Tomcat ?
Date Thu, 15 Apr 2004 05:27:50 GMT
Hi all,
  What is the best way to read and write file(the file locations are inside
context) in a servlet container. I was able to read file using
getResourceAsStream() but writing using URLConnection().getOutputStream()
failed and throws  protocol doesn't support output -
UnknownServiceException. Is it legitimate to use the getRealPath() to get
the context root and write the file ?

Antony Paul

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message