libutap  0.93
Uppaal Timed Automata Parser
UTAP::template_t Struct Reference

#include <system.h>

Inheritance diagram for UTAP::template_t:
Collaboration diagram for UTAP::template_t:

Public Member Functions

int addDynamicEval (expression_t t)
 
std::vector< expression_t > & getDynamicEval ()
 
state_taddLocation (const std::string &, expression_t inv, expression_t er)
 Add another location to template. More...
 
branchpoint_taddBranchpoint (const std::string &)
 Add another branchpoint to template. More...
 
edge_taddEdge (symbol_t src, symbol_t dst, bool type, const std::string &actname)
 Add edge to template. More...
 
instanceLine_taddInstanceLine ()
 Add another instance line to template. More...
 
message_taddMessage (symbol_t src, symbol_t dst, int loc, bool pch)
 Add message to template. More...
 
condition_taddCondition (std::vector< symbol_t > anchors, int loc, bool pch, bool isHot)
 Add condition to template. More...
 
update_taddUpdate (symbol_t anchor, int loc, bool pch)
 Add update to template. More...
 
bool isInvariant ()
 return true if the LSC is of invariant mode More...
 
const std::vector< simregion_tgetSimregions ()
 returns the simregions of an LSC scenario. More...
 
bool getCondition (instanceLine_t *instance, int y, condition_t *&simCondition)
 gets the condition on the given instance, at y location, returns false if there isn't any More...
 
bool getUpdate (instanceLine_t *instance, int y, update_t *&simUpdate)
 gets the update on the given instance at y location, returns false if there isn't any More...
 
bool getUpdate (const std::vector< instanceLine_t *> &instances, int y, update_t *&simUpdate)
 
- Public Member Functions inherited from UTAP::instance_t
std::string writeMapping () const
 
std::string writeParameters () const
 
std::string writeArguments () const
 
- Public Member Functions inherited from UTAP::declarations_t
bool addFunction (type_t type, const std::string &, function_t *&)
 Add function declaration. More...
 
std::string toString (bool global=false) const
 The following methods are used to write the declarations in an XML file. More...
 
std::string getConstants () const
 
std::string getTypeDefinitions () const
 
std::string getVariables (bool global) const
 
std::string getFunctions () const
 

Public Attributes

symbol_t init
 The initial location. More...
 
frame_t templateset
 Template set decls. More...
 
std::deque< state_tstates
 Locations. More...
 
std::deque< branchpoint_tbranchpoints
 Branchpoints. More...
 
std::deque< edge_tedges
 Edges. More...
 
std::vector< expression_tdynamicEvals
 
bool isTA
 
std::deque< instanceLine_tinstances
 Instance Lines. More...
 
std::deque< message_tmessages
 Messages. More...
 
std::deque< update_tupdates
 Updates. More...
 
std::deque< condition_tconditions
 Conditions. More...
 
std::string type
 
std::string mode
 
bool hasPrechart
 
bool dynamic
 
int dynindex
 
bool isDefined
 
- Public Attributes inherited from UTAP::instance_t
symbol_t uid
 The name. More...
 
frame_t parameters
 The parameters. More...
 
std::map< symbol_t, expression_tmapping
 The arguments. More...
 
size_t arguments
 
size_t unbound
 
struct template_ttempl
 
std::set< symbol_trestricted
 Restricted variables. More...
 
- Public Attributes inherited from UTAP::declarations_t
frame_t frame
 
std::list< variable_tvariables
 Variables. More...
 
std::list< function_tfunctions
 Functions. More...
 
std::list< progress_tprogress
 Progress measures. More...
 
std::list< iodecl_tiodecl
 
std::list< gantt_tganttChart
 

Detailed Description

Definition at line 354 of file system.h.

Member Function Documentation

◆ addBranchpoint()

branchpoint_t & template_t::addBranchpoint ( const std::string &  )

Add another branchpoint to template.

Definition at line 308 of file system.cpp.

References UTAP::branchpoint_t::bpNr, UTAP::Constants::BRANCHPOINT, UTAP::type_t::createPrimitive(), and UTAP::branchpoint_t::uid.

Referenced by UTAP::SystemBuilder::procBranchpoint().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ addCondition()

condition_t & template_t::addCondition ( std::vector< symbol_t anchors,
int  loc,
bool  pch,
bool  isHot 
)

Add condition to template.

Definition at line 398 of file system.cpp.

References UTAP::condition_t::nr.

Referenced by UTAP::SystemBuilder::procMessage().

Here is the caller graph for this function:

◆ addDynamicEval()

int UTAP::template_t::addDynamicEval ( expression_t  t)
inline

Definition at line 364 of file system.h.

◆ addEdge()

edge_t & template_t::addEdge ( symbol_t  src,
symbol_t  dst,
bool  type,
const std::string &  actname 
)

Add edge to template.

Definition at line 325 of file system.cpp.

References edges, UTAP::symbol_t::getData(), UTAP::symbol_t::getType(), and UTAP::type_t::isLocation().

Referenced by UTAP::SystemBuilder::procEdgeBegin().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ addInstanceLine()

instanceLine_t & template_t::addInstanceLine ( )

Add another instance line to template.

Definition at line 357 of file system.cpp.

References UTAP::instanceLine_t::instanceNr.

Referenced by UTAP::SystemBuilder::procInstanceLine().

Here is the caller graph for this function:

◆ addLocation()

state_t & template_t::addLocation ( const std::string &  ,
expression_t  inv,
expression_t  er 
)

Add another location to template.

Definition at line 287 of file system.cpp.

References UTAP::type_t::createPrimitive(), UTAP::state_t::exponentialRate, UTAP::state_t::invariant, UTAP::Constants::LOCATION, UTAP::state_t::locNr, and UTAP::state_t::uid.

Referenced by UTAP::SystemBuilder::procState().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ addMessage()

message_t & template_t::addMessage ( symbol_t  src,
symbol_t  dst,
int  loc,
bool  pch 
)

Add message to template.

Definition at line 374 of file system.cpp.

References UTAP::symbol_t::getData(), and UTAP::message_t::nr.

Referenced by UTAP::SystemBuilder::procMessage().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ addUpdate()

update_t & template_t::addUpdate ( symbol_t  anchor,
int  loc,
bool  pch 
)

Add update to template.

Definition at line 387 of file system.cpp.

References UTAP::symbol_t::getData(), and UTAP::update_t::nr.

Referenced by UTAP::SystemBuilder::procLscUpdate().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ getCondition()

bool template_t::getCondition ( instanceLine_t instance,
int  y,
condition_t *&  simCondition 
)

gets the condition on the given instance, at y location, returns false if there isn't any

Definition at line 594 of file system.cpp.

References UTAP::condition_t::anchors, UTAP::instanceLine_t::instanceNr, and UTAP::condition_t::location.

◆ getDynamicEval()

std::vector<expression_t>& UTAP::template_t::getDynamicEval ( )
inline

Definition at line 369 of file system.h.

◆ getSimregions()

const vector< simregion_t > template_t::getSimregions ( )

returns the simregions of an LSC scenario.

A simregion is a simultaneous region containing 1 or 0 message, 1 or 0 update and 1 or 0 condition, at the same location. a message, update or condition must be in only one simregion.

we copy the messages, conditions and updates from the scenario

iterates over messages

we give priority to the condition on the target, if there is also one in the source, it must be part of another simregion

iterates over remaining conditions

iterates over remaining updates

Definition at line 460 of file system.cpp.

References UTAP::condition_t::anchors, UTAP::simregion_t::condition, conditions_nr(), UTAP::message_t::dst, UTAP::message_t::location, UTAP::condition_t::location, UTAP::simregion_t::message, messages_nr(), UTAP::condition_t::nr, UTAP::update_t::nr, UTAP::simregion_t::nr, UTAP::simregion_t::setCondition(), UTAP::simregion_t::setMessage(), UTAP::simregion_t::setUpdate(), UTAP::message_t::src, UTAP::simregion_t::update, and updates_nr().

Here is the call graph for this function:

◆ getUpdate() [1/2]

bool template_t::getUpdate ( instanceLine_t instance,
int  y,
update_t *&  simUpdate 
)

gets the update on the given instance at y location, returns false if there isn't any

Definition at line 623 of file system.cpp.

References UTAP::update_t::anchor, UTAP::instanceLine_t::instanceNr, and UTAP::update_t::location.

◆ getUpdate() [2/2]

bool UTAP::template_t::getUpdate ( const std::vector< instanceLine_t *> &  instances,
int  y,
update_t *&  simUpdate 
)

◆ isInvariant()

bool template_t::isInvariant ( )

return true if the LSC is of invariant mode

Definition at line 890 of file system.cpp.

Member Data Documentation

◆ branchpoints

std::deque<branchpoint_t> UTAP::template_t::branchpoints

Branchpoints.

Definition at line 359 of file system.h.

◆ conditions

std::deque<condition_t> UTAP::template_t::conditions

Conditions.

Definition at line 384 of file system.h.

◆ dynamic

bool UTAP::template_t::dynamic

Definition at line 388 of file system.h.

Referenced by UTAP::TypeChecker::checkExpression().

◆ dynamicEvals

std::vector<expression_t> UTAP::template_t::dynamicEvals

Definition at line 361 of file system.h.

◆ dynindex

int UTAP::template_t::dynindex

Definition at line 389 of file system.h.

◆ edges

std::deque<edge_t> UTAP::template_t::edges

◆ hasPrechart

bool UTAP::template_t::hasPrechart

Definition at line 387 of file system.h.

Referenced by UTAP::SystemBuilder::hasPrechart().

◆ init

symbol_t UTAP::template_t::init

The initial location.

Definition at line 356 of file system.h.

Referenced by UTAP::XMLWriter::init(), and UTAP::SystemBuilder::procStateInit().

◆ instances

std::deque<instanceLine_t> UTAP::template_t::instances

Instance Lines.

Definition at line 381 of file system.h.

◆ isDefined

bool UTAP::template_t::isDefined

◆ isTA

bool UTAP::template_t::isTA

Definition at line 362 of file system.h.

Referenced by UTAP::XMLWriter::taTempl().

◆ messages

std::deque<message_t> UTAP::template_t::messages

Messages.

Definition at line 382 of file system.h.

◆ mode

std::string UTAP::template_t::mode

Definition at line 386 of file system.h.

◆ states

std::deque<state_t> UTAP::template_t::states

Locations.

Definition at line 358 of file system.h.

Referenced by UTAP::XMLWriter::taTempl(), and UTAP::SignalFlow::visitProcess().

◆ templateset

frame_t UTAP::template_t::templateset

Template set decls.

Definition at line 357 of file system.h.

◆ type

std::string UTAP::template_t::type

Definition at line 385 of file system.h.

◆ updates

std::deque<update_t> UTAP::template_t::updates

Updates.

Definition at line 383 of file system.h.


The documentation for this struct was generated from the following files: