PUTs and getInputStream()

Gordon Dakin writes:
 > 
 > Thanks for your help with proxying.  At this stage, I have a new resource
 > class that extends FileResource (to take advantage of GET & PUT), plus
 > methods borrowed from ForwardDirectory to proxy a request on-the-fly.
 > I've been able to proxy GET requests to a foreign host running a "pure"
 > Jigsaw.  But I'm having trouble doing the same with PUTs, because I don't
 > see any way to set the request's input stream (FileResource's put() does
 > a request.getInputStream() and passes the result to newContent()).  The
 > request's MimeParser's "input" attribute is  returned by getInputStream(),
 > but there is no setInputStream() method, and both Request's parser and
 > Parser's input are protected.  Am I bypassing some "usual" way for the
 > request to acquire an input stream (e.g., by changing a GET to a PUT
 > on-the-fly)?

The client side request object (ie w3c.www.protocol.http.Request) has
the appropriate setOutputStream(InputStream in) that I guess you are
looking for.

Again, check the ForwardDirectory, that supports PUT requests too..

Anselm.

Received on Monday, 18 November 1996 11:50:12 UTC