A recursive hierarchy annotation may also contain a navigation property to the parent node

    • Type: Improvement
    • Resolution: Fixed
    • Priority: Major
    • V4.0_CSD03
    • Affects Version/s: V4.0_CS01
    • Component/s: Data Aggregation
    • None
    • Environment:

      [Applied]

    • Hide

      Extend the RecursiveHierarchy term by a property ParentNavigationProperty of type Edm.NavigationPropertyPath. Added element surrounded by *:
      <Term Name="RecursiveHierarchy" Type="Aggregation.RecursiveHierarchyType" AppliesTo="EntityType ComplexType">
      <Annotation Term="Core.Description" String="Defines a recursive hierarchy." />
      </Term>

      <ComplexType Name="RecursiveHierarchyType">
      <Property Name="NodeProperty" Type="Edm.PropertyPath" Nullable="false">
      <Annotation Term="Core.Description" String="Property holding the hierarchy node value" />
      </Property>
      <Property Name="ParentNodeProperty" Type="Edm.PropertyPath" Nullable="false">
      <Annotation Term="Core.Description" String="Property holding the value of the parent node" />
      </Property>
      <Property Name="HierarchyLevelProperty" Type="Edm.PropertyPath" Nullable="true">
      <Annotation Term="Core.Description" String="Property holding the hierarchy level of the node" />
      </Property>
      *<Property Name="ParentNavigationProperty" Type="Edm.NavigationPropertyPath" Nullable="true">
      <Annotation Term="Core.Description" String="Property for navigating to the parent node" />
      </Property>*
      <Property Name="IsLeafProperty" Type="Edm.PropertyPath" Nullable="true">
      <Annotation Term="Core.RequiresType" String="Edm.Boolean" />
      <Annotation Term="Core.Description" String="Property indicating whether the node is a leaf of the hierarchy" />
      </Property>
      </ComplexType>

      Ammendments:
      -Remove the term property "ParentNodeProperty"
      -Make the ParentNavigationProperty required by changing the Nullable property to false.

      Applied: https://www.oasis-open.org/committees/document.php?document_id=56041&wg_abbrev=odata

      Show
      Extend the RecursiveHierarchy term by a property ParentNavigationProperty of type Edm.NavigationPropertyPath. Added element surrounded by *: <Term Name="RecursiveHierarchy" Type="Aggregation.RecursiveHierarchyType" AppliesTo="EntityType ComplexType"> <Annotation Term="Core.Description" String="Defines a recursive hierarchy." /> </Term> <ComplexType Name="RecursiveHierarchyType"> <Property Name="NodeProperty" Type="Edm.PropertyPath" Nullable="false"> <Annotation Term="Core.Description" String="Property holding the hierarchy node value" /> </Property> <Property Name="ParentNodeProperty" Type="Edm.PropertyPath" Nullable="false"> <Annotation Term="Core.Description" String="Property holding the value of the parent node" /> </Property> <Property Name="HierarchyLevelProperty" Type="Edm.PropertyPath" Nullable="true"> <Annotation Term="Core.Description" String="Property holding the hierarchy level of the node" /> </Property> *<Property Name="ParentNavigationProperty" Type="Edm.NavigationPropertyPath" Nullable="true"> <Annotation Term="Core.Description" String="Property for navigating to the parent node" /> </Property>* <Property Name="IsLeafProperty" Type="Edm.PropertyPath" Nullable="true"> <Annotation Term="Core.RequiresType" String="Edm.Boolean" /> <Annotation Term="Core.Description" String="Property indicating whether the node is a leaf of the hierarchy" /> </Property> </ComplexType> Ammendments: -Remove the term property "ParentNodeProperty" -Make the ParentNavigationProperty required by changing the Nullable property to false. Applied: https://www.oasis-open.org/committees/document.php?document_id=56041&wg_abbrev=odata

      Consider a client processing entities according to their hierarchical structure imposed by the given hierarchy annotation. If the client wants to filter this entity set on some other property not related to the hierarchy, s/he wants to get all tree segments from the matching entities upwards to the root node. If the recursive hierarchy would also include a "parent" navigation property, this could be accomplished with a single request:
      GET Set?$filter=dataProp eq someValue&$select=nodeId,parentNodeId&$expand=parent($levels='max')
      In order to let clients detect the availability of such navigations, the existing RecursiveHierarchy term needs to be extended.

            Assignee:
            gerald.krause1
            Reporter:
            gerald.krause1
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: