On 09/21/2010 11:57 AM, jacob wrote: > > Sorry, should have been more clear the first time.... > > I want to present to my users (client side) collection of objects (rows). > This collection however can change over time server side so I would like to > synchronize it with clients. As mentioned before I'm using table to display > my collection and I poll server from time to time to see if anything was > removed from collection - if there were changes a delta is send to client > and removed from the table. In the mean time however new items could have > been added on the server so when I remove some row client side I would like > to check for next couple of rows from lastIndex and add them to table at the > end (say lastIndex + newRows(upto 50)) without the need to clear whole > cache.
Right. > > A shorter way of describing it - I'm trying to implement queue using table > and remote model. Small modification is that elements can be removed not > only from head of queue but from the middle as well, therefore I'm polling > for removed objects. I think this metaphor misses the point. You're not implementing a queue, you want to implement a synchronized model. You can use a queue to do that, but the aim is to synchronize data. Removing from the middle of a queue only means processing some queue entries earlier, and does not relate to removing data from the model. > Yes, from the server. The row would be *inserted* on the server but at the > end, so as soon I remove something on client side I want to get some more > rows from the end without clearing cache. But that is easy. You can removeRow on the client, and for the new rows you just request the next couple of higher indexes from the server. Both should be possible without clearing the cache (unless, of course, you request too many new rows so old rows will be thrown out of the cache to make space; but that's also incremental). T. ------------------------------------------------------------------------------ Start uncovering the many advantages of virtual appliances and start using them to simplify application deployment and accelerate your shift to cloud computing. http://p.sf.net/sfu/novell-sfdev2dev _______________________________________________ qooxdoo-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel
