开发者

How to track if (List<T>)collection is modified?

I have a my custom collection derived from List(.MyItem.)

I want to trace 开发者_如何学Cif my collection is modified, how can I do that?

I am able to track Add Remove operations etc...by implement new definition of them but I don't see any method in List that gives me opportunity to track if collection is modified...


Take a look at a new type called ObservableCollection<T>. It has built in notification of changes, and it should be fairly simple to change your base class to this from list as both are very similar.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