libutap  0.93
Uppaal Timed Automata Parser
UTAP::ExpressionBuilder Class Reference

Partial implementation of the builder interface: The ExpressionBuilder implements all expression related methods. More...

#include <expressionbuilder.h>

Inheritance diagram for UTAP::ExpressionBuilder:
Collaboration diagram for UTAP::ExpressionBuilder:

Classes

class  ExpressionFragments
 
class  TypeFragments
 

Public Member Functions

 ExpressionBuilder (TimedAutomataSystem *)
 
ExpressionFragmentsgetExpressions ()
 
void addPosition (uint32_t position, uint32_t offset, uint32_t line, const std::string &path) override
 Add mapping from an absolute position to a relative XML element. More...
 
void handleError (const std::string &) override
 
void handleWarning (const std::string &) override
 
void typeDuplicate () override
 Duplicate type at the top of the type stack. More...
 
void typePop () override
 Pop type at the topof the type stack. More...
 
void typeBool (PREFIX) override
 Called whenever a boolean type is parsed. More...
 
void typeInt (PREFIX) override
 Called whenever an integer type is parsed. More...
 
void typeDouble (PREFIX) override
 Called whenever a double type is parsed. More...
 
void typeBoundedInt (PREFIX) override
 Called whenever an integer type with a range is parsed. More...
 
void typeChannel (PREFIX) override
 Called whenever a channel type is parsed. More...
 
void typeClock (PREFIX) override
 Called whenever a clock type is parsed. More...
 
void typeVoid () override
 Called whenever a void type is parsed. More...
 
void typeScalar (PREFIX) override
 Called whenever a scalar type is parsed. More...
 
void typeName (PREFIX, const char *name) override
 Called when a type name has been parsed. More...
 
bool isType (const char *) override
 Must return true if and only if name is registered in the symbol table as a named type, for instance, "int" or "bool" or a user defined type. More...
 
void exprTrue () override
 
void exprFalse () override
 
void exprDouble (double) override
 
void exprId (const char *varName) override
 
void exprNat (int32_t) override
 
void exprCallBegin () override
 
void exprCallEnd (uint32_t n) override
 
void exprArray () override
 
void exprPostIncrement () override
 
void exprPreIncrement () override
 
void exprPostDecrement () override
 
void exprPreDecrement () override
 
void exprAssignment (Constants::kind_t op) override
 
void exprUnary (Constants::kind_t unaryop) override
 
void exprBinary (Constants::kind_t binaryop) override
 
void exprNary (Constants::kind_t op, uint32_t num) override
 
void exprScenario (const char *name) override
 
expression_t exprScenario ()
 
void exprTernary (Constants::kind_t ternaryop, bool firstMissing) override
 
void exprInlineIf () override
 
void exprComma () override
 
void exprDot (const char *) override
 
void exprDeadlock () override
 
void exprForAllBegin (const char *name) override
 
void exprForAllEnd (const char *name) override
 
void exprExistsBegin (const char *name) override
 
void exprExistsEnd (const char *name) override
 
void exprSumBegin (const char *name) override
 
void exprSumEnd (const char *name) override
 
void exprBuiltinFunction1 (Constants::kind_t) override
 
void exprBuiltinFunction2 (Constants::kind_t) override
 
void exprBuiltinFunction3 (Constants::kind_t) override
 
void exprSMCControl () override
 
void exprProbaQualitative (Constants::kind_t, Constants::kind_t, double) override
 
void exprProbaQuantitative (Constants::kind_t) override
 
void exprProbaCompare (Constants::kind_t, Constants::kind_t) override
 
void exprProbaExpected (const char *aggregatingOp) override
 
void exprSimulate (int, bool=false, int=0) override
 
void exprMitlFormula () override
 
void exprMitlUntil (int, int) override
 
void exprMitlRelease (int, int) override
 
void exprMitlDisj () override
 
void exprMitlConj () override
 
void exprMitlNext () override
 
void exprMitlAtom () override
 
void exprMitlDiamond (int, int) override
 
void exprMitlBox (int, int) override
 
void exprSpawn (int params) override
 
