Main Page | Namespace List | Class Hierarchy | Class List | File List | Namespace Members | Class Members | File Members

Broker::Policy Interface Reference

Inheritance diagram for Broker::Policy:

Inheritance graph
[legend]
List of all members.

Detailed Description

A Policy provides an interface for objects that can manage contention for a resource.

See also:
StrictPolicy


Public Member Functions

void AddTask (in Task new_task)
 Add a task to an active policy.

void RemoveTask (in Task added_task)
 Remove a task from an active policy.

void Activate (in TaskList tasks)
 Activate the policy.

void Deactivate ()
 Deactivate an active policy.

void ChangeTaskCPU (in RealTimeTask task, in unsigned long ct, in unsigned long status, in unsigned long advice) raises (InvalidState)

Public Attributes

readonly attribute string Name
 The name of the policy.


Member Function Documentation

void Broker::Policy::Activate in TaskList  tasks  ) 
 

Activate the policy.

NOTE: The policy is expected to discover and adjust the scheduling parameters of any currently executing tasks.

See also:
Deactivate
Parameters:
tasks The list of tasks the policy needs to manage.
Exceptions:
CORBA::BAD_INV_ORDER if the method is called without intervening calls to Deactivate().

void Broker::Policy::AddTask in Task  new_task  ) 
 

Add a task to an active policy.

NOTE: This method will be called before the reservation is made, giving the policy a chance to adjust any values.

See also:
RemoveTask
Parameters:
new_task The newly created Task object.
Exceptions:
CORBA::BAD_PARAM if task is nil.
CORBA::BAD_PARAM if task has already been added.
CORBA::BAD_INV_ORDER if the method is called without Activate() being called first.

void Broker::Policy::ChangeTaskCPU in RealTimeTask  task,
in unsigned long  ct,
in unsigned long  status,
in unsigned long  advice
raises (InvalidState)
 

Parameters:
task The Task object requesting a CPU time change.
ct The Task's current CPU time.
status The status value reported by Task.ReportCPU().
advice The CPU time advice from the Task object.

void Broker::Policy::Deactivate  ) 
 

Deactivate an active policy.

NOTE: The policy should change any scheduling parameters of the currently executing tasks, the next policy to be activated will handle any changes.

See also:
Deactivate
Exceptions:
CORBA::BAD_INV_ORDER if the method is called on an inactive policy.

void Broker::Policy::RemoveTask in Task  added_task  ) 
 

Remove a task from an active policy.

NOTE: This method will be called after the reservation has been destroyed, so it can safely reallocate the newly freed CPU time.

See also:
AddTask
Parameters:
added_task The task to remove.
Exceptions:
CORBA::BAD_PARAM if task is nil.
CORBA::BAD_PARAM if task has already been removed.
CORBA::BAD_INV_ORDER if the method is called without Activate() being called first.


Member Data Documentation

readonly attribute string Broker::Policy::Name
 

The name of the policy.

Mostly useful for debugging.


The documentation for this interface was generated from the following file:
Generated on Mon Dec 1 16:22:45 2003 for CPUBroker by doxygen 1.3.4