Skip to content
This repository was archived by the owner on Nov 9, 2022. It is now read-only.

JSON Options Have Unnatural Way of Using Arrays #287

Open
@jamesagardner

Description

@jamesagardner

When going through the merge-options and match-options as JSON the pattern used for passing multiple values to JSON arrays doesn't seem very natural

Here is an example:
as-is:

"propertyDefs": {
    "property": [
        { "namespace": "", "localname": "IdentificationID", "name": "ssn" },
        { "namespace": "", "localname": "PersonGivenName", "name": "first-name" }
    ]
}

should be:

"propertyDefs": [
    { "namespace": "", "localname": "IdentificationID", "name": "ssn" },
    { "namespace": "", "localname": "PersonGivenName", "name": "first-name" }
]

Here are the other fields that follow this same array pattern that could be simplified:

matching options:

Current Path Suggested Path
propertyDefs.property[] propertyDefs[]
algorithms.algorithm[] algorithms[]
collections.content[] collections[]
actions.action[] actions[]
thresholds.threshold[] thresholds[]

merging options:

Current Path Suggested Path
propertyDefs.properties[] propertyDefs[]

There may be other options that fall into this category, but these are the ones I've noticed so far.

Note: that this issue is related to #267

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions