From: Matt E. <me...@in...> - 2004-03-22 11:52:09
|
> and if you use the pre > Delphi 6 version of interfaces, they are reference counted.... just to clarify... delphi 4 and 5 forced all interfaces to be reference counted and have the mothods _addref and _release plus possibly one other. In Delphi 6 onwards, interfaces do not necessarily require this to be so... All D5 interfaces inherit from 'IUnknown', but iirc Delphi 6 onwards uses 'IInterface' or something, 'IUnknown' is a subclass of 'IInterface' that adds those methods. The original purpose of Interfaces was to simplify COM automation, but people started to use them for general programming. They work well, though there are quirks (be careful with ref counting!!) Matt |