|
Unicorn XML Toolkit Version 1.00.00 |
|||||||||
� PREV CLASS �� NEXT CLASS | FRAMES��NO FRAMES | |||||||||
SUMMARY: � CONSTR �|� FUNCTION �|�DATA | DETAIL: � CONSTR �|� FUNCTION �|�DATA |
class CContext { public: CContext(); ~CContext(); public: CScopeChain *GetScopeChain(); CGlobalObject *GetGlobalObject(); XObject GetActivationObject(); XObject GetVariableObject(); XObject GetThis(); public: XObject GetBase(const XValue &pReference); CPropertyName GetPropertyName(const XValue &pReference); XValue GetValue(const XValue &pReference); void PutValue(const XValue &pReference, const XValue &pValue); public: XValue ToPrimitive(const XValue &pValue, int nPreferredType); bool ToBoolean(const XValue &pValue); CNumber ToNumber(const XValue &pValue); CNumber ToInteger(const XValue &pValue); CNumber ToInt32(const XValue &pValue); CNumber ToUint32(const XValue &pValue); CNumber ToUint16(const XValue &pValue); CString ToString(const XValue &pValue); XObject ToObject(const XValue &pValue); public: XValue EvaluateIdentifier(const CPropertyName &identifier); };
The ECMAScript execution context.
CNumber, CPropertyName, CValue, CObject, CScopeChain, CGlobalObject
Constructor/Destructor Summary | |
CContext
();
����������Constructs the context. |
|
~CContext
();
����������Destroys the context. |
Function Summary | |
CScopeChain�*
|
GetScopeChain
();
����������Returns a scope chain associated with this context. |
CGlobalObject�*
|
GetGlobalObject
();
����������Returns a global object associated with this context. |
XObject
|
GetActivationObject
();
����������Returns an activation object associated with this context. |
XObject
|
GetVariableObject
();
����������Returns a variable object associated with this context. |
XObject
|
GetThis
();
����������Returns this
object associated with this context. |
XObject
|
GetBase
(const XValue &pReference);
����������Returns a base object of the given reference. |
CPropertyName
|
GetPropertyName
(const XValue &pReference);
����������Returns a property name of the given reference. |
XValue
|
GetValue
(const XValue &pReference);
����������Returns a value of the property indicated by the given reference. |
void
|
PutValue
(const XValue &pReference, const XValue &pValue);
����������Puts the value of the property indicated by the given reference. |
XValue
|
ToPrimitive
(const XValue &pValue, int nPreferredType);
����������Converts the given value to a primitive type. |
bool
|
ToBoolean
(const XValue &pValue);
����������Converts the given value to a boolean. |
CNumber
|
ToNumber
(const XValue &pValue);
����������Converts the given value to a number. |
CNumber
|
ToInteger
(const XValue &pValue);
����������Converts the given value to an integer. |
CNumber
|
ToInt32
(const XValue &pValue);
����������Converts the given value to a 32-bit integer. |
CNumber
|
ToUint32
(const XValue &pValue);
����������Converts the given value to an unsigned 32-bit integer. |
CNumber
|
ToUint16
(const XValue &pValue);
����������Converts the given value to an unsigned 16-bit integer. |
CString
|
ToString
(const XValue &pValue);
����������Converts the given value to a string. |
XObject
|
ToObject
(const XValue &pValue);
����������Converts the given value to an object. |
XValue
|
EvaluateIdentifier
(const CPropertyName &identifier);
����������Evaluates the ECMAScript identifier (that is, maps the identifier to a reference). |
Constructor/Destructor Detail |
CContext();
Constructs the context.
~CContext();
Destroys the context.
Function Detail |
CScopeChain *GetScopeChain();
Returns a scope chain associated with this context.
CGlobalObject *GetGlobalObject();
Returns a global object associated with this context.
XObject GetActivationObject();
Returns an activation object associated with this context.
XObject GetVariableObject();
Returns a variable object associated with this context.
XObject GetThis();
Returns
this
object associated with this context.
this
object associated with this contextXObject GetBase(const XValue &pReference);
Returns a base object of the given reference.
This function corresponds to the ECMAScript
GetBase
operation.
pReference
- the reference valueCPropertyName GetPropertyName(const XValue &pReference);
Returns a property name of the given reference.
This function corresponds to the ECMAScript
GetPropertyName
operation.
pReference
- the reference valueXValue GetValue(const XValue &pReference);
Returns a value of the property indicated by the given reference.
This function corresponds to the ECMAScript
GetValue
operation.
pReference
- the reference valuevoid PutValue(const XValue &pReference, const XValue &pValue);
Puts the value of the property indicated by the given reference.
This function corresponds to the ECMAScript
PutValue
operation.
pReference
- the reference valuepValue
- the value to putXValue ToPrimitive(const XValue &pValue, int nPreferredType);
Converts the given value to a primitive type.
This function corresponds to the ECMAScript
ToPrimitive
operator.
pValue
- the value to convertnPreferredType
- the preferred type of the resultbool ToBoolean(const XValue &pValue);
Converts the given value to a boolean.
This function corresponds to the ECMAScript
ToBoolean
operator.
pValue
- the value to convertCNumber ToNumber(const XValue &pValue);
Converts the given value to a number.
This function corresponds to the ECMAScript
ToNumber
operator.
pValue
- the value to convertCNumber ToInteger(const XValue &pValue);
Converts the given value to an integer.
This function corresponds to the ECMAScript
ToInteger
operator.
pValue
- the value to convertCNumber ToInt32(const XValue &pValue);
Converts the given value to a 32-bit integer.
This function corresponds to the ECMAScript
ToInt32
operator.
pValue
- the value to convertCNumber ToUint32(const XValue &pValue);
Converts the given value to an unsigned 32-bit integer.
This function corresponds to the ECMAScript
ToUint32
operator.
pValue
- the value to convertCNumber ToUint16(const XValue &pValue);
Converts the given value to an unsigned 16-bit integer.
This function corresponds to the ECMAScript
ToUint16
operator.
pValue
- the value to convertCString ToString(const XValue &pValue);
Converts the given value to a string.
This function corresponds to the ECMAScript
ToString
operator.
pValue
- the value to convertXObject ToObject(const XValue &pValue);
Converts the given value to an object.
This function corresponds to the ECMAScript
ToObject
operator.
pValue
- the value to convertXValue EvaluateIdentifier(const CPropertyName &identifier);
Evaluates the ECMAScript identifier (that is, maps the identifier to a reference).
identifier
- the property name
representing the identifier
|
Unicorn XML Toolkit Version 1.00.00 |
|||||||||
� PREV CLASS �� NEXT CLASS | FRAMES��NO FRAMES | |||||||||
SUMMARY: � CONSTR �|� FUNCTION �|�DATA | DETAIL: � CONSTR �|� FUNCTION �|�DATA |