Re: [streams] How will ReadableByteStream work with seekable resources? (#253)

@domenic

> Can we tie the value to the stream's notion of "size", as governed by the strategy? So, we still let the stream creator judge size of objects. But now we let the stream consumer set the high water mark.

Yes, that's what I was thinking. window adjusts high water mark when there's a strategy and queue behind the stream.

> Is this supposed to take a "region specification" (= offset, count, I think?)? Or does it reuse the window that was set?

As it's specified to throw when window has ever been set to 0, I made `feedBuffer` and window exclusive.

> If so maybe it still needs to take an offset? Or are you using Uint8Array instead of ArrayBuffer specifically in order to get a region specification built in? If so that's interesting, not sure what I think of it...

So, right. I chose to represent region via the offset and size info held by the Uint8Array object. I don't have strong opinion about this. Separate topic. Sorry for confusing.

> How does this interact with the buffers it was fed? I am unsure whether readInto is actually necessary at all given feedBuffer() + read(). See #253 (comment).

Right. Sorry it was just not brushed up well. I'll summarize discussion I had with Yutaka and read your gist to republish our current ideas.

---
Reply to this email directly or view it on GitHub:
https://github.com/whatwg/streams/issues/253#issuecomment-74816352

Received on Wednesday, 18 February 2015 05:47:44 UTC