|
libutap
0.93
Uppaal Timed Automata Parser
|
DistanceCalculator is used in TargetFirst heuristic search order of Uppaal. More...
#include <signalflow.h>


Public Member Functions | |
| DistanceCalculator (const char *_title, TimedAutomataSystem &ta) | |
| virtual | ~DistanceCalculator () |
| void | addVariableNeedle (const char *var) |
| adds a variable needle to I/O map More... | |
| void | addProcessNeedle (const char *proc) |
| adds a variable needle to I/O map More... | |
| void | updateDistances () |
| Recalculates the distances to needles. More... | |
| uint32_t | getDistance (const char *element) |
| Finds a distance measure for given element. More... | |
| void | printForDot (std::ostream &os, bool ranked, bool erd, bool cEdged) override |
| Print I/O information in DOT format into given output stream. More... | |
Public Member Functions inherited from UTAP::SignalFlow | |
| SignalFlow (const char *_title, TimedAutomataSystem &ta) | |
| Analyse the system and extract I/O information: More... | |
| void | setVerbose (int verbose) |
| virtual | ~SignalFlow () |
| All strings are from TASystem (don't dispose TASystem before SignalFlow). More... | |
| void | printForTron (std::ostream &os) |
| Print I/O information in TRON format into given output stream. More... | |
| int32_t | visitEmptyStatement (EmptyStatement *stat) override |
| System visitor pattern extracts read/write information from UCode. More... | |
| int32_t | visitExprStatement (ExprStatement *stat) override |
| int32_t | visitForStatement (ForStatement *stat) override |
| int32_t | visitIterationStatement (IterationStatement *stat) override |
| int32_t | visitWhileStatement (WhileStatement *stat) override |
| int32_t | visitDoWhileStatement (DoWhileStatement *stat) override |
| int32_t | visitBlockStatement (BlockStatement *stat) override |
| int32_t | visitSwitchStatement (SwitchStatement *stat) override |
| int32_t | visitCaseStatement (CaseStatement *stat) override |
| int32_t | visitDefaultStatement (DefaultStatement *stat) override |
| int32_t | visitIfStatement (IfStatement *stat) override |
| int32_t | visitBreakStatement (BreakStatement *stat) override |
| int32_t | visitContinueStatement (ContinueStatement *stat) override |
| int32_t | visitReturnStatement (ReturnStatement *stat) override |
| int32_t | visitAssertStatement (UTAP::AssertStatement *stat) override |
Public Member Functions inherited from UTAP::StatementVisitor | |
| virtual | ~StatementVisitor () |
Protected Member Functions | |
| void | printProcsForDot (std::ostream &os, bool erd) override |
| void | printVarsForDot (std::ostream &os, bool ranked, bool erd) override |
Protected Member Functions inherited from UTAP::SignalFlow | |
| bool | checkParams (const symbol_t &s) |
| void | addChan (const std::string &, strs_t &, str2procs_t &) |
| void | addVar (const symbol_t &, str2strs_t &, str2procs_t &) |
| void | visitProcess (instance_t &) |
| void | visitExpression (const expression_t &) |
| void | pushIO () |
| void | popIO () |
| virtual void | printVarsWriteForDot (std::ostream &os) |
| virtual void | printVarsReadForDot (std::ostream &os) |
| virtual void | printChansOnEdgesForDot (std::ostream &os) |
| virtual void | printChansSeparateForDot (std::ostream &os, bool ranked, bool erd) |
Protected Attributes | |
| TimedAutomataSystem & | taSystem |
Protected Attributes inherited from UTAP::SignalFlow | |
| int | verbosity |
| const char * | title |
| procs_t | procs |
| str2procs_t | receivers |
| str2procs_t | transmitters |
| strs_t | processes |
| strs_t | channels |
| strs_t | variables |
| proc_t * | cTA |
| instance_t * | cP |
| const char * | cChan |
| std::string | chanString |
| bool | inp |
| bool | out |
| bool | sync |
| bool | paramsExpanded |
| std::stack< std::pair< bool, bool > > | ioStack |
| std::stack< exprref_t > | refparams |
| std::stack< exprref_t > | valparams |
Additional Inherited Members | |
Public Types inherited from UTAP::SignalFlow | |
| typedef std::set< const char *, const less_str > | strs_t |
| typedef std::map< const proc_t *, strs_t > | proc2strs_t |
| typedef std::map< const char *, strs_t > | str2strs_t |
| typedef std::set< proc_t * > | procs_t |
| typedef std::map< const char *, procs_t, less_str > | str2procs_t |
| typedef std::map< const symbol_t, expression_t > | exprref_t |
DistanceCalculator is used in TargetFirst heuristic search order of Uppaal.
Current implementation calculates complexity distances from a process to the given set of "needles" (e.g. variables or process location mentioned in query). In the future this can be refined to take the process-local information into account (e.g. calculate distance for individual edges within the process rather than just process).
Definition at line 266 of file signalflow.h.
|
inline |
Definition at line 299 of file signalflow.h.
References UTAP::SignalFlow::printForDot().

|
virtual |
Definition at line 1761 of file signalflow.cpp.
| void DistanceCalculator::addProcessNeedle | ( | const char * | proc | ) |
adds a variable needle to I/O map
Definition at line 1553 of file signalflow.cpp.
References UTAP::template_t::edges, UTAP::SignalFlow::processes, UTAP::SignalFlow::procs, UTAP::instance_t::templ, and UTAP::SignalFlow::transmitters.
Referenced by main().

| void DistanceCalculator::addVariableNeedle | ( | const char * | var | ) |
adds a variable needle to I/O map
Definition at line 1520 of file signalflow.cpp.
References UTAP::SignalFlow::variables.
| uint32_t DistanceCalculator::getDistance | ( | const char * | element | ) |
Finds a distance measure for given element.
Definition at line 1772 of file signalflow.cpp.
|
overridevirtual |
Print I/O information in DOT format into given output stream.
ranked – puts oposite "ranks" on variables and channels erd – puts boxes and diamonds rather than (compact) ellipses. cEdged – channels are printed on edges rather than separate nodes.
Reimplemented from UTAP::SignalFlow.
Definition at line 1784 of file signalflow.cpp.
References UTAP::SignalFlow::printForDot().

|
overrideprotectedvirtual |
Reimplemented from UTAP::SignalFlow.
Definition at line 1699 of file signalflow.cpp.
References UTAP::SignalFlow::procs.
|
overrideprotectedvirtual |
Reimplemented from UTAP::SignalFlow.
Definition at line 1726 of file signalflow.cpp.
References UTAP::SignalFlow::transmitters, and UTAP::SignalFlow::variables.
| void DistanceCalculator::updateDistances | ( | ) |
Recalculates the distances to needles.
Definition at line 1792 of file signalflow.cpp.
|
protected |
Definition at line 292 of file signalflow.h.