Re: A note on <bind /> (similar to <group />)

> The spec actually doesn't say whether @nodeset is optional or required
> on xf:bind [1]. However, the schema (which is normative) *does* say that
> @nodeset is optional [2]. This therefore leads to a number of possible
> arrangements, many of which I believe are very useful.
> 
> For example, you could break this:
> 
>     <bind nodeset="task" readonly="true()" relevant="true()" />
> 
> into this:
> 
>     <bind nodeset="task">
>       <bind readonly="true()" />
>       <bind relevant="true()" />
>     </bind>
> 

Couldn't the same thing could be done as

    <bind nodeset="task">
       <bind nodeset="." readonly="true()"/>
       <bind nodeset="." relevant="true()"/>
    </bind>


>     <bind nodeset="shortTermLoanApplication">
>       <xi:include href="business-rules.xml" />
>     </bind>
> 
> whilst another form might have this:
> 
>     <bind nodeset="studentLoanApplication">
>       <xi:include href="business-rules.xml" />
>     </bind>
> 
> The company's rules can now be changed in one place.
> 
> Leigh's use of <bind /> is a special case of this, where if you have a
> number of rules in the central file, you would need to encapsulate them
> all in a single xf:bind:
> 
>     <bind>
>       <bind readonly="true()" />
>       <bind constraint=". &gt; 7" />
>     </bind>
> 

Again, I think, included file can easily do the following

<bind nodeset=".">
    <bind nodeset="."  readonly="..."/>
    <bind nodeset="." ... />
</bind>

Isn't it? This is a bit more explicit also. Am I missing something?

PV

Received on Thursday, 5 February 2004 12:34:56 UTC