Skip to content

Implement Independent Serialization Policies for Primitive Data Types when converting XML to JSON #194

Description

@twigglius

[This is an enhancement request, not a true issue]

When converting XML to JSON the code does its best to determine proper serialization/deserialization but it is sometimes incorrect. I should have the ability to tell the program to treat primitive data types according to my requirements.

For example I have an XML message I want to convert to JSON, but I want every field to written as a String. I have an element in my XML with a value of '5237E8' after conversion, the JSON shows the value as 5.237E11. It assumed it was a double and converted it.

Another example is I have elements with leading 0's that need to be maintained in the conversion to json, but those 0's are removed in the serialization/deserialization.

This is standard functionality in other similar libraries such as GSON.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions