Hi Feng Xiao! Thanks for the response.
    That's actually our backup plan. We were hoping to avoid it, though, 
since the wrappers would each contain an extra copy of the data internally. 
Our ideal case is for the data to get copied in a single step directly from 
an InputStream to a ByteString with no intermediate copies along the way.
Question: You would know best... Would the safety of ByteStrings be 
preserved if the readChunk() method were to be made public? If so, I'll 
open a feature request on the issue tracker.

On Monday, August 5, 2013 7:32:49 PM UTC-4, Feng Xiao wrote:
>
> How about create an wrapper InputStream that only reads N bytes from the 
> original InputStream and provide the wrapper to BytesString.readFrom()?
>

 

-- 
You received this message because you are subscribed to the Google Groups 
"Protocol Buffers" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to protobuf+unsubscr...@googlegroups.com.
To post to this group, send email to protobuf@googlegroups.com.
Visit this group at http://groups.google.com/group/protobuf.
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to