I am working with DevForce Silverlight in a simple demo application. In my demo app I display a Silverlight treeview control that is bound to an IEnumerable collection ("Facilities") that was returned from an EntityQuery. I have modified the "Facility" partial class that was generated by the DevForce Object Mapper to inherit from my own interface ITreeViewNode in order to make the binding generic (we plan on ultimately binding many different types to the treeview).
For demo purposes I have now added a button control that will update the caption property of the selected node ("Facility") in the treeview when clicked. If I examine the cache, I see that the caption property of the entity has indeed been changed. What is the recommended way to keep the treeview control in sync with changes made to the collection/cache?
Do I need to re-fetch the data or I was thinking I could convert the IEnumerable collection into an ObservableCollection and then modify the partial entity classes generated by the DevForce Object Mapper to inherit from INotifyPropertyChanged. If that is the case though I think I will need to modify every object that is modeled though. Is this built-in to the DevForce model somehow that I can take advantage of? I have to admit I am confused here with the DevForce model in the picture and any guidance would be appreciated.