W3C home > Mailing lists > Public > public-xformsusers@w3.org > December 2016

Dynamic dependencies

From: Steven Pemberton <steven.pemberton@cwi.nl>
Date: Thu, 22 Dec 2016 10:13:09 +0100
To: XForms <public-xformsusers@w3.org>
Message-ID: <op.ysu7v7ljsmjzpq@steven-aspire-s7>

This section lists some functions that are safe and dangerous for using in  
model binding expressions.

It lists position(), last(), and count() as safe and then goes on to say:

"functions such as id(), instance(), and index() can establish dynamic  
dependencies that can necessitate invoking a rebuild if they are used in  
model binding expressions or computed expressions because the results of  
the functions are affected by changing the values of instance nodes, not  
by inserting or deleting nodes."

index() I understand perfectly. The value comes from outside the model,  
and so changes to the index don't trigger rebuild/recalculate.

id() I think I understand. id('X Y', instance('Z')) also doesn't get  
triggered I suppose.

But instance() I don't understand. Can anyone give me an example of a  
model binding that uses instance(), and is unsafe?

Received on Thursday, 22 December 2016 09:13:42 UTC

This archive was generated by hypermail 2.4.0 : Friday, 17 January 2020 19:37:47 UTC