Envision
A visual programming IDE for object-oriented languages
List of all members | Public Member Functions | Private Attributes
OOModel::FunctionType Class Reference
Inheritance diagram for OOModel::FunctionType:
OOModel::Type

Public Member Functions

 FunctionType (bool isValueType, std::vector< std::unique_ptr< Type >> arguments, std::unique_ptr< Type > result={})
 
 FunctionType (bool isValueType, std::vector< std::unique_ptr< Type >> arguments, std::vector< std::unique_ptr< Type >> results)
 
 FunctionType (const FunctionType &other)
 
const std::vector< std::unique_ptr< Type > > & arguments () const
 
virtual FunctionTypeclone () const override
 
virtual bool equals (const Type *other) const override
 
const Typeresult () const
 
const std::vector< std::unique_ptr< Type > > & results () const
 
- Public Member Functions inherited from OOModel::Type
 Type (bool isValueType)
 
 Type (const Type &other)
 
virtual ~Type ()
 
virtual bool isError () const
 Returns true if this is an error type. More...
 
bool isValueType () const
 Returns true if the this type belongs to an expression representing a value. More...
 
Qualifiers qualifiers () const
 
TypeSystem::TypeRelations relationTo (const Type *other) const
 
void setQualifiers (Qualifiers q, bool enable=true)
 
void setValueType (bool isValueType)
 

Private Attributes

std::vector< std::unique_ptr< Type > > arguments_
 
std::vector< std::unique_ptr< Type > > results_
 

Additional Inherited Members

- Public Types inherited from OOModel::Type
enum  Qualifier { CONST = 0x1 , VOLATILE = 0x2 }
 
using Qualifiers = QFlags< Qualifier >
 

Constructor & Destructor Documentation

◆ FunctionType() [1/3]

OOModel::FunctionType::FunctionType ( bool  isValueType,
std::vector< std::unique_ptr< Type >>  arguments,
std::unique_ptr< Type result = {} 
)

◆ FunctionType() [2/3]

OOModel::FunctionType::FunctionType ( bool  isValueType,
std::vector< std::unique_ptr< Type >>  arguments,
std::vector< std::unique_ptr< Type >>  results 
)

◆ FunctionType() [3/3]

OOModel::FunctionType::FunctionType ( const FunctionType other)

Member Function Documentation

◆ arguments()

const std::vector< std::unique_ptr< Type > > & OOModel::FunctionType::arguments ( ) const
inline

◆ clone()

FunctionType * OOModel::FunctionType::clone ( ) const
overridevirtual

Implements OOModel::Type.

◆ equals()

bool OOModel::FunctionType::equals ( const Type other) const
overridevirtual

Implements OOModel::Type.

◆ result()

const Type * OOModel::FunctionType::result ( ) const
inline

◆ results()

const std::vector< std::unique_ptr< Type > > & OOModel::FunctionType::results ( ) const
inline

Member Data Documentation

◆ arguments_

std::vector<std::unique_ptr<Type> > OOModel::FunctionType::arguments_
private

◆ results_

std::vector<std::unique_ptr<Type> > OOModel::FunctionType::results_
private