Skip to content

Range property name (de)serialisation doesn't respect property naming strategyΒ #56

@philleonard

Description

@philleonard

Field names in the Guava Range<T> are serialised and deserialised with the hard coded values lowerEndpoint, lowerBoundType, upperEndpoint and upperBoundType:

    {
      "lowerEndpoint": 1,
      "lowerBoundType": "OPEN",
      "upperEndpoint": 10,
      "upperBoundType": "CLOSED"
    }

For consistent JSON field naming it would be nice to support other property naming strategies. For example snake case:

    {
      "lower_endpoint": 1,
      "lower_bound_type": "OPEN",
      "upper_endpoint": 10,
      "upper_bound_type": "CLOSED"
    }

Please see here for the basic idea philleonard@8a3f36f. Happy to open this as a PR and change to whatever is the correct way of formatting field names when writing them as strings.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions