forked from dotnet/corefx
-
Notifications
You must be signed in to change notification settings - Fork 0
Json prototype - transformation API #2
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
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
bartonjs
reviewed
Jul 18, 2019
bartonjs
reviewed
Jul 18, 2019
bartonjs
reviewed
Jul 18, 2019
bartonjs
reviewed
Jul 18, 2019
bartonjs
reviewed
Jul 18, 2019
bartonjs
reviewed
Jul 18, 2019
bartonjs
reviewed
Jul 18, 2019
bartonjs
reviewed
Jul 18, 2019
bartonjs
reviewed
Jul 18, 2019
bartonjs
reviewed
Jul 18, 2019
bartonjs
reviewed
Jul 18, 2019
kasiabulat
commented
Jul 19, 2019
joperezr
reviewed
Jul 19, 2019
joperezr
reviewed
Jul 19, 2019
joperezr
reviewed
Jul 19, 2019
joperezr
reviewed
Jul 19, 2019
joperezr
reviewed
Jul 19, 2019
joperezr
reviewed
Jul 19, 2019
joperezr
reviewed
Jul 19, 2019
joperezr
reviewed
Jul 19, 2019
joperezr
reviewed
Jul 19, 2019
joperezr
reviewed
Jul 19, 2019
joperezr
reviewed
Jul 19, 2019
joperezr
reviewed
Jul 19, 2019
joperezr
reviewed
Jul 19, 2019
joperezr
reviewed
Jul 19, 2019
joperezr
reviewed
Jul 19, 2019
joperezr
reviewed
Jul 19, 2019
joperezr
reviewed
Jul 19, 2019
joperezr
reviewed
Jul 19, 2019
joperezr
reviewed
Jul 19, 2019
Owner
Author
|
I will add more tests in subsequent PR. |
kasiabulat
added a commit
that referenced
this pull request
Jul 29, 2019
* transformation API added * assertions to existing scenarios added
Owner
Author
|
I created the issue for my project: https://github.com/dotnet/corefx/issues/39922 |
kasiabulat
added a commit
that referenced
this pull request
Aug 9, 2019
* Json prototype (#1) Basic API for Json writable DOM with scenarios including collection initialization, accessing and modifying Json nodes. * Json prototype - transformation API (#2) * transformation API added * assertions to existing scenarios added * Json prototype (#1) Basic API for Json writable DOM with scenarios including collection initialization, accessing and modifying Json nodes. * Json prototype - transformation API (#2) * transformation API added * assertions to existing scenarios added * JsonNumber implementation and tests (#3) * IEquatables added * JsonNumber implementation and unit tests added * pragmas deleted * review comments included, more tests added * decimal support added to JsonNumber * decimal support added to JsonArray and JsonObject * all unimplemented classes and methods with accompanying tests removed * First part of documentation added * documentation completed * missing exceptions added * JsonElement changes removed * part of the review comments included * work on review comments * code refactor * more decimal tests added using MemberData * more decimal tests added using MemberData * more test cases added * equals summary adjusted, equals tests added * more Equals tests added, GetHashCode tests added, minor changes * scientifing notation support added, rational numbers tests fixes * rational overflow tests added * ulong maxvalue tests added to rational types * presision problems fixes * exception strings fixed * CI failing fixes (hopefully), review comments included * missing == tests added to achieve 100% branch coverage * review comments included * trailing whitespaces fixes * equals comments added * equals object refactored to call quals json number * merge fix
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
I added following transforming API (and accompanying scenarios):
DeepCopymethod inJsonElementallowing to changeJsonElementandJsonDocumentintoJsonNoderecursively transforming all of the elementsAsJsonElementmethod inJsonNodeallowing to changeJsonNodeintoJsonElementwithIsImmutableproperty set to falseIsImmutableproperty informing ifJsonElementis keepingJsonDocumentorJsonNodeunderneathParse(string)inJsonNodeto be able to parse Json string right intoJsonNodeif user knows he/she wants mutable versionDeepCopyinJsonNodeto make a copy of the whole treeGetNodeandTryGetNodeinJsonNodeallowing to retrieve it fromJsonElementIssues addressed from previous PR:
Sortmethod toJsonArrayand accompanying scenariosArrayListmethods I considered onlyLastIndexOfuseful and consistent withIndexOf, but I still need to write scenarios for bothStill open question from previous PR:
equalstoJsonArrayandJsonObject?cc: @joperezr @bartonjs @ericstj @ahsonkhan @terrajobst