You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tapestry.apache.org by Nicholoz Koka Kiknadze <ki...@hotmail.com> on 2004/12/01 14:19:55 UTC

Component change recording

Hello,

Think the problem I'm looking into is quite common for most newbie's and
there should be some 'correct' way of handling it.

I have object hierarchy mapped to component hierarchy presented on my page.
User updates any component and hits save to record changes to persistent
storage (database in my case). Now I need to know which objects in the
hierarchy have been actually changed not to issue redundant update
statements. Currently I just have persistent page property 'oldValue' and in
formSubmit listener I walk my 'newValue' object graph and compare each
object to the corresponding old values (brrr, had to implement 'equals' for
all of them).

Ideally I'd like to be able to set 'dirty' flag for each edited object in
the corresponding Component (and hopefully avoiding implementing equals()).
Or maybe there's some better approach?

Tya
Nicholoz Koka Kiknadze


---------------------------------------------------------------------
To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tapestry-user-help@jakarta.apache.org