delegate void FoundOperation();
class BookStore //作者A
{
FoundOperation f=new FoundOperation(otherclass.fop) //注意
public static void Main()
{
find();
}
public void find()
{
.......
f(); //通过代理调用 otherclass里方法里具体实现什么本身是不知道.只知道有这个一样签名.
}
}
}
class otherclass //作者B
{
public static void fop()
{
.....
}
}