Skip to content

Inconsistencies for PostSubmodelElementByPath when operating on SubmodelElementList #181

@mjacoby

Description

@mjacoby

There are two issues with PostSubmodelElementByPath when adding elements to a SubmodelElementList

  1. Semantics of PostSubmodelElementByPath undefined for adding elements to SubmodelElementList
    When adding an element to a SubmodelElementList via PostSubmodelElementByPath it is undefined where in the list the new element is added. I assume it should be added to the end, however, this is not explicitely stated and therefore any implementation, like adding it at a random position, would be considered compliant to the specification.
  2. Asymmetry of API
    The API allows to delete an element at a specific position within a SubmodelElementList but does not provide a way to add an element at a specific position within a SubmodelElementList. This is unexpected and such an operation would be very helpful for users.
  3. PostSubmodelElementByPath does not allow to add elements without idShort which is optional for elements within a SubmodelElementList
    Specification (IDTA Number: 01002-3-0, June 2023, Section 5.3.11, p 35) states for operation PostSubmodelElementByPath
    The idShort of the new submodel element must be set in the payload.
    However, this prohibits adding a SubmodelElement without a idShort which is totally valid as long as the parent it is added to is of type SubmodelElementList.

Proposal(s):

  • add optional parameter index or position
  • remove constraint that idShort must be set

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions