On Sat, Apr 26, 2014 at 8:25 PM, Thiago H de Paula Figueiredo <
thiag...@gmail.com> wrote:

> On Sat, 26 Apr 2014 13:33:03 -0300, Boris Horvat <horvat.z.bo...@gmail.com>
> wrote:
>
>  But is it expected for the things that are @Persist-ed to be shared in
>> each iteration?
>>
>
> What do you mean by shared? If you overwrite a @Persist'ed value, anything
> that reads it later, regardless of being in inside a loop or not, will read
> the same value. So, in your code as posted in this thread, when an event
> occurrs, you'll always get the value of the last item in the iteration.
> @Persist is basically reading and writing to an HttpSession attributed
> named [fully qualified page name]:[field name], when it's in a page, or
> [fully qualified page name].[full component id]:[field name].


I guess in my mind it is like creating 5 instance of the same component and
then each instance will have their own version of the property that is
persisted. But this appears to be my wrong interpretation



>
>
>  I will try to pass the client zone id to the context and to use it back
>> to refresh the proper zone (I did come up with same idea but I was thinking
>> that it is wrong path to follow)
>>
>
> Actually, that's the correct approach. It works in every situation and no
> session persistence needed. Win-win situation. :)


This is implemented and I am happy to say that it works and I am glad to
hear that it is a correct approach.

Thanks


>
>
> --
> Thiago H. de Paula Figueiredo
> Tapestry, Java and Hibernate consultant and developer
> http://machina.com.br
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
> For additional commands, e-mail: users-h...@tapestry.apache.org
>
>


-- 
Sincerely
*Boris Horvat*

Reply via email to