The EiffelCOM Wizard can be used to add a COM interface to an existing Eiffel project. The advantage of that approach is that it doesn't require any knowledge about IDL. The EiffelCOM Wizard will take care of generating the IDL from the Eiffel facade class. The generated IDL will define one coclass containing one interface that corresponds to the contract view of the facade class.

Designing the Facade Class

The facade class should be designed so that it exposes the functionality of the Eiffel system that needs to be accessed from clients of the component. Only the public routines will be exported to the IDL and thus to clients (the class should not have any public attributes, see the list of requirements below).

There are some rules that the facade class must follow for the COM wizard to be able to generate correct IDL:

  • The facade class must have a creation procedure called make that does not take any argument. This is the procedure that will be called by the EiffelCOM runtime to initialize the Eiffel object when a COM call arrives from a client.
  • The facade class should not contain any public attribute, only routines can be exported to COM clients.
  • The facade class must belong to a successfully compiled Eiffel project.

See Also: How the EiffelCOM Wizard Works , Generated Files , Class Hierarchy , Adding a COM Interface to an Eiffel Project , Accessing a COM Component , Reusing a COM Component , Command Line Options

d94c4060-af70-930b-5023-1c2b2d069633
cached: 04/30/2017 10:52:06.000 PM