Skip to content

Commit 74f022f

Browse files
committed
$Apply and $Function in Appendix B
1 parent 48a734e commit 74f022f

File tree

3 files changed

+35
-32
lines changed

3 files changed

+35
-32
lines changed

docs/odata-csdl-json/odata-csdl-json.html

Lines changed: 17 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -2979,8 +2979,8 @@ <h3 id="-add--sub--mul--div--divby-and--mod"><a name="Add21.14" href="#Add21.14"
29792979
</div>
29802980
<h3 id="1444-apply-client-side-functions"><a name="ApplyClientSideFunctions" href="#ApplyClientSideFunctions">14.4.4 Apply Client-Side Functions</a></h3>
29812981
<p>The apply expression enables a value to be obtained by applying a client-side function. The apply expression MAY have operand expressions. The operand expressions are used as parameters to the client-side function.</p>
2982-
<section id="-apply" class="varjson rep">
2983-
<h3><a name="Apply21.20" href="#Apply21.20"> <code>$Apply</code></a></h3>
2982+
<section id="-apply-and--function" class="varjson rep">
2983+
<h3><a name="Apply21.20" href="#Apply21.20"> <code>$Apply</code></a> and <a name="Function21.21" href="#Function21.21"> <code>$Function</code></a></h3>
29842984
<p>Apply expressions are represented as an object with a member <code>$Apply</code> whose value is an array of annotation expressions, and a member <code>$Function</code> whose value is a string containing the <a href="#QualifiedName">qualified name</a> of the client-side function to be applied.</p>
29852985
<p>It MAY contain <a href="#Annotation">annotations</a>.</p>
29862986
</section>
@@ -3073,7 +3073,7 @@ <h4 id="14444-function-odatauriencode"><a name="FunctionodatauriEncode" href="#F
30733073
<h3 id="1445-cast"><a name="Cast" href="#Cast">14.4.5 Cast</a></h3>
30743074
<p>The cast expression casts the value obtained from its single child expression to the specified type. The cast expression follows the same rules as the <code>cast</code> canonical function defined in <a href="#ODataURL">OData-URL</a>.</p>
30753075
<section id="-cast" class="varjson rep">
3076-
<h3><a name="Cast21.21" href="#Cast21.21"> <code>$Cast</code></a></h3>
3076+
<h3><a name="Cast21.22" href="#Cast21.22"> <code>$Cast</code></a></h3>
30773077
<p>Cast expressions are represented as an object with a member <code>$Cast</code> whose value is an annotation expression, a member <code>$Type</code> whose value is a string containing the qualified type name, and optionally a member <code>$Collection</code> with a value of <code>true</code>.</p>
30783078
<p>It MAY contain <a href="#Annotation">annotations</a>.</p>
30793079
<p>If the specified type is a primitive type or a collection of primitive types, the facet members <a href="#MaxLength"><code>$MaxLength</code></a>, <a href="#Unicode"><code>$Unicode</code></a>, <a href="#Precision"><code>$Precision</code></a>, <a href="#Scale"><code>$Scale</code></a>, and <a href="#SRID"><code>$SRID</code></a> MAY be specified if applicable to the specified primitive type. If the facet members are not specified, their values are considered unspecified.</p>
@@ -3106,7 +3106,7 @@ <h3 id="1447-if-then-else"><a name="IfThenElse" href="#IfThenElse">14.4.7 If-The
31063106
<p>The second and third child expressions are evaluated conditionally. The result MUST be type compatible with the type expected by the surrounding expression.</p>
31073107
<p>If the first expression evaluates to <code>true</code>, the second expression MUST be evaluated and its value MUST be returned as the result of the if-then-else expression. If the first expression evaluates to <code>false</code> and a third child element is present, it MUST be evaluated and its value MUST be returned as the result of the if-then-else expression. If no third expression is present, nothing is added to the surrounding collection.</p>
31083108
<section id="-if" class="varjson rep">
3109-
<h3><a name="If21.22" href="#If21.22"> <code>$If</code></a></h3>
3109+
<h3><a name="If21.23" href="#If21.23"> <code>$If</code></a></h3>
31103110
<p>Conditional expressions are represented as an object with a member <code>$If</code> whose value is an array of two or three annotation expressions.</p>
31113111
<p>It MAY contain <a href="#Annotation">annotations</a>.</p>
31123112
</section>
@@ -3125,7 +3125,7 @@ <h3><a name="If21.22" href="#If21.22"> <code>$If</code></a></h3>
31253125
<h3 id="1448-is-of"><a name="IsOf" href="#IsOf">14.4.8 Is-Of</a></h3>
31263126
<p>The <code>is-of</code> expression checks whether the value obtained from its single child expression is compatible with the specified type. It returns <code>true</code> if the child expression returns a type that is compatible with the specified type, and <code>false</code> otherwise.</p>
31273127
<section id="-isof" class="varjson rep">
3128-
<h3><a name="IsOf21.23" href="#IsOf21.23"> <code>$IsOf</code></a></h3>
3128+
<h3><a name="IsOf21.24" href="#IsOf21.24"> <code>$IsOf</code></a></h3>
31293129
<p>Is-of expressions are represented as an object with a member <code>$IsOf</code> whose value is an annotation expression, a member <code>$Type</code> whose value is a string containing an qualified type name, and optionally a member <code>$Collection</code> with a value of <code>true</code>.</p>
31303130
<p>It MAY contain <a href="#Annotation">annotations</a>.</p>
31313131
<p>If the specified type is a primitive type or a collection of primitive types, the facet members <a href="#MaxLength"><code>$MaxLength</code></a>, <a href="#Unicode"><code>$Unicode</code></a>, <a href="#Precision"><code>$Precision</code></a>, <a href="#Scale"><code>$Scale</code></a>, and <a href="#SRID"><code>$SRID</code></a> MAY be specified if applicable to the specified primitive type. If the facet members are not specified, their values are considered unspecified.</p>
@@ -3144,7 +3144,7 @@ <h3 id="1449-labeled-element"><a name="LabeledElement" href="#LabeledElement">14
31443144
<p>A labeled element expression MUST contain exactly one child expression. The value of the child expression is also the value of the labeled element expression.</p>
31453145
<p>A labeled element expression MUST provide a <a href="#SimpleIdentifier">simple identifier</a> value as its name that MUST be unique within the schema containing the expression.</p>
31463146
<section id="-labeledelement" class="varjson rep">
3147-
<h3><a name="LabeledElement21.24" href="#LabeledElement21.24"> <code>$LabeledElement</code></a></h3>
3147+
<h3><a name="LabeledElement21.25" href="#LabeledElement21.25"> <code>$LabeledElement</code></a></h3>
31483148
<p>Labeled element expressions are represented as an object with a member <code>$LabeledElement</code> whose value is an annotation expression, and a member <code>$Name</code> whose value is a string containing the labeled element’s name.</p>
31493149
<p>It MAY contain <a href="#Annotation">annotations</a>.</p>
31503150
</section>
@@ -3160,7 +3160,7 @@ <h3><a name="LabeledElement21.24" href="#LabeledElement21.24"> <code>$LabeledEle
31603160
<h3 id="14410-labeled-element-reference"><a name="LabeledElementReference" href="#LabeledElementReference">14.4.10 Labeled Element Reference</a></h3>
31613161
<p>The labeled element reference expression MUST specify the <a href="#QualifiedName">qualified name</a> of a <a href="#LabeledElement">labeled element expression</a> in scope and returns the value of the identified labeled element expression as its value.</p>
31623162
<section id="-labeledelementreference" class="varjson rep">
3163-
<h3><a name="LabeledElementReference21.25" href="#LabeledElementReference21.25"> <code>$LabeledElementReference</code></a></h3>
3163+
<h3><a name="LabeledElementReference21.26" href="#LabeledElementReference21.26"> <code>$LabeledElementReference</code></a></h3>
31643164
<p>Labeled element reference expressions are represented as an object with a member <code>$LabeledElementReference</code> whose value is a string containing an qualified name.</p>
31653165
</section>
31663166
<div class="varjson example">
@@ -3179,7 +3179,7 @@ <h3 id="14411-null"><a name="Null" href="#Null">14.4.11 Null</a></h3>
31793179
<div class="sourceCode" id="cb93"><pre class="sourceCode json"><code class="sourceCode json"><span id="cb93-1"><a href="#cb93-1" aria-hidden="true" tabindex="-1"></a><span class="er">&quot;@UI.DisplayName&quot;:</span> <span class="er">null,</span></span></code></pre></div>
31803180
</div>
31813181
<section id="-null" class="varjson rep">
3182-
<h3><a name="Null21.26" href="#Null21.26"> <code>$Null</code></a></h3>
3182+
<h3><a name="Null21.27" href="#Null21.27"> <code>$Null</code></a></h3>
31833183
<p>Null expression containing <a href="#Annotations">annotations</a> are represented as an object with a member <code>$Null</code> whose value is the literal <code>null</code>.</p>
31843184
</section>
31853185
<div class="varjson example">
@@ -3235,7 +3235,7 @@ <h3 id="14413-url-reference"><a name="URLReference" href="#URLReference">14.4.13
32353235
<p>The URL reference expression MUST contain exactly one expression of type <code>Edm.String</code>. Its value is treated as a URL that MAY be relative or absolute; relative URLs are relative to the URL of the document containing the URL reference expression, or relative to a base URL specified in a format-specific way.</p>
32363236
<p>The response body of the <code>GET</code> request MUST be returned as the result of the URL reference expression. The result of the URL reference expression MUST be type compatible with the type expected by the surrounding expression.</p>
32373237
<section id="-urlref" class="varjson rep">
3238-
<h3><a name="UrlRef21.27" href="#UrlRef21.27"> <code>$UrlRef</code></a></h3>
3238+
<h3><a name="UrlRef21.28" href="#UrlRef21.28"> <code>$UrlRef</code></a></h3>
32393239
<p>URL reference expressions are represented as an object with a single member <code>$UrlRef</code> whose value is an annotation expression.</p>
32403240
<p>It MAY contain <a href="#Annotation">annotations</a>.</p>
32413241
</section>
@@ -3799,13 +3799,14 @@ <h1 id="appendix-b-table-of-json-objects-and-members"><a name="TableofJSONObject
37993799
<li><a href="#DivBy21.18"><code>$DivBy</code></a></li>
38003800
<li><a href="#Mod21.19"><code>$Mod</code></a></li>
38013801
<li><a href="#Apply21.20"><code>$Apply</code></a></li>
3802-
<li><a href="#Cast21.21"><code>$Cast</code></a></li>
3803-
<li><a href="#If21.22"><code>$If</code></a></li>
3804-
<li><a href="#IsOf21.23"><code>$IsOf</code></a></li>
3805-
<li><a href="#LabeledElement21.24"><code>$LabeledElement</code></a></li>
3806-
<li><a href="#LabeledElementReference21.25"><code>$LabeledElementReference</code></a></li>
3807-
<li><a href="#Null21.26"><code>$Null</code></a></li>
3808-
<li><a href="#UrlRef21.27"><code>$UrlRef</code></a></li>
3802+
<li><a href="#Function21.21"><code>$Function</code></a></li>
3803+
<li><a href="#Cast21.22"><code>$Cast</code></a></li>
3804+
<li><a href="#If21.23"><code>$If</code></a></li>
3805+
<li><a href="#IsOf21.24"><code>$IsOf</code></a></li>
3806+
<li><a href="#LabeledElement21.25"><code>$LabeledElement</code></a></li>
3807+
<li><a href="#LabeledElementReference21.26"><code>$LabeledElementReference</code></a></li>
3808+
<li><a href="#Null21.27"><code>$Null</code></a></li>
3809+
<li><a href="#UrlRef21.28"><code>$UrlRef</code></a></li>
38093810
</ul></li>
38103811
</ul>
38113812
</div>

