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

JsonPath setting by path and JSON facade #1

Closed
wants to merge 22 commits into from

Conversation

davefb
Copy link

@davefb davefb commented Jul 29, 2011

I did some feature enhancements to jsonpath as part of a project I'm working on. it's a pretty large change so you might not want to accept it wholesale, but feel free to take a look and use anything that might be useful to you. There are notes in the README.

@kallestenflo
Copy link
Contributor

Hi,

As you say it's a big change and it will break the projects where I use JsonPath today.

I will definitely pick parts of your code when I find the time.

Thank you for your input (and effort), it's appreciated!

Best regards
Kalle

On Jul 29, 2011, at 11:24 PM, davefb wrote:

I did some feature enhancements to jsonpath as part of a project I'm working on. it's a pretty large change so you might not want to accept it wholesale, but feel free to take a look and use anything that might be useful to you. There are notes in the README.

Reply to this email directly or view it on GitHub:
#1


</dependencies>
</project>
<?xml version="1.0"?>

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I am not totally sure what we are doing here with these mass removals and additions. They look like copy paste.

@kallestenflo
Copy link
Contributor

This is to old now.

KumarJayanti referenced this pull request in KumarJayanti/JsonPath Mar 15, 2019
… Configuration Option CREATE_MISSING_PROPERTIES_ON_DEFINITE_PATH needs to be set to enable this feature. Without this Option a Jsonpath.set() on a non-existent path would throw com.jayway.jsonpath.PathNotFoundException.

2. JSON -TO- JSON transformation :  A new API and SPI (TransformationProvider) has been introduced to support JSON to JSON transformation specified using Source and Target JsonPath's.  This feature makes use of #1 above to create/add the required attributes to the transformed target JSON.

3. As is the norm in JsonPath Framework, there can be several implementations of the TransformationProvider. This commit defines a particular Provider with its own JsonPath based TransformationSpec.  The Spec allows for WildCard mappings (currently Single-Level) for array paths. It provides a notion of LookupTables that support custom mapping of a string/enumeration value in the source document to a value in the corresponding transformed target document.

4. Changes made to Configuration and Option classes to introduce this new Optional TransformationProvider API.
5. DefaultsImpl updated to provide a default instance of the transformationProvider implementation.
6. Changes to internal classes PathRef, PathToken and PropertyPathToken mainly to support #1 above.
7. New API added to AbstractJsonProvider, addArrayIndex to support #1 above.

8. New Files and Classes :  API and SPI classes for TransformationProvider and TransformationSpec.
9. As an API the TransformationSpec provides the ability to get the spec as an opaque object and also one could validate the spec object.
10. Each implementation of the TransformationProvider can have its own TransformationSpec definition.
kallestenflo pushed a commit that referenced this pull request Apr 24, 2019
Update from json-path/JsonPath
PavelSakharchuk referenced this pull request in PavelSakharchuk/contribut_JsonPath Sep 22, 2023
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.

4 participants