Skip to content

Commit 745d22a

Browse files
pmariaDylanVanAssche
authored andcommitted
use list instead of set to define the result of expression (#121)
1 parent 35e610c commit 745d22a

File tree

1 file changed

+10
-9
lines changed

1 file changed

+10
-9
lines changed

spec/docs/expressions.md

Lines changed: 10 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -9,31 +9,32 @@ An <dfn>expression map</dfn> (`rml:ExpressionMap`) is an abstract class, that is
99
* 1 `rml:reference`, or
1010
* 1 `rml:template`.
1111

12-
Each of these properties specifies an [=expression=] which, upon evaluation, results in a [=set of values]=.
12+
Each of these properties specifies an [=expression=] which, upon evaluation, results in an ordered list of values.
1313

1414
The <dfn>set of values</dfn> are the values of the [=references expression set=] which are returned by an [=expression=].
1515

16-
For each value in the [=set of values=], an [=expression value=] is created. If the [=set of values=] is empty, `NULL` is returned and no [=expression value=] is created.
16+
For each value in the ordered list of values, an [=expression value=] is created. If the ordered list of values is empty, `NULL` is returned and no [=expression value=] is created.
1717

1818
The <dfn>reference expression set</dfn> of an [=expression map=] is the set of expressions which are evaluated on a [=logical iteration=].
1919

2020
### Constant expression (`rml:constant`)
2121

22-
A <dfn>constant-valued expression map</dfn> is an [=expression map=] that always generates the same expression value. A constant-valued expression map is represented by a resource that has exactly one `rml:constant` property, the value of which is called a <dfn>constant expression</dfn>.
22+
A <dfn>constant-valued expression map</dfn> is an [=expression map=] that always generates the same value. A constant-valued expression map is represented by a resource that has exactly one `rml:constant` property, the value of which is called a <dfn>constant expression</dfn>.
2323

24-
The <dfn>constant value</dfn> is a singleton set containing the [=constant expression=].
24+
The <dfn>constant value</dfn> is a singleton list containing the [=constant expression=].
2525

26-
The [=reference expressions=] of a [constant-valued expression map=] is the empty set.
26+
The [=reference expressions=] of a [constant-valued expression map=] is an empty list.
2727

2828
### Reference (`rml:reference`)
2929
A <dfn>reference-valued expression map</dfn> is an [=expression map=] that is represented by a resource that has exactly one `rml:reference` property, the value of which is called a <dfn>reference expression</dfn>.
3030

3131
The [=reference expression=] MUST be a valid [=expression=] according to the defined [=reference formulation=] in the [=logical source=].
3232

33-
The [=reference expression set=] of a [reference-valued expression map=] is the singleton set containing the [=reference expression=].
33+
The [=reference expression set=] of a [=reference-valued expression map=] is the singleton set containing the [=reference expression=].
3434

35-
The <dfn>reference value set</dfn> is a set of values obtained by evaluating a [=reference expression=] against a given [=logical iteration=]. For each value in the set, an expression is created.
36-
If the reference value set is an empty set, then the processor SHOULD return `NULL` and no expression should be created but a processor COULD allow users to adjust the strategy.
35+
The <dfn>reference value</dfn> is an ordered list of values obtained by evaluating the [=reference expression=] against a given [=logical iteration=].
36+
For each value in the ordered list, an expression is created.
37+
If the reference value set is an empty ordered list, then the processor SHOULD return `NULL` and no expression should be created but a processor COULD allow users to adjust the strategy.
3738

3839
### Template (`rml:template`)
3940
A <dfn>template-valued expression map</dfn> is an [=expression map=] that is represented by a resource that has exactly one `rml:template` property, the value of which is called a <dfn>template expression</dfn>. The [=template expression=] MUST be a valid [=string template=].
@@ -57,7 +58,7 @@ The <dfn>template value</dfn> when evaluating a [=string template=] for a given
5758
1. Let `result` be the [=reference expression set=] of the [=string template=]
5859
2. For each [=reference expression=] in `result`:
5960
1. Let `values` be the [=reference value=] of the [=reference expression=] that is enclosed in the curly braces
60-
2. If `values` is an empty set, then return `NULL`
61+
2. If `values` is an empty list, then return `NULL`
6162
3. For each `value` in `values`:
6263
1. Let `value` be the [=natural RDF lexical form=] corresponding to `value`
6364
3. Let `result` be the [=n-ary Cartesian product=] of `result`

0 commit comments

Comments
 (0)