Skip to content
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

Return length of decoded input #160

Open
bramp opened this issue Apr 11, 2021 · 0 comments
Open

Return length of decoded input #160

bramp opened this issue Apr 11, 2021 · 0 comments

Comments

@bramp
Copy link

bramp commented Apr 11, 2021

Over websocket I receive a stream of objects. I know the byte length of each object, and I want to ensure (as a safety/sanity check) that DecodeObject(...) has fully read the input. I see the private function decodeObject(...) returns the length, but that's not made available to the user.

May I request that either

  1. The API is changed to return the length
  2. A public field/method is added to the Decoder type, that exposed the number of bytes read.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant