Next in thread → Next in month →

[OASIS Issue Tracker] (ODATA-1142) Clarify MaxDistance is an optional parameter in hierarchy filter functions

From
OASIS Issues Tracker <>
Date
2018-02-22T16:56:07+00:00
ID
Thread
[OASIS Issue Tracker] (ODATA-1142) Clarify MaxDistance is an optional parameter in hierarchy filter functions
[ https://issues.oasis-open.org/browse/ODATA-1142?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Gerald Krause updated ODATA-1142:
---------------------------------

    Proposal: 
Extend the current definitions to make the maximum distance parameters optional by assigning the maximum possible distance by default (additions are enclosed in *):

<Function Name="isdescendant" IsBound="true">
  <Annotation Term="Core.Description" String="Returns true, if and only if the value of the node property of the specified hierarchy is a descendant of the given parent node with a distance of less than or equal to the optionally specified maximum distance"/>
  <Parameter Name="Entity" Type="Edm.EntityType" Nullable="false"/>
  <Parameter Name="Hierarchy" Type="Edm.String" Nullable="false"/>
  <Parameter Name="Node" Type="Edm.PrimitiveType" Nullable="false"/>
  <Parameter Name="MaxDistance" Type="Edm.Int16">
*    
    <Annotation Term="Core.OptionalParameter"> 
      <PropertyValue Property="DefaultValue" Int="32767"/> 
    </Annotation>
*    
  </Parameter>
  <ReturnType Type="Edm.Boolean"/>
</Function>
<Function Name="isancestor" IsBound="true">
  <Annotation Term="Core.Description" String="Returns true, if and only if the value of the node property of the specified hierarchy is an ancestor of the given child node with a distance of less than or equal to the optionally specified maximum distance"/>
  <Parameter Name="Entity" Type="Edm.EntityType" Nullable="false"/>
  <Parameter Name="Hierarchy" Type="Edm.String" Nullable="false"/>
  <Parameter Name="Node" Type="Edm.PrimitiveType" Nullable="false"/>
  <Parameter Name="MaxDistance" Type="Edm.Int16">
*    
    <Annotation Term="Core.OptionalParameter"> 
      <PropertyValue Property="DefaultValue" Int="32767"/> 
    </Annotation>
*    
  </Parameter>
  <ReturnType Type="Edm.Boolean"/>
</Function>

Note that term OptionalParameter has become available in the Core vocabulary with the work on OData version 4.01.

add to this proposal:
  - Use Validation.Minimum on the distance parameter
- Add meaning of distance to description


  was:
Extend the current definitions to make the maximum distance parameters optional by assigning the maximum possible distance by default (additions are enclosed in *):

<Function Name="isdescendant" IsBound="true">
  <Annotation Term="Core.Description" String="Returns true, if and only if the value of the node property of the specified hierarchy is a descendant of the given parent node with a distance of less than or equal to the optionally specified maximum distance"/>
  <Parameter Name="Entity" Type="Edm.EntityType" Nullable="false"/>
  <Parameter Name="Hierarchy" Type="Edm.String" Nullable="false"/>
  <Parameter Name="Node" Type="Edm.PrimitiveType" Nullable="false"/>
  <Parameter Name="MaxDistance" Type="Edm.Int16">
*    
    <Annotation Term="Core.OptionalParameter"> 
      <PropertyValue Property="DefaultValue" Int="32767"/> 
    </Annotation>
*    
  </Parameter>
  <ReturnType Type="Edm.Boolean"/>
</Function>
<Function Name="isancestor" IsBound="true">
  <Annotation Term="Core.Description" String="Returns true, if and only if the value of the node property of the specified hierarchy is an ancestor of the given child node with a distance of less than or equal to the optionally specified maximum distance"/>
  <Parameter Name="Entity" Type="Edm.EntityType" Nullable="false"/>
  <Parameter Name="Hierarchy" Type="Edm.String" Nullable="false"/>
  <Parameter Name="Node" Type="Edm.PrimitiveType" Nullable="false"/>
  <Parameter Name="MaxDistance" Type="Edm.Int16">
*    
    <Annotation Term="Core.OptionalParameter"> 
      <PropertyValue Property="DefaultValue" Int="32767"/> 
    </Annotation>
*    
  </Parameter>
  <ReturnType Type="Edm.Boolean"/>
</Function>

Note that term OptionalParameter has become available in the Core vocabulary with the work on OData version 4.01.



> Clarify MaxDistance is an optional parameter in hierarchy filter functions
> --------------------------------------------------------------------------
>
>                 Key: ODATA-1142
>                 URL: https://issues.oasis-open.org/browse/ODATA-1142
>             Project: OASIS Open Data Protocol (OData) TC
>          Issue Type: Bug
>          Components: Extension for Data Aggregation, Vocabularies
>    Affects Versions: V4.0_CSD03
>         Environment: Proposed
>            Reporter: Gerald Krause
>             Fix For: V4.0_CSD04
>
>
> Section 6.3.2.1 describes that functions isdescendant and isancestor both include a second parameter for the maximum distance that is ought to be optional. 
> The definitions of these functions in the vocabulary describe the parameters as mandatory.



--
This message was sent by Atlassian JIRA
(v6.2.2#6258)
Next in thread → Next in month →