[closed] Re: re p:iteration-source

/ James Fuller <james.fuller.2007@gmail.com> was heard to say:
| In addition, I would propose adding to p:iteration-source an attribute
| that would throw an error if the @select matches nothing e.g.
|
| <p:iteration-source
|   select? = XPathExpression
|  @fail-if-empty='true/false'>
|     (p:empty |
|       (p:pipe |
|        p:document |
|        p:inline)+)?
| </p:iteration-source>
|
| where if @fail-if-empty is set to true (defaults to false) a dynamic
| error is thrown if @select matches nothing.

The WG discussed this and decided that if it was applied to for-each
it would also need to be applied to viewport. And then, why not also
to rename, and perhaps other places.

On balance, we observe that the following XPath 2.0 workaround will
catch the error

  select="(expression) treat as element()+"

so we're not going to add this for V1.

                                        Be seeing you,
                                          norm

-- 
Norman Walsh <ndw@nwalsh.com> | Things work out best for those who make
http://nwalsh.com/            | the best of the way things work out.

Received on Thursday, 17 April 2008 16:58:27 UTC