docs/odata-csdl-json/odata-csdl-json.md

Lines changed: 16 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -4909,7 +4909,7 @@ The operand expressions are used as parameters to the client-side
49094909
function.
49104910

49114911
::: {.varjson .rep}
4912-
### <a name="Apply21.20" href="#Apply21.20"> `$Apply`</a>
4912+
### <a name="Apply21.20" href="#Apply21.20"> `$Apply`</a> and <a name="Function21.21" href="#Function21.21"> `$Function`</a>
49134913

49144914
Apply expressions are represented as an object with a member `$Apply`
49154915
whose value is an array of annotation expressions, and a member
@@ -5090,7 +5090,7 @@ rules as the `cast` canonical function defined in
50905090
[OData-URL](#ODataURL).
50915091

50925092
::: {.varjson .rep}
5093-
### <a name="Cast21.21" href="#Cast21.21"> `$Cast`</a>
5093+
### <a name="Cast21.22" href="#Cast21.22"> `$Cast`</a>
50945094

50955095
Cast expressions are represented as an object with a member `$Cast`
50965096
whose value is an annotation expression, a member `$Type` whose value is
@@ -5173,7 +5173,7 @@ third expression is present, nothing is added to the surrounding
51735173
collection.
51745174

51755175
::: {.varjson .rep}
5176-
### <a name="If21.22" href="#If21.22"> `$If`</a>
5176+
### <a name="If21.23" href="#If21.23"> `$If`</a>
51775177

51785178
Conditional expressions are represented as an object with a member `$If`
51795179
whose value is an array of two or three annotation expressions.
@@ -5208,7 +5208,7 @@ child expression is compatible with the specified type. It returns
52085208
the specified type, and `false` otherwise.
52095209

52105210
::: {.varjson .rep}
5211-
### <a name="IsOf21.23" href="#IsOf21.23"> `$IsOf`</a>
5211+
### <a name="IsOf21.24" href="#IsOf21.24"> `$IsOf`</a>
52125212

52135213
Is-of expressions are represented as an object with a member `$IsOf`
52145214
whose value is an annotation expression, a member `$Type` whose value is
@@ -5255,7 +5255,7 @@ identifier](#SimpleIdentifier) value as its name that MUST be unique
52555255
within the schema containing the expression.
52565256

52575257
::: {.varjson .rep}
5258-
### <a name="LabeledElement21.24" href="#LabeledElement21.24"> `$LabeledElement`</a>
5258+
### <a name="LabeledElement21.25" href="#LabeledElement21.25"> `$LabeledElement`</a>
52595259

52605260
Labeled element expressions are represented as an object with a member
52615261
`$LabeledElement` whose value is an annotation expression, and a member
@@ -5286,7 +5286,7 @@ in scope and returns the value of the identified labeled element
52865286
expression as its value.
52875287

52885288
::: {.varjson .rep}
5289-
### <a name="LabeledElementReference21.25" href="#LabeledElementReference21.25"> `$LabeledElementReference`</a>
5289+
### <a name="LabeledElementReference21.26" href="#LabeledElementReference21.26"> `$LabeledElementReference`</a>
52905290

52915291
Labeled element reference expressions are represented as an object with
52925292
a member `$LabeledElementReference` whose value is a string containing
@@ -5322,7 +5322,7 @@ Example 85:
53225322
:::
53235323

53245324
::: {.varjson .rep}
5325-
### <a name="Null21.26" href="#Null21.26"> `$Null`</a>
5325+
### <a name="Null21.27" href="#Null21.27"> `$Null`</a>
53265326

53275327
Null expression containing [annotations](#Annotations) are represented
53285328
as an object with a member `$Null` whose value is the literal `null`.
@@ -5433,7 +5433,7 @@ expression MUST be type compatible with the type expected by the
54335433
surrounding expression.
54345434

54355435
::: {.varjson .rep}
5436-
### <a name="UrlRef21.27" href="#UrlRef21.27"> `$UrlRef`</a>
5436+
### <a name="UrlRef21.28" href="#UrlRef21.28"> `$UrlRef`</a>
54375437

54385438
URL reference expressions are represented as an object with a single
54395439
member `$UrlRef` whose value is an annotation expression.
@@ -6072,13 +6072,14 @@ https://openui5.hana.ondemand.com/1.40.10/#docs/guide/87aac894a40640f89920d7b2a4
60726072
- [`$DivBy`](#DivBy21.18)
60736073
- [`$Mod`](#Mod21.19)
60746074
- [`$Apply`](#Apply21.20)
6075-
- [`$Cast`](#Cast21.21)
6076-
- [`$If`](#If21.22)
6077-
- [`$IsOf`](#IsOf21.23)
6078-
- [`$LabeledElement`](#LabeledElement21.24)
6079-
- [`$LabeledElementReference`](#LabeledElementReference21.25)
6080-
- [`$Null`](#Null21.26)
6081-
- [`$UrlRef`](#UrlRef21.27)
6075+
- [`$Function`](#Function21.21)
6076+
- [`$Cast`](#Cast21.22)
6077+
- [`$If`](#If21.23)
6078+
- [`$IsOf`](#IsOf21.24)
6079+
- [`$LabeledElement`](#LabeledElement21.25)
6080+
- [`$LabeledElementReference`](#LabeledElementReference21.26)
6081+
- [`$Null`](#Null21.27)
6082+
- [`$UrlRef`](#UrlRef21.28)
60826083
:::
60836084

60846085
-------

odata-csdl/14 Vocabulary and Annotation.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2278,7 +2278,8 @@ The operand expressions are used as parameters to the client-side
22782278
function.
22792279

22802280
::: {.varjson .rep}
2281-
### ##subisec `$Apply`
2281+
### ##subisec `$Apply`
2282+
and ##subisec `$Function`
22822283

22832284
Apply expressions are represented as an object with a member `$Apply`
22842285
whose value is an array of annotation expressions, and a member

0 commit comments

Comments
 (0)