You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by Galbayar Dorjgotov <ga...@mobinet.mn> on 2002/12/15 08:31:50 UTC

how to convert reader to the inputstream

how to convert reader to the inputstream?

--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


How do I unsubscribe?

Posted by Ronald Aronica <ra...@greystonegroup.com>.
I have tried most everything including sending blank messages to: 
tomcat-user-unsubscribe@jakarta.apache.org, and 
tomcat-user-unsubscribe-raronica=greystonegroup.com@jakarta.apache.org; 
and a request to be removed from the list to 
tomcat-user-owner@jakarta.apache.org. Nothing seems to work.  What 
should I do? HELP!

Thanks,
Ron Aronica



--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


Re: how to convert reader to the inputstream

Posted by "Craig R. McClanahan" <cr...@apache.org>.

On Sun, 15 Dec 2002, Galbayar Dorjgotov wrote:

> Date: Sun, 15 Dec 2002 15:31:50 +0800
> From: Galbayar Dorjgotov <ga...@mobinet.mn>
> Reply-To: Tomcat Users List <to...@jakarta.apache.org>
> To: TomCat Users <to...@jakarta.apache.org>
> Subject: how to convert reader to the inputstream
>
> how to convert reader to the inputstream?

It is not at all obvious what you are trying to accomplish -- could you
explain that, please?

If you want to read the submitted data as characters, you should call:

  Reader r = request.getReader();

Instead, if you want to read the submitted data as bytes, you should call:

  ServletInputStream sis = request.getInputStream();

Only one or the other call is allowed on any particular request.

Craig


--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>