activa / iridium

Iridium - Lightweight .NET ORM for mobile, desktop and server applications
MIT License
22 stars 8 forks source link

ObservableCollection<T> question #5

Closed kappesLab closed 6 years ago

kappesLab commented 6 years ago

What could be the best strategy to derive from IDataSet<T> an ObservableCollection<T> to use the binding of data with UI ?

activa commented 6 years ago

What's the use case you're looking for? If it's just for showing a list of records, you can simply instantiate an ObservableCollection and pass the dataset as the constructor parameter:

new ObservableCollection<Product>(db.Products) // db.Products is of type IDataSet<Product>

kappesLab commented 6 years ago

Ok, well.