3
votes

Consuming Delphi interfaces in Dephi and C++
The Programming Works
– An object-oriented DLL written in Delphi exports functions with parameters of interface type. A code consuming such DLL can use an interface reference directly, but a better way is to write a wrapper type which incapsulates an interface reference. Let us consider as an example a simple interface IBytes designed to work with byte arrays: unit ITypes; interface type IBytes = interface function GetLength: Integer; procedure Append(B: Byte); procedure CopyTo(var C: IBytes); end; implementation end. The IBytes interface is implemented by the TByteObject class: unit ...
Statistics
|
Visits by Source |
User Actions |