- Pretty-indenting code

git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@674 3ecf2c5c-341e-0410-92b4-d18e462d057c
This commit is contained in:
tchernobog 2006-06-29 08:44:30 +00:00
parent 7aecc910ba
commit 6b27a8461b
94 changed files with 3073 additions and 3066 deletions

View file

@ -33,106 +33,106 @@
namespace sgpem
{
enum policy_sorts_type
{
policy_sorts_threads,
policy_sorts_processes
};
enum policy_sorts_type
{
policy_sorts_threads,
policy_sorts_processes
};
class Policy;
/** \brief
It's a Strategy wich stay for a scheduling algorithm.
It implements the related scheduling policy.
Its goal is, usually, to keep a list of Schedulable objects
mantained in a SchedulableQueue.
*/
class SG_DLLEXPORT Policy
{
public:
virtual ~Policy();
/**
Initialize the inner components of the policy.
class Policy;
Because it's a pure virtual method, must be re-implemented
in concrete derived classes.
*/
virtual void configure() throw(UserInterruptException) = 0;
/** \brief
It's a Strategy wich stay for a scheduling algorithm.
It implements the related scheduling policy.
Its goal is, usually, to keep a list of Schedulable objects
mantained in a SchedulableQueue.
*/
class SG_DLLEXPORT Policy
{
public:
/**
Sort the \ref SchedulableQueue object that contain all the Schedulable objects
(Processes, Threads) still active managed by the scheduler.
virtual ~Policy();
Because it's a pure virtual method, must be re-implemented
in concrete derived classes.
*/
virtual void sort_queue() const throw(UserInterruptException) = 0;
/**
Initialize the inner components of the policy.
/**
Gets the unique identifier (id) of this Policy.
\return The Policy id.
*/
int get_id() const;
Because it's a pure virtual method, must be re-implemented
in concrete derived classes.
*/
virtual void configure() throw(UserInterruptException) = 0;
/**
Gets a string description of the policy.
/**
Sort the \ref SchedulableQueue object that contain all the Schedulable objects
(Processes, Threads) still active managed by the scheduler.
Because it's a pure virtual method, must be re-implemented
in concrete derived classes.
\return String description of the policy.
*/
virtual Glib::ustring get_description() const = 0;
Because it's a pure virtual method, must be re-implemented
in concrete derived classes.
*/
virtual void sort_queue() const throw(UserInterruptException) = 0;
virtual Glib::ustring get_name() const = 0;
/**
Gets the unique identifier (id) of this Policy.
\return The Policy id.
*/
int get_id() const;
/**
Tell if this policy is preemptible.
/**
Gets a string description of the policy.
Because it's a pure virtual method, must be re-implemented
in concrete derived classes.
\return True if this policy is preemptible.
*/
virtual bool is_pre_emptive() const throw(UserInterruptException) = 0;
Because it's a pure virtual method, must be re-implemented
in concrete derived classes.
\return String description of the policy.
*/
virtual Glib::ustring get_description() const = 0;
/**
Gets the time quantum for the policy.
virtual Glib::ustring get_name() const = 0;
Because it's a pure virtual method, must be re-implemented
in concrete derived classes.
\return Time quantum for the policy.
*/
virtual int get_time_slice() const throw(UserInterruptException) = 0;
/**
Tell if this policy is preemptible.
/**
Tell what kind of entities are scheduled by this policy.
Because it's a pure virtual method, must be re-implemented
in concrete derived classes.
\return True if this policy is preemptible.
*/
virtual bool is_pre_emptive() const throw(UserInterruptException) = 0;
Because it's a pure virtual method, must be re-implemented
in concrete derived classes.
\return A SortsType value identifying the desired type for the objects
composing the queue passed to the sort_queue method.
*/
virtual policy_sorts_type wants() const throw(UserInterruptException) = 0;
/**
Gets the time quantum for the policy.
virtual void activate() = 0;
Because it's a pure virtual method, must be re-implemented
in concrete derived classes.
\return Time quantum for the policy.
*/
virtual int get_time_slice() const throw(UserInterruptException) = 0;
virtual void deactivate() = 0;
/**
Gets the parameters related with this policy.
/**
Tell what kind of entities are scheduled by this policy.
Because it's a pure virtual method, must be re-implemented
in concrete derived classes.
\return The policy parameters.
*/
PolicyParameters& get_parameters();
Because it's a pure virtual method, must be re-implemented
in concrete derived classes.
\return A SortsType value identifying the desired type for the objects
composing the queue passed to the sort_queue method.
*/
virtual policy_sorts_type wants() const throw(UserInterruptException) = 0;
virtual void activate() = 0;
virtual void deactivate() = 0;
/**
Gets the parameters related with this policy.
Because it's a pure virtual method, must be re-implemented
in concrete derived classes.
\return The policy parameters.
*/
PolicyParameters& get_parameters();
protected:
PolicyParameters _parameters;
int _id;
};
protected:
PolicyParameters _parameters;
int _id;
};
}//~ namespace sgpem