From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.1.3 (2006-06-01) on yquem.inria.fr X-Spam-Level: X-Spam-Status: No, score=0.0 required=5.0 tests=none autolearn=disabled version=3.1.3 X-Original-To: caml-list@yquem.inria.fr Delivered-To: caml-list@yquem.inria.fr Received: from concorde.inria.fr (concorde.inria.fr [192.93.2.39]) by yquem.inria.fr (Postfix) with ESMTP id 833E1BC4F for ; Mon, 21 Aug 2006 09:15:50 +0200 (CEST) Received: from pauillac.inria.fr (pauillac.inria.fr [128.93.11.35]) by concorde.inria.fr (8.13.6/8.13.6) with ESMTP id k7L7FoVN019509 for ; Mon, 21 Aug 2006 09:15:50 +0200 Received: from concorde.inria.fr (concorde.inria.fr [192.93.2.39]) by pauillac.inria.fr (8.7.6/8.7.3) with ESMTP id JAA16926 for ; Mon, 21 Aug 2006 09:15:49 +0200 (MET DST) Received: from mail.gmx.net (mail.gmx.de [213.165.64.20]) by concorde.inria.fr (8.13.6/8.13.6) with SMTP id k7L7FiKs019444 for ; Mon, 21 Aug 2006 09:15:49 +0200 Received: (qmail 8385 invoked by uid 0); 21 Aug 2006 07:15:32 -0000 Received: from 194.25.187.120 by www050.gmx.net with HTTP; Mon, 21 Aug 2006 09:15:32 +0200 (CEST) Content-Type: text/plain; charset="iso-8859-1" Date: Mon, 21 Aug 2006 09:15:32 +0200 From: "Michael Wohlwend" Message-ID: <20060821071532.32660@gmx.net> MIME-Version: 1.0 Subject: question about caml_get_public_method To: caml-list@inria.fr X-Authenticated: #20477425 X-Flags: 0001 X-Mailer: WWW-Mail 6100 (Global Message Exchange) X-Priority: 3 Content-Transfer-Encoding: 8bit X-Miltered: at concorde with ID 44E95DA6.000 by Joe's j-chkmail (http://j-chkmail.ensmp.fr)! X-Miltered: at concorde with ID 44E95DA0.000 by Joe's j-chkmail (http://j-chkmail.ensmp.fr)! X-Spam: no; 0.00; ocaml:01 ocaml:01 cheers:01 ihrer:98 isdn:98 70%:98 argument:02 caml:02 caml:02 callback:02 callback:02 external:02 external:02 initializer:05 function:08 if I want to connect a c++ method to a method of an ocaml class, I can choose between: a) in the initializer of the ocaml class use register_value to register a method (like self#some_method) and then calling an external function which caches the registered value and calls that method or b) calling an external function with the ocaml object as argument and then use caml_get_public_method, cache the method-id of the callback methods and use those to make the callback. Is this just a matter of taste which one to use? cheers Michael -- Der GMX SmartSurfer hilft bis zu 70% Ihrer Onlinekosten zu sparen! Ideal für Modem und ISDN: http://www.gmx.net/de/go/smartsurfer