cocoon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Joerg Heinicke <joerg.heini...@gmx.de>
Subject Re: [CForms] Support for multipe unique-row-id in Repeater
Date Wed, 03 Mar 2004 21:24:52 GMT
>  <wb:repeater id="myRepeaterId" parent-path="." row-path="TheRowPath">
>    <wb:unique-row>
>      <wb:unique-field id="myId1" path="myId1"/>
>      <wb:unique-field id="myId2" path="myId2"/>
>    </wb:unique-row>
>    <wb:on-bind>
>      <wb:value id="myId1" path="myId1"/>
>      <wb:value id="myId2" path="myId2"/>
>      <wb:value id="field1" path="field1"/>
>      <wb:value id="field2" path="field2"/>
>    </wb:on-bind>
>  </wb:repeater>

It was a good idea to replace the both attributes with a more 
sophisticated XML structure, but it is a bad realization in my opinion.

<rant>
The above is redundant, irritating (unique-field is not really correctly 
named, is it?) and (because of the more java code we need) bloated. On 
the one hand the redundancy above is obvious, on the other hand 
sentences like "This unique-field element ... The id and path attributes 
have the same meaning as in <wb:value>. ... The wd:convertor ... For 
more info see the description of this element in <wb:value>." will get 
me suspicious. Why the ยง$%& we need an additional XML element if we have 
already one that seems to be perfect for it: wb:value as the frequent 
references above show? Why do we have to specify @id and @path twice for 
those identifying elements? And so on. Such changes should be well 
thought out, otherwise we have to change to much later on when 
sophisticating our XML elements. And the latter we do this the more we 
will break. Unfortunately not many Woody developers are really active on 
the list at the moment.
</rant>

Another thing that I don't like is the new restriction:
"Note: This binding is only active in the 'load' operation, so 
specifying the direction="save" is meaningless."

Sorry, Antonio, but you seem to be often the targets of my rants ...

> NOTE: The "old style" is also supported. You don't need to rewrite your
> code. But I think we can also deprecate the old way (using attributes).

I would not let live these deprecated attributes that long. Just like we 
did it for @readonly => @direction I would remove it as fast as possible 
and therefore do a big ANNOUNCEMENT on the users list.

BTW, the wd:convertor element can also be deprecated and removed as it 
is used in combination with the unique-row-id.

Joerg

Mime
View raw message