DREAM::UppaalInterpreter Class Reference

The UppaalInterpreter class generates Uppaal XML input from the DREAM models. More...

#include <UppaalInterpreter.h>

List of all members.

Public Member Functions

 UppaalInterpreter (DREAM::System *system_ptr)
 Constructor.
 ~UppaalInterpreter ()
 Destructor.
void visitor_uppaal (char *outputFile)
 Generates the Uppaal XML system description.
void visitor_uppaaltemplate (char *outputFile)
 Generates the Uppaal XML templates.

Private Member Functions

std::string create_fixedpriority_guard (NODE_MAP *node_map, std::string scheduler_id, const DREAM::Node *const node)
 Creates guard condition to model fixed-priority scheduling based on priorities.
bool highestpriority (DREAM::Node *task_ptr)
 Determines whether the Task is the highest priority Task in the Scheduler.
bool lowestpriority (DREAM::Node *task_ptr)
 Determines whether the Task is the lowest priority Task in the Scheduler.

Private Attributes

DREAM::Systemsystem_ptr_
 Pointer to store the DREAM system.
std::string filename_
 String storing the name of the generated file.


Detailed Description

The UppaalInterpreter class generates Uppaal XML input from the DREAM models.

Definition at line 60 of file UppaalInterpreter.h.


Constructor & Destructor Documentation

DREAM::UppaalInterpreter::UppaalInterpreter ( DREAM::System system_ptr  ) 

Constructor.

Parameters:
system_ptr is the pointer to the system to be output.

Definition at line 56 of file UppaalInterpreter.cpp.

DREAM::UppaalInterpreter::~UppaalInterpreter (  ) 

Destructor.

Definition at line 61 of file UppaalInterpreter.cpp.


Member Function Documentation

void DREAM::UppaalInterpreter::visitor_uppaal ( char *  outputFile  ) 

Generates the Uppaal XML system description.

It uses the visitor pattern to get the data from the DREAM models.

Parameters:
outputFile specifies the output file to be generated.

Definition at line 111 of file UppaalInterpreter.cpp.

Referenced by main().

void DREAM::UppaalInterpreter::visitor_uppaaltemplate ( char *  outputFile  ) 

Generates the Uppaal XML templates.

It uses the visitor pattern to get the data from the DREAM models.

Parameters:
outputFile specifies the output file to be generated.

Definition at line 190 of file UppaalInterpreter.cpp.

Referenced by main().

std::string DREAM::UppaalInterpreter::create_fixedpriority_guard ( NODE_MAP node_map,
std::string  scheduler_id,
const DREAM::Node *const  node 
) [private]

Creates guard condition to model fixed-priority scheduling based on priorities.

Parameters:
node_map contains the Nodes in the Scheduler.
scheduler_id specifies the Scheduler id.
node is used to calculate the priority level used in the guard.

Definition at line 65 of file UppaalInterpreter.cpp.

References DREAM::Node::id(), DREAM::Node::priority(), and DREAM::Node::subpriority().

bool DREAM::UppaalInterpreter::highestpriority ( DREAM::Node task_ptr  )  [private]

Determines whether the Task is the highest priority Task in the Scheduler.

Used to reduce state space caused by preemptions.

Parameters:
task_ptr is a pointer to the Task to be checked.
Returns:
true if the Task is the highest priority Task in the Scheduler, false otherwise.

Definition at line 101 of file UppaalInterpreter.cpp.

References DREAM::Scheduler::highestpriority(), and DREAM::Node::scheduler().

bool DREAM::UppaalInterpreter::lowestpriority ( DREAM::Node task_ptr  )  [private]

Determines whether the Task is the lowest priority Task in the Scheduler.

Used to reduce state space caused by preemptions.

Parameters:
task_ptr is a pointer to the Task to be checked.
Returns:
true if the Task is the lowest priority Task in the Scheduler, false otherwise.

Definition at line 106 of file UppaalInterpreter.cpp.

References DREAM::Scheduler::lowestpriority(), and DREAM::Node::scheduler().


Member Data Documentation

DREAM::System* DREAM::UppaalInterpreter::system_ptr_ [private]

Pointer to store the DREAM system.

Definition at line 118 of file UppaalInterpreter.h.

std::string DREAM::UppaalInterpreter::filename_ [private]

String storing the name of the generated file.

Definition at line 121 of file UppaalInterpreter.h.


The documentation for this class was generated from the following files:
Generated on Fri Jul 27 18:30:04 2007 for DREAM by  doxygen 1.5.1