void exprExit () override
 
void exprNumOf () override
 
void exprForAllDynamicBegin (const char *, const char *) override
 
void exprForAllDynamicEnd (const char *name) override
 
void exprExistsDynamicBegin (const char *, const char *) override
 
void exprExistsDynamicEnd (const char *) override
 
void exprSumDynamicBegin (const char *, const char *) override
 
void exprSumDynamicEnd (const char *name) override
 
void exprForeachDynamicBegin (const char *, const char *) override
 
void exprForeachDynamicEnd (const char *name) override
 
void pushDynamicFrameOf (template_t *t, const std::string &name)
 
void popDynamicFrameOf (const std::string &name)
 
- Public Member Functions inherited from UTAP::AbstractBuilder
 AbstractBuilder ()
 
void setPosition (uint32_t, uint32_t) override
 Sets the current position. More...
 
void typeStruct (PREFIX, uint32_t fields) override
 Called when a struct-type has been parsed. More...
 
void typeArrayOfSize (size_t) override
 Called to create an array type. More...
 
void typeArrayOfType (size_t) override
 Called to create an array type. More...
 
void structField (const char *name) override
 Called to declare a field of a structure. More...
 
void declTypeDef (const char *name) override
 Used when a typedef declaration was parsed. More...
 
void declVar (const char *name, bool init) override
 Called to when a variable declaration has been parsed. More...
 
void declInitialiserList (uint32_t num) override
 
void declFieldInit (const char *name) override
 
void ganttDeclStart (const char *name) override
 
void ganttDeclSelect (const char *id) override
 
void ganttDeclEnd () override
 
void ganttEntryStart () override
 
void ganttEntrySelect (const char *id) override
 
void ganttEntryEnd () override
 
void declProgress (bool) override
 Guard progress measure declaration. More...
 
void declParameter (const char *name, bool) override
 
void declFuncBegin (const char *name) override
 
void declFuncEnd () override
 
void procBegin (const char *name, const bool isTA=true, const std::string type="", const std::string mode="") override
 
void procEnd () override
 
void procState (const char *name, bool hasInvariant, bool hasER) override
 
void procStateCommit (const char *name) override
 
void procStateUrgent (const char *name) override
 
void procStateInit (const char *name) override
 
void procBranchpoint (const char *name) override
 
void procEdgeBegin (const char *from, const char *to, const bool control, const char *actname) override
 
void procEdgeEnd (const char *from, const char *to) override
 
void procSelect (const char *id) override
 
void procGuard () override
 
void procSync (Constants::synchronisation_t type) override
 
void procUpdate () override
 
void procProb () override
 
void procInstanceLine () override
 
void instanceName (const char *name, bool templ=true) override
 
void instanceNameBegin (const char *name) override
 
void instanceNameEnd (const char *name, size_t arguments) override
 
void procMessage (const char *from, const char *to, const int loc, const bool pch) override
 
void procMessage (Constants::synchronisation_t type) override
 
void procCondition (const std::vector< char *> anchors, const int loc, const bool pch, const bool hot) override
 
void procCondition () override
 
void procLscUpdate (const char *anchor, const int loc, const bool pch) override
 
void procLscUpdate () override
 
void hasPrechart (const bool pch) override
 
void blockBegin () override
 
void blockEnd () override
 
void emptyStatement () override
 
void forBegin () override
 
void forEnd () override
 
void iterationBegin (const char *name) override
 
void iterationEnd (const char *name) override
 
void whileBegin () override
 
void whileEnd () override
 
void doWhileBegin () override
 
void doWhileEnd () override
 
void ifBegin () override
 
void ifCondition () override
 
void ifThen () override
 
void ifEnd (bool) override
 
void breakStatement () override
 
void continueStatement () override
 
void switchBegin () override
 
void switchEnd () override
 
void caseBegin () override
 
void caseEnd () override
 
void defaultBegin () override
 
void defaultEnd () override
 
void exprStatement () override
 
void returnStatement (bool) override
 
void assertStatement () override
 
void exprSync (Constants::synchronisation_t type) override
 
void declIO (const char *, int, int) override
 
