define-
dispinterface
-method
method-spec
(
class-spec
. lambda-list
)
form*
=>
value
method-spec ::= method-name | ( interface-name method-name )
Specifies the method to be defined.
A symbol naming the method to define.
A symbol naming the interface of the method to define. This is only required if the implementation class class-name has more than one method with the given method-name .
Specifies the implementation class and variables bound to the object with in the form s.
A symbol which will be bound to the COM object whose method is being invoked.
A symbol naming the COM implementation class for which this method is defined.
A simple lambda list. That is, a list of parameter names.
Forms which implement the method. The value of the final form is returned as the result of the method.
The value to be returned to the caller.
The macro
define-dispinterface-method
defines a
dispinterface
method that implements the method
method-name
for the Automation implementation class
class-name
. The extended
method-spec
syntax is required if
class-name
implements more than one interface with a method called
method-name
(analogous to the C++ syntax
InterfaceName::MethodName
).
The symbol this is bound to the instance of the Automation implementation class on which the method is being invoked.
The number of parameter in
lambda-list
must match the declaration in the type library. Each
in
and
in-out
parameter is bound to the value passed to IDispatch::Invoke, converted to the type specified by the method declaration and then converted to Lisp objects as specified in Data conversion when calling Automation methods. For missing values the value of the parameter is
:not-found
. For
out
and
in-out
arguments, the corresponding parameter should be set by the forms to contain the value to be returned to the caller and will be converted to an automation value as specified in Data conversion when calling Automation methods.
The value should be a value which can be converted to the appropriate return type as the primary value of the method and will be converted to an automation value as specified in Data conversion when calling Automation methods. It is ignored for methods that are declared as returning void.
Note: the define-com-method macro should be used to implement methods in dual interfaces.