- Incapsulate code so that the hack we previously used in CPUPoliciesGatekeeper isn't needed anymore

- Now CPUPolicy has a callback method for scripting languages, but it is up to derived classes to take
mutexes and set the value when needed (maybe we can improve this?)


git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@862 3ecf2c5c-341e-0410-92b4-d18e462d057c
This commit is contained in:
tchernobog 2006-08-14 14:28:41 +00:00
parent 390af1f09d
commit 45ef305a1b
7 changed files with 80 additions and 39 deletions

View file

@ -24,6 +24,7 @@
#include "config.h"
#include <Python.h>
#include <glibmm/thread.h>
#include <glibmm/ustring.h>
#include <iostream>
@ -63,7 +64,7 @@ namespace sgpem
*/
Glib::ustring get_description() const;
Glib::ustring get_name() const;
Glib::ustring get_name() const;
/**
\returns \c TRUE if the policy is preemptive.
@ -87,6 +88,8 @@ namespace sgpem
void wait_unlock() const throw(UserInterruptException, MalformedPolicyException);
static std::string get_exception_information();
static Glib::StaticRecMutex _mtx;
PyObject* _upolicy_dict;
PyObject* _adapter;