[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

[libvirt] ocaml: prototype bindings for event callbacks


I've made an prototype set of ocaml bindings for the libvirt event
mechanism -- here is what I've got so far.

It's possible to register for all the types supported by


I've not tested each type of event yet, but the basics are all working.

For every distinct callback function signature it maintains:

  1. OCaml: a hashtable mapping callback_id (int64) to a specific closure
  2. OCaml: a function registered with Callback.register
  3. C: a function registered with libvirt, which upcalls to OCaml

There's still some missing polish, for example I've not implemented a
means to actually deregister a callback :-) I thought it would be best
to get feedback on the overall approach, style of the mapping etc first.

Comments and criticism greatly appreciated!


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]