Simple question. Using Delphi, code first. Instead implementing the event interface like this:
TFormMain = class(TForm, IEvents)
i would like to have the interface as variable:
TFormMain = class(TForm) private FEventInterface: IEvents; end procedure TFormMain.FormCreate(Sender: TObject); begin // FEventInterface:= how to do this? end;
Is this possible?
The reason is i have to write a huge testcase with a local IEvents implementation. And this should be possible switching by configuration. I did it already with the service interfaces. But i’m stuck here with the event interface.