123456789101112131415161718192021222324252627282930313233(*
* nm_monitor.ml
* -------------
* Copyright : (c) 2011, Jeremie Dimino <jeremie@dimino.org>
* Licence : BSD3
*
* This file is a part of obus, an ocaml implementation of D-Bus.
*)openLwt_reactopenLwtopenOBus_valuemoduleString_map=Map.Make(String)letproperties_changedinterface=OBus_member.Signal.make~interface~member:"PropertiesChanged"~args:(arg1(Some"properties",C.dictC.stringC.variant))~annotations:[]letmonitorproxyinterfaceswitch=let%lwtevent=OBus_signal.connect~switch(OBus_signal.with_context(OBus_signal.make(properties_changedinterface)proxy))andcontext,dict=OBus_property.get_all_no_cacheproxyinterfaceinreturn(S.fold_s~eq:(String_map.equal(=))(funmap(context,updates)->return(OBus_property.update_mapcontextupdatesmap))(OBus_property.map_of_listcontextdict)event)