Reputation: 21
I have a following problem:
D<T>
, that implements interface Ic and calls into 3. Exe's Ia's and Ib's implementations.D<E>
)At run-time happens following: Exe loads Dll2 (several instances) and instantiates E providing it with pointers to its Ia and Ib pointers. Exe "obtains" Ic pointer from Dll2.
Now, I have to allow implementation of Dll2(s) in C# so that Exe can call into Dll2's Ic impl. and Dll2 cann call back to Exe's Ia and Ib i-faces. Further restriction that I don't have to recompile Exe and Dll1 each time when new Dll2 implementation pops up.
Is it possible to implement something like this ?
Upvotes: 2
Views: 246
Reputation: 613382
I think you are going to have to move away from inheritance which is already a rather fragile tool when applied across module boundaries.
I'd point you towards COM. Managed code can expose their interfaces as COM objects and C++ can consume them. And vice versa.
Upvotes: 5