Board index » delphi » For Binh Ly - Automation Objects vs Standard COM Objects

For Binh Ly - Automation Objects vs Standard COM Objects

Hello Binh:

I've read your paper where you discuss a COM Object Hierarchy.  I used this
example to develop something similar, however, in my case I will only be
using this COM serve from a Delphi client.  Also I intend to always use
early binding (Interfaces only).  Since I will not be creating any VB
clients or calling the COM server via late binding, should I simply use a
standard COM object instead of an automation object?  Also my internal
classes are currently derived from TAutoIntfObject, if I go with a standard
COM object, should I have my internal classes derive from TInterfacedObject?
Does deriving from TAutoObject provide alot of overhead?

Any help or suggestions would be greatly appreciated.  Thanks

-Sal

 

Re:For Binh Ly - Automation Objects vs Standard COM Objects


I would just use Automation (TAutoObject/TAutoIntfObject) for the following
reasons:

1) Not much overhead
2) Safecall mapping is automatically implied and is convenient for your
Delphi client
3) Switching from TComObjects to TAutoObjects and the whole type library
later can be a lot of work.

--
have fun
Binh Ly
http://www.techvanguards.com

Quote
"Sal Mendoza" <salmend...@decadesoftware.com> wrote in message

news:3b5e4e83$1_1@dnews...
Quote
> Hello Binh:

> I've read your paper where you discuss a COM Object Hierarchy.  I used
this
> example to develop something similar, however, in my case I will only be
> using this COM serve from a Delphi client.  Also I intend to always use
> early binding (Interfaces only).  Since I will not be creating any VB
> clients or calling the COM server via late binding, should I simply use a
> standard COM object instead of an automation object?  Also my internal
> classes are currently derived from TAutoIntfObject, if I go with a
standard
> COM object, should I have my internal classes derive from
TInterfacedObject?
> Does deriving from TAutoObject provide alot of overhead?

> Any help or suggestions would be greatly appreciated.  Thanks

> -Sal

Other Threads