Next Previous Up Top Contents Index

4.3 Mapping IDL to Common Lisp

4.3.4 Mapping for operations

The IDL operationcredit is mapped to the Common Lisp generic function:

op:credit

In IDL, thecredit operation is defined within theaccount interface, declaring it to be an operation onaccount 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 functionop:credit is an object of typeBankingDemo:account.

The operation'sin andinout arguments become the remaining parameters of the corresponding Common Lisp generic function. In this case, thecredit operation specifies a singlein parameter,in unsigned long amount, that determines the second and only other parameter,amount, of theop:credit generic function.

The operation's result type, and any other parameters declared asout orinout, become results of the corresponding Common Lisp generic function. In this case, because the result type ofcredit isvoid, and the operation has noout orinout parameters,op:credit has an empty result list.


Developing Component Software with CORBA - 22 Jan 1999

Next Previous Up Top Contents Index

Generated with Harlequin WebMaker