[fpc-devel] interfaces vs classes in dll

Michael Van Canneyt michael at freepascal.org
Thu Nov 29 21:33:19 CET 2007



On Thu, 29 Nov 2007, Mattias Gaertner wrote:

> Lazarus has the IDEIntf, the API for IDE plugins.
> 
> What is better in this case: classes or interfaces?

Classes:
- No reference counting mess. 
- Easier to grasp conceptually.
- You can use ansistrings. Interfaces require widestrings. (olestrings to be exact)

> What if someday there are packages? 

It'll work transparantly.

> What if someday there is a closed source dll plugin?

If it is a package, there is no problem.

Michael.



More information about the fpc-devel mailing list