Envision
A visual programming IDE for object-oriented languages
List of all members | Public Member Functions | Static Public Member Functions | Private Member Functions | Static Private Attributes
OOInteraction::CommandDescriptor Class Reference
Inheritance diagram for OOInteraction::CommandDescriptor:
OOInteraction::OOOperatorDescriptor Interaction::OperatorDescriptor

Public Member Functions

 CommandDescriptor (const QString &name, const QString &signature, int precedence, Associativity associativity)
 
 ~CommandDescriptor ()
 
virtual OOModel::Expressioncreate (const QList< OOModel::Expression * > &operands)
 
- Public Member Functions inherited from OOInteraction::OOOperatorDescriptor
 OOOperatorDescriptor (const QString &name, const QString &signature, int precedence, Associativity associativity)
 
 OOOperatorDescriptor (const QString &name, const QString &signature, int precedence, Associativity associativity, CreateFunction createFunction)
 
- Public Member Functions inherited from Interaction::OperatorDescriptor
 OperatorDescriptor ()
 
 OperatorDescriptor (const QString &name, const QString &signature, int precedence, Associativity associativity)
 
 OperatorDescriptor (const QString &prefixText, const QString &postfixText)
 
virtual ~OperatorDescriptor ()
 
Associativity associativity ()
 
QStringList delimiters ()
 
const QList< ExpectedToken > & expectedTokens () const
 
const QStringList & infix (int at) const
 
const QList< QStringList > & infixes () const
 
bool isDelimiter (int signatureIndex)
 
bool isTransient ()
 
const QString & name ()
 
int numOperands ()
 
const QStringList & postfix () const
 
int precedence ()
 
const QStringList & prefix () const
 
void setTransient (bool transient)
 
const QStringList & signature ()
 

Static Public Member Functions

static bool registerCommand (CommandExpression *command)
 
static void unregisterCommand (CommandExpression *command)
 
- Static Public Member Functions inherited from OOInteraction::OOOperatorDescriptor
template<OOModel::AssignmentExpression::AssignmentTypes op>
static OOModel::Expressionassignment (const QList< OOModel::Expression * > &operands)
 
template<OOModel::BinaryOperation::OperatorTypes op>
static OOModel::Expressionbinary (const QList< OOModel::Expression * > &operands)
 
template<OOModel::UnaryOperation::OperatorTypes op>
static OOModel::Expressionunary (const QList< OOModel::Expression * > &operands)
 
- Static Public Member Functions inherited from Interaction::OperatorDescriptor
static bool isDelimiter (const QString &str)
 

Private Member Functions

OOModel::UnfinishedOperatorcreateUnfinished (const QString &name, const QList< OOModel::Expression * > &arguments)
 

Static Private Attributes

static QMap< QString, CommandExpression * > commands
 

Additional Inherited Members

- Public Types inherited from OOInteraction::OOOperatorDescriptor
using CreateFunction = std::function< OOModel::Expression *(const QList< OOModel::Expression * > &operands)>
 
- Public Types inherited from Interaction::OperatorDescriptor
enum  Associativity { LeftAssociative , RightAssociative , NotAssociative }
 

Constructor & Destructor Documentation

◆ CommandDescriptor()

OOInteraction::CommandDescriptor::CommandDescriptor ( const QString &  name,
const QString &  signature,
int  precedence,
Associativity  associativity 
)

◆ ~CommandDescriptor()

OOInteraction::CommandDescriptor::~CommandDescriptor ( )

Member Function Documentation

◆ create()

OOModel::Expression * OOInteraction::CommandDescriptor::create ( const QList< OOModel::Expression * > &  operands)
virtual

◆ createUnfinished()

OOModel::UnfinishedOperator * OOInteraction::CommandDescriptor::createUnfinished ( const QString &  name,
const QList< OOModel::Expression * > &  arguments 
)
private

◆ registerCommand()

bool OOInteraction::CommandDescriptor::registerCommand ( CommandExpression command)
static

◆ unregisterCommand()

void OOInteraction::CommandDescriptor::unregisterCommand ( CommandExpression command)
static

Member Data Documentation

◆ commands

QMap< QString, CommandExpression * > OOInteraction::CommandDescriptor::commands
staticprivate