void instantiationBegin (const char *, size_t, const char *) override
 
void instantiationEnd (const char *, size_t, const char *, size_t) override
 
void process (const char *) override
 
void processListEnd () override
 
void done () override
 
void handleExpect (const char *text) override
 
void property () override
 
void scenario (const char *) override
 
void parse (const char *) override
 
void beforeUpdate () override
 
void afterUpdate () override
 
void beginChanPriority () override
 
void addChanPriority (char separator) override
 
void defaultChanPriority () override
 
void incProcPriority () override
 
void procPriority (const char *) override
 
void declDynamicTemplate (const std::string &) override
 Dynamic. More...
 
void exprDynamicProcessExpr (const char *) override
 
void exprMITLForAllDynamicBegin (const char *, const char *) override
 
void exprMITLForAllDynamicEnd (const char *name) override
 
void exprMITLExistsDynamicBegin (const char *, const char *) override
 
void exprMITLExistsDynamicEnd (const char *name) override
 
void queryBegin () override
 Verification queries. More...
 
void queryFormula (const char *formula, const char *location) override
 
void queryComment (const char *comment) override
 
void queryEnd () override
 
- Public Member Functions inherited from UTAP::ParserBuilder
virtual ~ParserBuilder ()
 
void handleWarning (const char *msg,...)
 
void handleError (const char *msg,...)
 

Protected Member Functions

void pushFrame (frame_t)
 Push a new frame. More...
 
void popFrame ()
 Pop the topmost frame. More...
 
bool resolve (const std::string &, symbol_t &)
 
expression_t makeConstant (int value)
 
expression_t makeConstant (double value)
 
type_t applyPrefix (PREFIX, type_t type)
 Given a prefix and a type, this method creates a new type by applying the prefix. More...
 
virtual bool allowProcessReferences ()
 If this method returns true, it is allowed to access the private identifiers of a process by prefixing the identifier with the process name. More...
 

Protected Attributes

ExpressionFragments fragments
 Expression stack. More...
 
TypeFragments typeFragments
 Type stack. More...
 
std::stack< frame_tframes
 Frame stack. More...
 
TimedAutomataSystemsystem
 Pointer to the system under construction. More...
 
template_tcurrentTemplate
 The template currently being parsed. More...
 
int32_t scalar_count
 Counter for creating unique scalarset names. More...
 
std::map< std::string, frame_tdynamicFrames
 
- Protected Attributes inherited from UTAP::AbstractBuilder
position_t position
 

Additional Inherited Members

- Public Types inherited from UTAP::ParserBuilder
enum  PREFIX {
  PREFIX_NONE = 0, PREFIX_CONST = 1, PREFIX_URGENT = 2, PREFIX_BROADCAST = 4,
  PREFIX_URGENT_BROADCAST = 6, PREFIX_SYSTEM_META = 8, PREFIX_HYBRID = 16
}
 
- Public Attributes inherited from UTAP::ParserBuilder
std::vector< std::string > lscTemplateNames
 

Detailed Description

Partial implementation of the builder interface: The ExpressionBuilder implements all expression related methods.

In order to support quantifier expressions, this class also handles the type related methods.

This class does not implement any declaration related methods.

Internally, three stacks are maintained: One for expressions, one for types and for frames (scopes).

Definition at line 50 of file expressionbuilder.h.

Constructor & Destructor Documentation

◆ ExpressionBuilder()

ExpressionBuilder::ExpressionBuilder ( TimedAutomataSystem system)

Definition at line 63 of file expressionbuilder.cpp.

References UTAP::declarations_t::frame, UTAP::TimedAutomataSystem::getGlobals(), pushFrame(), and scalar_count.

Here is the call graph for this function:

Member Function Documentation

◆ addPosition()

void ExpressionBuilder::addPosition ( uint32_t  position,
uint32_t  offset,
uint32_t  line,
const std::string &  path 
)
overridevirtual

Add mapping from an absolute position to a relative XML element.

Implements UTAP::ParserBuilder.

Definition at line 70 of file expressionbuilder.cpp.

References UTAP::TimedAutomataSystem::addPosition(), and system.

