Skip to content

Stream Parser Support - pt3 - create parser context object and turn parse() function into parser.parse() #35

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

Merged
merged 2 commits into from
Aug 25, 2020

Conversation

jf-tech
Copy link

@jf-tech jf-tech commented Aug 24, 2020

Stream Parser Support - pt3 - create parser context object and turn parse() function into parser.parse()

Eventually streaming parser needs to remember state in between client calls, thus we have to save those into a parser context object. This PR simply creates the parser context object and turns parse() the standalone function into a method on parser object. Move all the state variables into parser object. Other than that, the functionalities and code paths remain unchanged.

jf-tech added 2 commits August 25, 2020 07:56
… `parse()` function into `parser.parse()`

Eventually streaming parser needs to remember state in between client calls, thus we have to
save those into a `parser` context object. This PR simply creates the `parser` context object
and turns `parse()` the standalone function into a method on `parser` object. Move all the state
variables into `parser` object. Other than that, the functionalities and code paths remain unchanged.
@coveralls
Copy link

Coverage Status

Coverage increased (+0.6%) to 87.288% when pulling db13d6a on jf-tech:jf-tech/parse4 into 5f8a389 on antchfx:master.

1 similar comment
@coveralls
Copy link

Coverage Status

Coverage increased (+0.6%) to 87.288% when pulling db13d6a on jf-tech:jf-tech/parse4 into 5f8a389 on antchfx:master.

@zhengchun zhengchun merged commit fa5754e into antchfx:master Aug 25, 2020
@jf-tech jf-tech deleted the jf-tech/parse4 branch August 25, 2020 20:57
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

Successfully merging this pull request may close these issues.

None yet

3 participants