[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[news.eclipse.platform] Re: [Databinding] Making views synchronize with my data model

You can use databinding to achieve what you want. Once you bind a control/viewer to a data, changes in the data gets reflected in the control/viewer without any extra code. databinding is still under development toward a stable release but I am currently using it and has made my life much easier.

Ali.

Nacef LABIDI wrote:
Hi all,

I'm a newbie to eclipse RCP and I'm trying to develop a sort of bar chart viewer.

What my application is doing is loading the data parsed from an XML file into my data model (a root containing some ArrayLists : an ArrayList for each type of data). Then my perspective is containing a set of views in each view a TableViewer having its data provided by a different ContentProvider for each ArrayList of my data model.

What I want to realise is to make Actions do modifications on my data model, and I want my views to automatically update their display according to the changes that occured on the data model.

Do I have to implements Observer pattern for my own, or does the JFace contains something that does this.
I'm reading something about org.eclipse.jface.databinding but I don't know if this is the good way.