Here is the call graph for this function:

◆ allowProcessReferences()

virtual bool UTAP::ExpressionBuilder::allowProcessReferences ( )
inlineprotectedvirtual

If this method returns true, it is allowed to access the private identifiers of a process by prefixing the identifier with the process name.

This is only interesting when parsing properties. In this case the method should be overridden by a sub class.

Definition at line 128 of file expressionbuilder.h.

◆ applyPrefix()

type_t ExpressionBuilder::applyPrefix ( PREFIX  prefix,
type_t  type 
)
protected

◆ exprArray()

◆ exprAssignment()

void ExpressionBuilder::exprAssignment ( Constants::kind_t  op)
overridevirtual

◆ exprBinary()

void ExpressionBuilder::exprBinary ( Constants::kind_t  binaryop)
overridevirtual

◆ exprBuiltinFunction1()

void ExpressionBuilder::exprBuiltinFunction1 ( Constants::kind_t  kind)
overridevirtual

Reimplemented from UTAP::AbstractBuilder.

Definition at line 461 of file expressionbuilder.cpp.

References UTAP::expression_t::createUnary(), fragments, and UTAP::AbstractBuilder::position.

Here is the call graph for this function:

◆ exprBuiltinFunction2()

void ExpressionBuilder::exprBuiltinFunction2 ( Constants::kind_t  kind)
overridevirtual

◆ exprBuiltinFunction3()

void ExpressionBuilder::exprBuiltinFunction3 ( Constants::kind_t  kind)
overridevirtual

◆ exprCallBegin()

void ExpressionBuilder::exprCallBegin ( )
overridevirtual

Reimplemented from UTAP::AbstractBuilder.

Reimplemented in UTAP::StatementBuilder.

Definition at line 336 of file expressionbuilder.cpp.

Referenced by UTAP::StatementBuilder::exprCallBegin().

Here is the caller graph for this function:

◆ exprCallEnd()

◆ exprComma()

◆ exprDeadlock()

void ExpressionBuilder::exprDeadlock ( )
overridevirtual

Reimplemented from UTAP::AbstractBuilder.

Definition at line 326 of file expressionbuilder.cpp.

References UTAP::expression_t::createDeadlock(), fragments, UTAP::AbstractBuilder::position, and UTAP::ExpressionBuilder::ExpressionFragments::push().

Here is the call graph for this function:

◆ exprDot()

◆ exprDouble()

void ExpressionBuilder::exprDouble ( double  d)
overridevirtual

◆ exprExistsBegin()

void ExpressionBuilder::exprExistsBegin ( const char *  name)
overridevirtual

Reimplemented from UTAP::AbstractBuilder.

Definition at line 723 of file expressionbuilder.cpp.

References exprForAllBegin().

Here is the call graph for this function:

◆ exprExistsDynamicBegin()

void ExpressionBuilder::exprExistsDynamicBegin ( const char *  name,
const char *  temp 
)
overridevirtual

◆ exprExistsDynamicEnd()

◆ exprExistsEnd()

void ExpressionBuilder::exprExistsEnd ( const char *  name)
overridevirtual

◆ exprExit()

void ExpressionBuilder::exprExit ( )
overridevirtual

Reimplemented from UTAP::AbstractBuilder.

Definition at line 1065 of file expressionbuilder.cpp.

References UTAP::expression_t::createExit(), fragments, UTAP::AbstractBuilder::position, and UTAP::ExpressionBuilder::ExpressionFragments::push().

Here is the call graph for this function:

◆ exprFalse()

void ExpressionBuilder::exprFalse ( )
overridevirtual

Reimplemented from UTAP::AbstractBuilder.

Definition at line 299 of file expressionbuilder.cpp.

References UTAP::Constants::BOOL, UTAP::type_t::createPrimitive(), fragments, makeConstant(), UTAP::ExpressionBuilder::ExpressionFragments::push(), and UTAP::expression_t::setType().

Referenced by exprDot(), and exprId().

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

◆ exprForAllBegin()

void ExpressionBuilder::exprForAllBegin ( const char *  name)
overridevirtual

