-
Notifications
You must be signed in to change notification settings - Fork 55
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Streaming/chunked inputs? #41
Comments
Not currently possible but I definitely thought on that kind of thing. The main problem is that much of data structures rely on knowing at least size of entire data, so making jBinary streaming would make parsing those impossible/inconsistent with other structures. Not sure how to properly address both kind of cases (where generic streaming mode is needed + where |
This would be easiest to implement in jDataView. The method to read one byte, for example, would read it either from the current buffer or advance to the next if there were no remaining bytes in the current buffer. Streaming parsing would be harder—some of the APIs might have to become async. |
Even in jDataView, advancing mode is completely optional, and you still need to have ability to read/write stuff at any offset. Thus, all the APIs become async and so breaking+slower :( |
I'm getting my input as a sequence of
ArrayBuffer
s. I can merge them all into a singleArrayBuffer
for jBinary, but I'd save time & memory if I could feed the individualArrayBuffer
s in one at a time. Is this possible with jBinary/jDataView?The text was updated successfully, but these errors were encountered: