中国开发网: 论坛: 程序员情感CBD: 贴子 692572
好望角
【技术贴】C#问题3
类接口是否支持成员变量实现?类似于Delphi的implementation?

type
IMyInterface = interface
procedure P1;
procedure P2;
end;

TMyClass = class(TObject, IMyInterface)
FMyInterface: IMyInterface;
property MyInterface: IMyInterface read FMyInterface implements IMyInterface;
end;

相关信息:


欢迎光临本社区,您还没有登录,不能发贴子。请在 这里登录