◆ exprForAllDynamicBegin()

void ExpressionBuilder::exprForAllDynamicBegin ( const char *  name,
const char *  temp 
)
overridevirtual

◆ exprForAllDynamicEnd()

◆ exprForAllEnd()

void ExpressionBuilder::exprForAllEnd ( const char *  name)
overridevirtual

◆ exprForeachDynamicBegin()

void ExpressionBuilder::exprForeachDynamicBegin ( const char *  name,
const char *  temp 
)
overridevirtual

◆ exprForeachDynamicEnd()

◆ exprId()

void ExpressionBuilder::exprId ( const char *  varName)
overridevirtual

◆ exprInlineIf()

◆ exprMitlAtom()

void ExpressionBuilder::exprMitlAtom ( )
overridevirtual

◆ exprMitlBox()

◆ exprMitlConj()

void ExpressionBuilder::exprMitlConj ( )
overridevirtual

◆ exprMitlDiamond()

◆ exprMitlDisj()

void ExpressionBuilder::exprMitlDisj ( )
overridevirtual

◆ exprMitlFormula()

void ExpressionBuilder::exprMitlFormula ( )
overridevirtual

◆ exprMitlNext()

void ExpressionBuilder::exprMitlNext ( )
overridevirtual

◆ exprMitlRelease()

void ExpressionBuilder::exprMitlRelease ( int  low,
int  high 
)
overridevirtual

◆ exprMitlUntil()

void ExpressionBuilder::exprMitlUntil ( int  low,
int  high 
)
overridevirtual

◆ exprNary()

void ExpressionBuilder::exprNary ( Constants::kind_t  op,
uint32_t  num 
)
overridevirtual

◆ exprNat()

void ExpressionBuilder::exprNat ( int32_t  n)
overridevirtual

Reimplemented from UTAP::AbstractBuilder.

Definition at line 331 of file expressionbuilder.cpp.

References fragments, makeConstant(), and UTAP::ExpressionBuilder::ExpressionFragments::push().

Referenced by UTAP::StatementBuilder::typeArrayOfSize(), and typeScalar().

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

◆ exprNumOf()

◆ exprPostDecrement()

void ExpressionBuilder::exprPostDecrement ( )
overridevirtual

Reimplemented from UTAP::AbstractBuilder.

Definition at line 449 of file expressionbuilder.cpp.

References UTAP::expression_t::createUnary(), fragments, UTAP::AbstractBuilder::position, and UTAP::Constants::POSTDECREMENT.

Here is the call graph for this function:

◆ exprPostIncrement()

void ExpressionBuilder::exprPostIncrement ( )
overridevirtual

Reimplemented from UTAP::AbstractBuilder.

Definition at line 437 of file expressionbuilder.cpp.

References UTAP::expression_t::createUnary(), fragments, UTAP::AbstractBuilder::position, and UTAP::Constants::POSTINCREMENT.

Here is the call graph for this function:

◆ exprPreDecrement()

void ExpressionBuilder::exprPreDecrement ( )
overridevirtual

Reimplemented from UTAP::AbstractBuilder.

Definition at line 455 of file expressionbuilder.cpp.

References UTAP::expression_t::createUnary(), fragments, UTAP::AbstractBuilder::position, and UTAP::Constants::PREDECREMENT.

Here is the call graph for this function:

◆ exprPreIncrement()

void ExpressionBuilder::exprPreIncrement ( )
overridevirtual

Reimplemented from UTAP::AbstractBuilder.

Definition at line 443 of file expressionbuilder.cpp.

References UTAP::expression_t::createUnary(), fragments, UTAP::AbstractBuilder::position, and UTAP::Constants::PREINCREMENT.

Here is the call graph for this function:

◆ exprProbaCompare()

void ExpressionBuilder::exprProbaCompare ( Constants::kind_t  pathType1,
Constants::kind_t  pathType2 
)
overridevirtual

◆ exprProbaExpected()

void ExpressionBuilder::exprProbaExpected ( const char *  aggregatingOp)
overridevirtual

◆ exprProbaQualitative()

◆ exprProbaQuantitative()

◆ exprScenario() [1/2]

void ExpressionBuilder::exprScenario ( const char *  name)
overridevirtual

◆ exprScenario() [2/2]

◆ exprSimulate()

void ExpressionBuilder::exprSimulate ( int  nbExpr,
bool  hasReach = false,
int  numberOfAcceptingRuns = 0 
)
overridevirtual

◆ exprSMCControl()

void ExpressionBuilder::exprSMCControl ( )
overridevirtual

◆ exprSpawn()

void ExpressionBuilder::exprSpawn ( int  params)
overridevirtual

◆ exprSumBegin()

void ExpressionBuilder::exprSumBegin ( const char *  name)
overridevirtual

Reimplemented from UTAP::AbstractBuilder.

Definition at line 741 of file expressionbuilder.cpp.

References exprForAllBegin().

Here is the call graph for this function:

◆ exprSumDynamicBegin()

void ExpressionBuilder::exprSumDynamicBegin ( const char *  name,
const char *  temp 
)
overridevirtual

◆ exprSumDynamicEnd()

◆ exprSumEnd()

void ExpressionBuilder::exprSumEnd ( const char *  name)
overridevirtual

◆ exprTernary()

void ExpressionBuilder::exprTernary ( Constants::kind_t  ternaryop,
bool  firstMissing 
)
overridevirtual

◆ exprTrue()

void ExpressionBuilder::exprTrue ( )
overridevirtual

◆ exprUnary()

void ExpressionBuilder::exprUnary ( Constants::kind_t  unaryop)
overridevirtual

◆ getExpressions()

ExpressionBuilder::ExpressionFragments & ExpressionBuilder::getExpressions ( )

Definition at line 102 of file expressionbuilder.cpp.

References fragments.

Referenced by parseExpression().

Here is the caller graph for this function:

◆ handleError()

◆ handleWarning()

void ExpressionBuilder::handleWarning ( const std::string &  )
overridevirtual

Implements UTAP::ParserBuilder.

Definition at line 81 of file expressionbuilder.cpp.

References UTAP::TimedAutomataSystem::addWarning(), UTAP::AbstractBuilder::position, and system.

Referenced by UTAP::SystemBuilder::addSelectSymbolToFrame(), and UTAP::SystemBuilder::procMessage().

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

◆ isType()

bool ExpressionBuilder::isType ( const char *  )
overridevirtual

Must return true if and only if name is registered in the symbol table as a named type, for instance, "int" or "bool" or a user defined type.

Reimplemented from UTAP::AbstractBuilder.

Definition at line 107 of file expressionbuilder.cpp.

References UTAP::type_t::getKind(), UTAP::symbol_t::getType(), resolve(), and UTAP::Constants::TYPEDEF.

Here is the call graph for this function:

◆ makeConstant() [1/2]

expression_t ExpressionBuilder::makeConstant ( int  value)
protected

◆ makeConstant() [2/2]

expression_t ExpressionBuilder::makeConstant ( double  value)
protected

Definition at line 122 of file expressionbuilder.cpp.

References UTAP::expression_t::createDouble(), and UTAP::AbstractBuilder::position.

Here is the call graph for this function:

◆ popDynamicFrameOf()

void ExpressionBuilder::popDynamicFrameOf ( const std::string &  name)

Definition at line 1225 of file expressionbuilder.cpp.

References dynamicFrames.

Referenced by exprExistsDynamicEnd(), exprForAllDynamicEnd(), exprForeachDynamicEnd(), and exprSumDynamicEnd().

Here is the caller graph for this function:

◆ popFrame()

◆ pushDynamicFrameOf()

void ExpressionBuilder::pushDynamicFrameOf ( template_t t,
const std::string &  name 
)

◆ pushFrame()

◆ resolve()

◆ typeBool()

void ExpressionBuilder::typeBool ( PREFIX  )
overridevirtual

Called whenever a boolean type is parsed.

Reimplemented from UTAP::AbstractBuilder.

Definition at line 160 of file expressionbuilder.cpp.

