All Manuals > Developing Component Software with CORBA > 4 Writing and Compiling IDL > 4.3 Mapping IDL to Common Lisp

NextPrevUpTopContentsIndex

4.3.4 Mapping for operations

The IDL operation credit is mapped to the Common Lisp generic function:

op:credit

In IDL, the credit operation is defined within the account interface, declaring it to be an operation on account objects. The Common Lisp language binding adopts the convention that an operation's target object should be passed as the first argument of the corresponding Common Lisp generic function. Thus the first parameter of the generic function op:credit is an object of type BankingDemo:account .

The operation's in and inout arguments become the remaining parameters of the corresponding Common Lisp generic function. In this case, the credit operation specifies a single in parameter, in unsigned long amount , that determines the second and only other parameter, amount , of the op:credit generic function.

The operation's result type, and any other parameters declared as out or inout , become results of the corresponding Common Lisp generic function. In this case, because the result type of credit is void , and the operation has no out or inout parameters, op:credit has an empty result list.


Developing Component Software with CORBA - 29 Jul 2010

NextPrevUpTopContentsIndex