Om
1.0.0
A universal framework for multimedia simulation
|
A class that represents a template parameter list instantiation. More...
#include <omScriptingMirTemplates.h>
Public Types | |
enum | ArgumentKind { TYPE, VALUE, UNDEFINED } |
An enum describing the different kinds of parameters a template instantiation can have. More... | |
Public Member Functions | |
TemplateInstantiation () | |
Create a new template instantation object with no arguments present. More... | |
~TemplateInstantiation () | |
Size | getArgumentCount () const |
Return the number of template arguments this template instantiation specifies. More... | |
Bool | addTypeArgument (const Shared< lang::Type > &newType) |
Add a new type argument to the end of this template instantiation's argument list. More... | |
Bool | addValueArgument (const Shared< Expression > &newValue) |
Add a new value parameter to the end of this template declaration's parameter list. More... | |
ArgumentKind | getArgumentKind (Index argumentIndex) const |
Return the kind of argument at the specified index in this template declaration's parameter list. More... | |
Shared< lang::Type > | getArgumentType (Index parameterIndex) const |
Return the template type of the argument at the specified index in this declaration's argument list. More... | |
Shared< Expression > | getArgumentValue (Index parameterIndex) const |
Return the expression of the argument at the specified index in this instantiaion's argument list. More... | |
Public Member Functions inherited from om::scripting::mir::lang::ASTNode | |
ASTNode () | |
Create a new AST node with no node position specified. More... | |
ASTNode (const Position &newPosition) | |
Create a new AST node which corresponds to a token starting at the specified source code position. More... | |
virtual | ~ASTNode () |
Destroy this AST node object. More... | |
const Position & | getPosition () const |
Return an object representing the position of this AST node in the source code. More... | |
void | setPosition (const Position &newPosition) |
Set the position of this AST node in the source code. More... | |
Static Public Member Functions | |
static Shared< TemplateInstantiation > | construct () |
Construct a smart-pointer-wrapped instance of this class using the constructor with the given arguments. More... | |
A class that represents a template parameter list instantiation.
A template instantiation consists of a list of type or constant expression arguments that specify the instantiation for a previously declared template type or method.
|
inline |
Create a new template instantation object with no arguments present.
om::scripting::mir::lang::TemplateInstantiation::~TemplateInstantiation | ( | ) |
|
inline |
Return the number of template arguments this template instantiation specifies.
Bool om::scripting::mir::lang::TemplateInstantiation::addTypeArgument | ( | const Shared< lang::Type > & | newType | ) |
Add a new type argument to the end of this template instantiation's argument list.
Bool om::scripting::mir::lang::TemplateInstantiation::addValueArgument | ( | const Shared< Expression > & | newValue | ) |
Add a new value parameter to the end of this template declaration's parameter list.
|
inline |
Return the kind of argument at the specified index in this template declaration's parameter list.
If the specified index is out-of-bounds, the UNDEFINED parameter kind is returned.
Shared<lang::Type> om::scripting::mir::lang::TemplateInstantiation::getArgumentType | ( | Index | parameterIndex | ) | const |
Return the template type of the argument at the specified index in this declaration's argument list.
If the specified index is out-of-bounds or is a VALUE argument kind, a NULL Type pointer is returned.
Shared<Expression> om::scripting::mir::lang::TemplateInstantiation::getArgumentValue | ( | Index | parameterIndex | ) | const |
Return the expression of the argument at the specified index in this instantiaion's argument list.
If the specified index is out-of-bounds or is a TYPE argument kind, a NULL Expression value pointer is returned.
|
inlinestatic |
Construct a smart-pointer-wrapped instance of this class using the constructor with the given arguments.