References applyPrefix(), UTAP::Constants::BOOL, UTAP::type_t::createPrimitive(), UTAP::AbstractBuilder::position, UTAP::ExpressionBuilder::TypeFragments::push(), and typeFragments.

Here is the call graph for this function:

◆ typeBoundedInt()

void ExpressionBuilder::typeBoundedInt ( PREFIX  )
overridevirtual

Called whenever an integer type with a range is parsed.

Expressions for the lower and upper have been pushed before.

Reimplemented from UTAP::AbstractBuilder.

Definition at line 185 of file expressionbuilder.cpp.

References applyPrefix(), UTAP::type_t::createPrimitive(), UTAP::type_t::createRange(), fragments, UTAP::Constants::INT, UTAP::ExpressionBuilder::ExpressionFragments::pop(), UTAP::AbstractBuilder::position, UTAP::ExpressionBuilder::TypeFragments::push(), and typeFragments.

Referenced by UTAP::StatementBuilder::typeArrayOfSize().

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

◆ typeChannel()

void ExpressionBuilder::typeChannel ( PREFIX  )
overridevirtual

Called whenever a channel type is parsed.

Reimplemented from UTAP::AbstractBuilder.

Definition at line 193 of file expressionbuilder.cpp.

References applyPrefix(), UTAP::Constants::CHANNEL, UTAP::type_t::createPrimitive(), UTAP::AbstractBuilder::position, UTAP::ExpressionBuilder::TypeFragments::push(), and typeFragments.

Here is the call graph for this function:

◆ typeClock()

void ExpressionBuilder::typeClock ( PREFIX  )
overridevirtual

Called whenever a clock type is parsed.

Reimplemented from UTAP::AbstractBuilder.

Definition at line 199 of file expressionbuilder.cpp.

References applyPrefix(), UTAP::Constants::CLOCK, UTAP::type_t::createPrimitive(), UTAP::AbstractBuilder::position, UTAP::ExpressionBuilder::TypeFragments::push(), and typeFragments.

Here is the call graph for this function:

◆ typeDouble()

void ExpressionBuilder::typeDouble ( PREFIX  )
overridevirtual

Called whenever a double type is parsed.

Reimplemented from UTAP::AbstractBuilder.

Definition at line 179 of file expressionbuilder.cpp.

References applyPrefix(), UTAP::type_t::createPrimitive(), UTAP::Constants::DOUBLE, UTAP::AbstractBuilder::position, UTAP::ExpressionBuilder::TypeFragments::push(), and typeFragments.

Here is the call graph for this function:

◆ typeDuplicate()

void ExpressionBuilder::typeDuplicate ( )
overridevirtual

Duplicate type at the top of the type stack.

Reimplemented from UTAP::AbstractBuilder.

Definition at line 150 of file expressionbuilder.cpp.

References UTAP::ExpressionBuilder::TypeFragments::duplicate(), and typeFragments.

Here is the call graph for this function:

◆ typeInt()

void ExpressionBuilder::typeInt ( PREFIX  )
overridevirtual

◆ typeName()

void ExpressionBuilder::typeName ( PREFIX  ,
const char *  name 
)
overridevirtual

Called when a type name has been parsed.

Prefix indicates whether the type named was prefixed (e.g. with 'const').

Reimplemented from UTAP::AbstractBuilder.

Definition at line 270 of file expressionbuilder.cpp.

References applyPrefix(), UTAP::type_t::createLabel(), UTAP::type_t::createPrimitive(), UTAP::type_t::getKind(), UTAP::symbol_t::getName(), UTAP::symbol_t::getType(), UTAP::AbstractBuilder::position, UTAP::ExpressionBuilder::TypeFragments::push(), resolve(), UTAP::Constants::TYPEDEF, typeFragments, and UTAP::Constants::VOID_TYPE.

Here is the call graph for this function:

◆ typePop()

void ExpressionBuilder::typePop ( )
overridevirtual

Pop type at the topof the type stack.

Reimplemented from UTAP::AbstractBuilder.

Definition at line 155 of file expressionbuilder.cpp.

References UTAP::ExpressionBuilder::TypeFragments::pop(), and typeFragments.

Here is the call graph for this function:

◆ typeScalar()

◆ typeVoid()

void ExpressionBuilder::typeVoid ( )
overridevirtual

Called whenever a void type is parsed.

Reimplemented from UTAP::AbstractBuilder.

Definition at line 205 of file expressionbuilder.cpp.

References UTAP::type_t::createPrimitive(), UTAP::AbstractBuilder::position, UTAP::ExpressionBuilder::TypeFragments::push(), typeFragments, and UTAP::Constants::VOID_TYPE.

Here is the call graph for this function:

Member Data Documentation

◆ currentTemplate

◆ dynamicFrames

std::map<std::string,frame_t> UTAP::ExpressionBuilder::dynamicFrames
protected

Definition at line 129 of file expressionbuilder.h.

Referenced by exprDot(), popDynamicFrameOf(), and pushDynamicFrameOf().

◆ fragments

ExpressionFragments UTAP::ExpressionBuilder::fragments
protected

Expression stack.

Definition at line 85 of file expressionbuilder.h.

Referenced by UTAP::SystemBuilder::addChanPriority(), UTAP::SystemBuilder::afterUpdate(), UTAP::StatementBuilder::assertStatement(), UTAP::SystemBuilder::beforeUpdate(), UTAP::SystemBuilder::beginChanPriority(), UTAP::StatementBuilder::declFieldInit(), UTAP::StatementBuilder::declInitialiserList(), UTAP::SystemBuilder::declIO(), UTAP::SystemBuilder::declProgress(), UTAP::StatementBuilder::declVar(), UTAP::SystemBuilder::defaultChanPriority(), UTAP::StatementBuilder::doWhileEnd(), exprArray(), exprAssignment(), exprBinary(), exprBuiltinFunction1(), exprBuiltinFunction2(), exprBuiltinFunction3(), UTAP::StatementBuilder::exprCallBegin(), exprCallEnd(), exprComma(), exprDeadlock(), exprDot(), exprDouble(), exprExistsDynamicEnd(), exprExistsEnd(), exprExit(), exprFalse(), exprForAllDynamicEnd(), exprForAllEnd(), exprForeachDynamicEnd(), exprId(), exprInlineIf(), exprMitlAtom(), exprMitlBox(), exprMitlConj(), exprMitlDiamond(), exprMitlDisj(), exprMitlFormula(), exprMitlNext(), exprMitlRelease(), exprMitlUntil(), exprNary(), exprNat(), exprNumOf(), exprPostDecrement(), exprPostIncrement(), exprPreDecrement(), exprPreIncrement(), exprProbaCompare(), exprProbaExpected(), exprProbaQualitative(), exprProbaQuantitative(), exprScenario(), exprSimulate(), exprSMCControl(), exprSpawn(), UTAP::StatementBuilder::exprStatement(), exprSumDynamicEnd(), exprSumEnd(), UTAP::SystemBuilder::exprSync(), exprTernary(), exprTrue(), exprUnary(), UTAP::StatementBuilder::forEnd(), UTAP::SystemBuilder::ganttEntryEnd(), getExpressions(), UTAP::StatementBuilder::ifEnd(), UTAP::SystemBuilder::instanceNameEnd(), UTAP::SystemBuilder::instantiationEnd(), UTAP::SystemBuilder::procCondition(), UTAP::SystemBuilder::procGuard(), UTAP::SystemBuilder::procLscUpdate(), UTAP::SystemBuilder::procMessage(), UTAP::SystemBuilder::procProb(), UTAP::SystemBuilder::procState(), UTAP::SystemBuilder::procSync(), UTAP::SystemBuilder::procUpdate(), UTAP::StatementBuilder::returnStatement(), UTAP::StatementBuilder::typeArrayOfSize(), typeBoundedInt(), typeScalar(), and UTAP::StatementBuilder::whileEnd().

◆ frames

◆ scalar_count

int32_t UTAP::ExpressionBuilder::scalar_count
protected

Counter for creating unique scalarset names.

Definition at line 100 of file expressionbuilder.h.

Referenced by ExpressionBuilder(), and typeScalar().

◆ system

◆ typeFragments


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