【发布时间】:2008-12-16 12:18:21
【问题描述】:
我有一个包含对象列表的类。修改列表时,在类中运行某些代码的最佳方法是什么?
class MyManagerClass
{
ArrayList list = new ArrayList(); // will likely be a different collection class
private OnItemAddedToList(object o)
{
// how to call this?
}
private OnItemRemovedFromList(object o)
{
// how to call this?
}
}
【问题讨论】:
标签: .net collections