Sorry, There is no way to do that but: define your own wait function. It is in fact very simple: check the file gecode/kernel/wait.hh and just extend the continuation called in the propagator UnaryWait. How to use it you can see in gecode/int/exec.cpp.
Maybe we should change our wait functions such that they do what you suggest anyway. No, we do not want to have dependencies on Boost, but as said you can do it yourself. Christian -- Christian Schulte, KTH, web.it.kth.se/~cschulte/ -----Original Message----- From: [email protected] [mailto:[email protected]] On Behalf Of Max Ostrowski Sent: Thursday, July 28, 2011 4:12 PM To: [email protected] Subject: [gecode-users] How to wait for a variable Hi, i want to use the wait function to get notified what a certain variable has been assigned. And i want to do this for some variables, to finally to something with them. so i want to have wait(*this,a,&foo); wait(*this,b,&foo); And in my function foo i want to add the variables into a list or something like this. void foo(Space&, Var a) { do something with a } but as foo does not get any information about which variable has been assigned i can not use it. Is there another method to find out/get notified when a variable has been assigned, without going through the list of variables and testing each of it. If the expected function would like to have a boost function pointer this would be great. Then you could bind additional information to figure out which variable. This would also be advantageous if you have several Spaces running in parallel, there is no easy way to figure out which one triggered the callback. Best, Max -- Empfehlen Sie GMX DSL Ihren Freunden und Bekannten und wir belohnen Sie mit bis zu 50,- Euro! https://freundschaftswerbung.gmx.de _______________________________________________ Gecode users mailing list [email protected] https://www.gecode.org/mailman/listinfo/gecode-users _______________________________________________ Gecode users mailing list [email protected] https://www.gecode.org/mailman/listinfo/gecode-users
