Re: ACTION-2193: Propose text separating the two cases of id identification

I've been giving this some thought, and I think I've found a way to do it,  
and make the text describing ID identification in repeats simpler as well,  
by inverting how we describe it, and describing it declaratively rather  
than procedurally.

====

An active id is one that is not in a repeating construct, or in a repeat  
item that is currently active (is indexed by the current value of the  
repeat index for that repeat).

A passive id is one in a repeat item that is not currently active.

An IDREF is identified by matching in the list of active ids.

Actions that refer to an element that is not in the set of active ids, but  
is in the set of passive ids have no effect.

Functions that refer to an element that is not in the set of active ids,  
but is in the set of passive ids return an exception value: index()  
returns NaN, and case() returns an empty sequence.

IDREFs that don't match any id generate an error.

====

This would then override my suggestion for new text in  
https://lists.w3.org/Archives/Public/public-xformsusers/2018Aug/0004.html

See  
https://lists.w3.org/Archives/Public/public-xformsusers/2018Jul/0000.html  
for a list of elements with IDREFs.

This does not yet address the question of @bind and bind() which is a  
separate agenda item.

Steven




On Wed, 22 Aug 2018 15:19:29 +0200, XForms Users Community Group Issue  
Tracker <sysbot+tracker@w3.org> wrote:

> ACTION-2193: Propose text separating the two cases of id identification
>
> https://www.w3.org/2005/06/tracker/xforms/actions/2193
>
> Assigned to: Steven Pemberton
>
>
>
>
>
>
>

Received on Wednesday, 29 August 2018 10:21:42 UTC