Hormiga 1.0

Value Class Reference

#include <operand.h>

Inheritance diagram for Value:
Collaboration diagram for Value:

List of all members.

Public Member Functions

virtual T_MAGNITUDE getValue () const
virtual T_STRING toString () const
virtual bool isShareable ()
virtual T_STRING getSymbol () const
virtual bool isSeteable ()
virtual bool isConstantExpresion () const
 Value ()
 Value (T_MAGNITUDE v, T_STRING &symbol, Type *type=NULL)
 Value (Value &v)
virtual ~Value ()

Protected Attributes

T_MAGNITUDE value
T_STRING symbol

Detailed Description

Definition at line 95 of file operand.h.


Constructor & Destructor Documentation

Value::Value ( )

Constructors

Definition at line 141 of file operand.cpp.

Value::Value ( T_MAGNITUDE  v,
T_STRING &  symbol,
Type type = NULL 
)

Definition at line 146 of file operand.cpp.

Value::Value ( Value v)

Definition at line 152 of file operand.cpp.

Here is the call graph for this function:

virtual Value::~Value ( ) [inline, virtual]

Definition at line 109 of file operand.h.


Member Function Documentation

virtual T_STRING Value::getSymbol ( ) const [inline, virtual]

Return de Symbol that represent this object, it can be the name of a variable.

Implements Operand.

Definition at line 101 of file operand.h.

Here is the caller graph for this function:

T_MAGNITUDE Value::getValue ( ) const [virtual]

Value

Implements Operand.

Reimplemented in VarValueProxy.

Definition at line 125 of file operand.cpp.

Here is the caller graph for this function:

bool Value::isConstantExpresion ( ) const [virtual]

Return TRUE if this expresion is composed only by constants. Return FALSE if this expresion contains some variable or function call.

Implements Operand.

Reimplemented in VarValue.

Definition at line 136 of file operand.cpp.

virtual bool Value::isSeteable ( ) [inline, virtual]

Reimplemented in VarValue.

Definition at line 103 of file operand.h.

virtual bool Value::isShareable ( ) [inline, virtual]

This method tell if this object is sharable (exists in the Symbol Table) If not, this object should be 'deleted' by it's parent. If this object is 'shareable' then the Symbol Table will delete it. By DEFAULT it will return FALSE. Overwrite this if you need to return TRUE ( as in class Boolean and Value )

Reimplemented from Shareable.

Definition at line 100 of file operand.h.

T_STRING Value::toString ( ) const [virtual]

Implements Operand.

Reimplemented in VarValueProxy.

Definition at line 130 of file operand.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:


Member Data Documentation

T_STRING Value::symbol [protected]

Definition at line 112 of file operand.h.

T_MAGNITUDE Value::value [protected]

Definition at line 111 of file operand.h.


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