logo       
Google Custom Search
    AddThis Social Bookmark Button

Re[2]: nested calculate problem: msg#00022

Subject: Re[2]: nested calculate problem
JT> we detected a problem with the dependency engine or to be more specific
JT> the part that finds the referenced nodes of a binding. We'll investigate
JT> this and hope to find a fix soon.
OK thank you. I hope the patch can fix the broblem in
chiba-core-1.1.1.

JT> Joern
JT> Михаил Павлов wrote:
>> There is a problem with nested calculates in chiba-core 1.2.0.
>> Instance
>> <data>
>>   <test1>
>>     <item id="1"/>
>>     <item id="2"/>
>>     <item id="3"/>
>>     <item id="4"/>
>>     <item id="5"/>
>>     <item id="6"/>
>>   </test1>
>>   <test2>
>>     <item1/>
>>     <item2/>
>>     <item3/>
>>     <item4/>
>>     <item5/>
>>     <item6/>
>>   </test2>
>> </data>
>> 
>> bindings
>> <xf:bind id="g1" nodeset="test1">
>>   <xf:bind id="i11" nodeset="item[@id='1']"
>> calculate="../item[@id='2']+../item[@id='3']" type="float"
>> readonly="true()"/>
>>   <xf:bind id="i12" nodeset="item[@id='2']" type="float"/>
>>   <xf:bind id="i13" nodeset="item[@id='3']"
>> calculate="../item[@id='4']+../item[@id='5']+../item[@id='6']"
>> type="float" readonly="true()"/>
>>   <xf:bind id="i14" nodeset="item[@id='4']" type="float"/>
>>   <xf:bind id="i15" nodeset="item[@id='5']" type="float"/>
>>   <xf:bind id="i16" nodeset="item[@id='6']" type="float"/>
>> </xf:bind>
>> <xf:bind id="g2" nodeset="test2">
>>   <xf:bind id="i21" nodeset="item1"
>> calculate="../item2+../item3" type="float" readonly="true()"/>
>>   <xf:bind id="i22" nodeset="item2" type="float"/>
>>   <xf:bind id="i23" nodeset="item3"
>> calculate="../item4+../item5+../item6" type="float"
>> readonly="true()"/>
>>   <xf:bind id="i24" nodeset="item4" type="float"/>
>>   <xf:bind id="i25" nodeset="item5" type="float"/>
>>   <xf:bind id="i26" nodeset="item6" type="float"/>
>> </xf:bind>
>> 
>> The problem is that for test1 when for example item[@id='4']
>> gets new value calculate for bind
>> i11 occures before calculate for bind i13. So item[@id='1'] calculated
>> on the base of old value for item[@id='3'].
>> For the test2 calculate sequense is correct: first calculate for i23 is 
>> evaluated
>> then for i21.
>> 
>> Why is it so. The only difference is that items in test1 are defined
>> by attribute values but not names.
>> 
>> Sample form is attached.
>> 
>> 
>> 
>> ------------------------------------------------------------------------
>> 
>>    Test 1  item 11  item 12  item 13  item 14  item 15  item 16 Test 2  item
>> 21  item 22 item 23 item 24 item 25 item 26 recalculate reset



JT> -------------------------------------------------------
JT> This SF.Net email is sponsored by xPML, a groundbreaking scripting language
JT> that extends applications into web and mobile media. Attend the live webcast
JT> and join the prime developer group breaking into this new coding territory!
JT> http://sel.as-us.falkag.net/sel?cmdlnk&kid0944&bid$1720&dat1642
JT> _______________________________________________
JT> Chiba-developer mailing list
JT> Chiba-developer-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@xxxxxxxxxxxxxxxx
JT> https://lists.sourceforge.net/lists/listinfo/chiba-developer



-- 
С уважением, Михаил Павлов.
mailto:MIC-B54ZLJp+iVcox3rIn2DAYQ@xxxxxxxxxxxxxxxx




-------------------------------------------------------
This SF.Net email is sponsored by xPML, a groundbreaking scripting language
that extends applications into web and mobile media. Attend the live webcast
and join the prime developer group breaking into this new coding territory!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid0944&bid$1720&dat1642



Try Searching:
servers, voip, java, networking, microsoft ...
<Prev in Thread] Current Thread [Next in Thread>