RexxContext Class Reference

#include <ContextClass.hpp>

Inheritance diagram for RexxContext:
[legend]

Public Member Functions

void * operator new (size_t, void *ptr)
 
void operator delete (void *, void *)
 
void * operator new (size_t)
 
void operator delete (void *)
 
void live (size_t)
 
void liveGeneral (int reason)
 
void flatten (RexxEnvelope *)
 
 RexxContext (RexxActivation *)
 
 RexxContext (RESTORETYPE restoreType)
 
PackageClassgetPackage ()
 
RexxObjectgetDigits ()
 
RexxObjectgetDigitsPropagate ()
 
RexxObjectgetFuzz ()
 
RexxObjectgetForm ()
 
RexxObjectgetVariables ()
 
RexxObjectgetExecutable ()
 
RexxObjectgetArgs ()
 
RexxObjectgetNamedArgs ()
 
RexxObjectsetArgs (RexxObject *, RexxObject **, size_t)
 
RexxObjectgetCondition ()
 
RexxObjectgetLine ()
 
RexxObjectgetRS ()
 
RexxObjectgetParentContextObject ()
 
RexxObjectcopyRexx ()
 
RexxObjectgetName ()
 
RexxObjectgetStackFrames ()
 
RexxObjectnewRexx (RexxObject **args, size_t argc, size_t named_argc)
 
void detach ()
 
- Public Member Functions inherited from RexxObject
void * operator new (size_t, RexxClass *)
 
void * operator new (size_t, RexxClass *, RexxObject **, size_t, size_t)
 
void * operator new (size_t size, void *objectPtr)
 
void operator delete (void *, void *)
 
void operator delete (void *)
 
void operator delete (void *, RexxClass *)
 
void operator delete (void *, RexxClass *, RexxObject **, size_t)
 
RexxObjectnewRexx (RexxObject **arguments, size_t argCount, size_t named_argCount)
 
RexxObjectnewObject ()
 
 operator RexxInternalObject * ()
 
 RexxObject ()
 
 RexxObject (RESTORETYPE restoreType)
 
void initializeNewObject (size_t size, size_t mark, void *vft, RexxBehaviour *b)
 
void initializeNewObject (size_t mark, void *vft, RexxBehaviour *b)
 
virtual ~RexxObject ()
 
virtual RexxObjectdefMethod (RexxString *, RexxMethod *, RexxString *a=OREF_NULL)
 
virtual RexxStringdefaultName ()
 
virtual RexxObjectunknown (RexxString *msg, RexxArray *args, RexxDirectory *named_args)
 
virtual RexxIntegerhasMethod (RexxString *msg)
 
bool hasUninitMethod ()
 
RexxObjectinit ()
 
void uninit ()
 
RexxObjectcopy ()
 
HashCode hash ()
 
bool truthValue (int)
 
virtual bool logicalValue (logical_t &)
 
virtual bool numberValue (wholenumber_t &result, size_t precision)
 
virtual bool numberValue (wholenumber_t &result)
 
virtual bool unsignedNumberValue (stringsize_t &result, size_t precision)
 
virtual bool unsignedNumberValue (stringsize_t &result)
 
virtual bool doubleValue (double &result)
 
RexxNumberStringnumberString ()
 
RexxIntegerintegerValue (size_t)
 
RexxStringmakeString ()
 
RexxTextmakeText ()
 
void copyIntoTail (RexxCompoundTail *buffer)
 
RexxArraymakeArray ()
 
RexxStringstringValue ()
 
RexxTexttextValue ()
 
RexxStringrequestString ()
 
RexxStringrequestStringNoNOSTRING ()
 
RexxTextrequestText ()
 
RexxIntegerrequestInteger (size_t)
 
bool requestNumber (wholenumber_t &, size_t)
 
bool requestUnsignedNumber (stringsize_t &, size_t)
 
RexxArrayrequestArray ()
 
RexxDirectoryrequestDirectory ()
 
RexxStringrequiredString (RexxString *kind, size_t)
 
RexxStringrequiredString (RexxString *kind, const char *)
 
RexxStringrequiredString ()
 
RexxIntegerrequiredInteger (RexxString *kind, size_t, size_t)
 
wholenumber_t requiredNumber (RexxString *kind, size_t position, size_t precision=Numerics::ARGUMENT_DIGITS)
 
stringsize_t requiredPositive (RexxString *kind, size_t position, size_t precision=Numerics::ARGUMENT_DIGITS)
 
stringsize_t requiredNonNegative (RexxString *kind, size_t position, size_t precision=Numerics::ARGUMENT_DIGITS)
 
bool isEqual (RexxObject *)
 
bool isInstanceOf (RexxClass *)
 
RexxObjectisInstanceOfRexx (RexxClass *)
 
RexxObjectisNilRexx ()
 
RexxMethodinstanceMethod (RexxString *)
 
RexxSupplierinstanceMethods (RexxClass *)
 
RexxMethodinstanceMethodRexx (RexxString *)
 
RexxSupplierinstanceMethodsRexx (RexxClass *)
 
RexxObjectdynamicTargetRexx (RexxObject **arguments, size_t argCount, size_t named_argCount)
 
RexxStringobjectName ()
 
RexxObjectobjectNameEquals (RexxObject *)
 
RexxClassclassObject ()
 
RexxObjectsetMethod (RexxString *, RexxMethod *, RexxString *a=OREF_NULL)
 
RexxObjectunsetMethod (RexxString *)
 
RexxObjectrequestRexx (RexxString *)
 
RexxMessagestart (RexxObject **, size_t, size_t)
 
RexxMessagestartWith (RexxObject *, RexxArray *, RexxObject **, size_t)
 
RexxObjectsend (RexxObject **, size_t, size_t)
 
RexxObjectsendWith (RexxObject *, RexxArray *, RexxObject **, size_t)
 
RexxMessagestartCommon (RexxObject *message, RexxObject **arguments, size_t argCount, size_t named_argCount)
 
RexxStringoref ()
 
RexxObjectpmdict ()
 
RexxObjectrun (RexxObject **, size_t, size_t)
 
bool messageSend (RexxString *, RexxObject **, size_t, size_t, ProtectedObject &, bool processUnknown=true, bool dynamicTarget=true)
 
bool messageSend (RexxString *, RexxObject **, size_t, size_t, RexxObject *, ProtectedObject &, bool processUnknown=true, bool dynamicTarget=true)
 
RexxMethodcheckPrivate (RexxMethod *, RexxErrorCodes &)
 
RexxMethodcheckPackage (RexxMethod *, RexxErrorCodes &)
 
void processUnknown (RexxErrorCodes, RexxString *, RexxObject **, size_t, size_t, ProtectedObject &)
 
void processProtectedMethod (RexxString *, RexxMethod *, RexxObject **, size_t, size_t, ProtectedObject &)
 
void sendMessage (RexxString *, RexxArray *, RexxDirectory *, ProtectedObject &)
 
void sendMessage (RexxString *message, RexxObject **args, size_t argCount, size_t named_argCount, ProtectedObject &result)
 
void sendMessage (RexxString *message, ProtectedObject &result)
 
void sendMessage (RexxString *message, RexxObject *argument1, ProtectedObject &result)
 
void sendMessage (RexxString *, RexxObject *, RexxObject *, ProtectedObject &)
 
void sendMessage (RexxString *, RexxObject *, RexxObject *, RexxObject *, ProtectedObject &)
 
void sendMessage (RexxString *, RexxObject *, RexxObject *, RexxObject *, RexxObject *, ProtectedObject &)
 
void sendMessage (RexxString *, RexxObject *, RexxObject *, RexxObject *, RexxObject *, RexxObject *, ProtectedObject &)
 
RexxObjectsendMessage (RexxString *, RexxArray *, RexxDirectory *=OREF_NULL)
 
RexxObjectsendMessage (RexxString *message, RexxObject **args, size_t argCount, size_t named_argCount)
 
RexxObjectsendMessage (RexxString *message)
 
RexxObjectsendMessage (RexxString *message, RexxObject *argument1)
 
RexxObjectsendMessage (RexxString *, RexxObject *, RexxObject *)
 
RexxObjectsendMessage (RexxString *, RexxObject *, RexxObject *, RexxObject *)
 
RexxObjectsendMessage (RexxString *, RexxObject *, RexxObject *, RexxObject *, RexxObject *)
 
RexxObjectsendMessage (RexxString *, RexxObject *, RexxObject *, RexxObject *, RexxObject *, RexxObject *)
 
RexxObjectdefMethods (RexxDirectory *)
 
void setObjectVariable (RexxString *, RexxObject *, RexxObject *)
 
RexxObjectgetObjectVariable (RexxString *)
 
RexxObjectgetObjectVariable (RexxString *, RexxObject *)
 
void addObjectVariables (RexxVariableDictionary *)
 
void copyObjectVariables (RexxObject *newObject)
 
RexxObjectsuperScope (RexxObject *)
 
RexxMethodsuperMethod (RexxString *, RexxObject *)
 
RexxObjectmdict ()
 
RexxObjectsetMdict (RexxObject *)
 
RexxBehaviourbehaviourObject ()
 
const char * idString ()
 
RexxStringid ()
 
RexxMethodmethodLookup (RexxString *name)
 
RexxVariableDictionarygetObjectVariables (RexxObject *)
 
void guardOn (RexxActivity *activity, RexxObject *scope)
 
void guardOff (RexxActivity *activity, RexxObject *scope)
 
RexxObjectequal (RexxObject *)
 
RexxObjectnotEqual (RexxObject *other)
 
RexxObjectstrictEqual (RexxObject *)
 
RexxObjectstrictNotEqual (RexxObject *other)
 
RexxIntegeridentityHashRexx ()
 
RexxObjecthashCode ()
 
RexxStringstringRexx ()
 
RexxStringconcatRexx (RexxObject *)
 
RexxStringconcatBlank (RexxObject *)
 
RexxObjectmakeStringRexx ()
 
RexxObjectmakeArrayRexx ()
 
RexxStringdefaultNameRexx ()
 
RexxObjectcopyRexx ()
 
RexxObjectunknownRexx (RexxString *, RexxArray *, RexxObject **, size_t)
 
RexxObjecthasMethodRexx (RexxString *)
 
void * getCSelf ()
 
void * getCSelf (RexxObject *scope)
 
bool equalValue (RexxObject *other)
 
virtual wholenumber_t compareTo (RexxObject *)
 
 koper (operator_plus) koper(operator_minus) koper(operator_multiply) koper(operator_divide) koper(operator_integerDivide) koper(operator_remainder) koper(operator_power) koper(operator_abuttal) koper(operator_concat) koper(operator_concatBlank) koper(operator_equal) koper(operator_notEqual) koper(operator_isGreaterThan) koper(operator_isBackslashGreaterThan) koper(operator_isLessThan) koper(operator_isBackslashLessThan) koper(operator_isGreaterOrEqual) koper(operator_isLessOrEqual) koper(operator_strictEqual) koper(operator_strictNotEqual) koper(operator_strictGreaterThan) koper(operator_strictBackslashGreaterThan) koper(operator_strictLessThan) koper(operator_strictBackslashLessThan) koper(operator_strictGreaterOrEqual) koper(operator_strictLessOrEqual) koper(operator_lessThanGreaterThan) koper(operator_greaterThanLessThan) koper(operator_and) koper(operator_or) koper(operator_xor) koper(operator_not) RexxVariableDictionary *objectVariables
 
- Public Member Functions inherited from RexxInternalObject
void * operator new (size_t, RexxClass *)
 
void * operator new (size_t, RexxClass *, RexxObject **, size_t, size_t)
 
void * operator new (size_t size, void *ptr)
 
void operator delete (void *)
 
void operator delete (void *p, void *ptr)
 
 RexxInternalObject ()
 
 RexxInternalObject (RESTORETYPE restoreType)
 
virtual ~RexxInternalObject ()
 
 operator RexxObject * ()
 
size_t getObjectSize ()
 
void setObjectSize (size_t s)
 
size_t getObjectDataSize ()
 
void * getObjectDataSpace ()
 
void clearObject ()
 
void clearObject (size_t l)
 
void setVirtualFunctions (void *t)
 
void setInitHeader (size_t s, size_t markword)
 
void setInitHeader (size_t markword)
 
void setObjectLive (size_t markword)
 
void setHasReferences ()
 
void setHasNoReferences ()
 
bool hasReferences ()
 
bool hasNoReferences ()
 
void setPrimitive ()
 
void setNonPrimitive ()
 
bool isPrimitive ()
 
bool isNonPrimitive ()
 
void setInRexxPackage ()
 
bool isInRexxPackage ()
 
bool isObjectMarked (size_t markword)
 
void setObjectMark (size_t markword)
 
void clearObjectMark ()
 
bool isObjectLive (size_t mark)
 
bool isObjectDead (size_t mark)
 
bool isOldSpace ()
 
bool isNewSpace ()
 
void setNewSpace ()
 
void setOldSpace ()
 
void makeProxiedObject ()
 
bool isProxyObject ()
 
bool isSubClassOrEnhanced ()
 
bool isBaseClass ()
 
size_t getObjectTypeNumber ()
 
RexxBehaviourgetObjectType ()
 
bool isObjectType (RexxBehaviour *b)
 
bool isObjectType (size_t t)
 
bool isSameType (RexxInternalObject *o)
 
void setBehaviour (RexxBehaviour *b)
 
virtual RexxObjectmakeProxy (RexxEnvelope *)
 
virtual RexxObjectevaluate (RexxActivation *, RexxExpressionStack *)
 
virtual RexxObjectgetValue (RexxActivation *)
 
virtual RexxObjectgetValue (RexxVariableDictionary *)
 
virtual RexxObjectgetRealValue (RexxActivation *)
 
virtual RexxObjectgetRealValue (RexxVariableDictionary *)
 
virtual HashCode getHashValue ()
 
HashCode identityHash ()
 
virtual RexxStringprimitiveMakeString ()
 
virtual RexxTextprimitiveMakeText ()
 
virtual RexxObjectdynamicTarget (RexxObject **arguments, size_t count, size_t named_count)
 
void hasUninit ()
 
void removedUninit ()
 
void printObject ()
 
RexxObjectclone ()
 
- Public Member Functions inherited from RexxVirtualBase
virtual RexxObjectunflatten (RexxEnvelope *)
 

Static Public Member Functions

static void createInstance ()
 
- Static Public Member Functions inherited from RexxObject
static void decodeMessageName (RexxObject *target, RexxObject *message, RexxString *&messageName, RexxObject *&startScope)
 
static void createInstance ()
 
- Static Public Member Functions inherited from RexxInternalObject
static size_t getObjectHeaderSize ()
 

Static Public Attributes

static RexxClassclassInstance = OREF_NULL
 
- Static Public Attributes inherited from RexxObject
static PCPPM operatorMethods []
 
static RexxClassclassInstance = OREF_NULL
 

Protected Member Functions

void checkValid ()
 
- Protected Member Functions inherited from RexxVirtualBase
virtual ~RexxVirtualBase ()
 
virtual void baseVirtual ()
 

Protected Attributes

RexxActivationactivation
 

Additional Inherited Members

- Public Attributes inherited from RexxInternalObject
ObjectHeader header
 
RexxBehaviourbehaviour
 

Detailed Description

Definition at line 53 of file ContextClass.hpp.

Constructor & Destructor Documentation

◆ RexxContext() [1/2]

RexxContext::RexxContext ( RexxActivation a)

Constructor for a RexxContext object.

Parameters
aThe activation we're attached to.

Definition at line 80 of file ContextClass.cpp.

References activation.

◆ RexxContext() [2/2]

RexxContext::RexxContext ( RESTORETYPE  restoreType)
inline

Definition at line 66 of file ContextClass.hpp.

Member Function Documentation

◆ checkValid()

◆ copyRexx()

RexxObject * RexxContext::copyRexx ( )

An override for the copy method to keep RexxContext objects from being copied.

Returns
Never returns.

Definition at line 144 of file ContextClass.cpp.

References Error_Unsupported_copy_method, reportException(), and TheNilObject.

Referenced by RexxMemory::createImage().

◆ createInstance()

void RexxContext::createInstance ( )
static

Create initial bootstrap objects

Definition at line 55 of file ContextClass.cpp.

References CLASS_CREATE.

Referenced by RexxMemory::createImage().

◆ detach()

void RexxContext::detach ( )
inline

Definition at line 95 of file ContextClass.hpp.

References activation, and OREF_NULL.

Referenced by RexxActivation::termination().

◆ flatten()

void RexxContext::flatten ( RexxEnvelope envelope)
virtual

Reimplemented from RexxObject.

Definition at line 122 of file ContextClass.cpp.

References cleanUpFlatten, OREF_NULL, and setUpFlatten.

◆ getArgs()

RexxObject * RexxContext::getArgs ( )

Return the positional arguments used to invoke the current context

Returns
The array of positional arguments

Definition at line 255 of file ContextClass.cpp.

References activation, checkValid(), RexxActivation::getMethodArgumentCount(), and RexxActivation::getMethodArgumentList().

Referenced by RexxMemory::createImage().

◆ getCondition()

RexxObject * RexxContext::getCondition ( )

Return the current executable condition information

Returns
The condition information

Definition at line 323 of file ContextClass.cpp.

References activation, checkValid(), RexxObject::copy(), RexxActivation::getConditionObj(), OREF_NULL, and TheNilObject.

Referenced by RexxMemory::createImage().

◆ getDigits()

RexxObject * RexxContext::getDigits ( )

Return the current digits setting for the running context

Returns
The current digits value

Definition at line 182 of file ContextClass.cpp.

References activation, checkValid(), RexxActivation::digits(), and new_integer().

Referenced by RexxMemory::createImage().

◆ getDigitsPropagate()

RexxObject * RexxContext::getDigitsPropagate ( )

Return the current digits propagate setting for the running context

Returns
The current digits propagate value

Definition at line 194 of file ContextClass.cpp.

References activation, checkValid(), RexxActivation::propagateNumericSettings(), TheFalseObject, and TheTrueObject.

Referenced by RexxMemory::createImage().

◆ getExecutable()

RexxObject * RexxContext::getExecutable ( )

Return the executable backing the current context

Returns
The executable object (either a method or routine)

Definition at line 243 of file ContextClass.cpp.

References activation, checkValid(), and RexxActivationBase::getExecutable().

Referenced by RexxMemory::createImage().

◆ getForm()

RexxObject * RexxContext::getForm ( )

Return the current form setting for the running context

Returns
The current form value

Definition at line 218 of file ContextClass.cpp.

References activation, checkValid(), RexxActivation::form(), and Numerics::FORM_SCIENTIFIC.

Referenced by RexxMemory::createImage().

◆ getFuzz()

RexxObject * RexxContext::getFuzz ( )

Return the current fuzz setting for the running context

Returns
The current fuzz value

Definition at line 206 of file ContextClass.cpp.

References activation, checkValid(), RexxActivation::fuzz(), and new_integer().

Referenced by RexxMemory::createImage().

◆ getLine()

RexxObject * RexxContext::getLine ( )

Return the execution context current line position.

Returns
The current line number of the context.

Definition at line 337 of file ContextClass.cpp.

References activation, checkValid(), and RexxActivation::getContextLine().

Referenced by RexxMemory::createImage().

◆ getName()

RexxObject * RexxContext::getName ( )

Retrieve the name associated with the current context. If this is the top level, then the name of the package is returned. For internal call contexts, the label name is returned, and for routines or methods, the name used to invoke the code is returned.

Returns
The appropriate name for this context.

Definition at line 375 of file ContextClass.cpp.

References activation, checkValid(), and RexxActivation::getCallname().

Referenced by RexxMemory::createImage().

◆ getNamedArgs()

RexxObject * RexxContext::getNamedArgs ( )

Return the named arguments used to invoke the current context

Returns
The directory of named arguments

Definition at line 269 of file ContextClass.cpp.

References activation, checkValid(), RexxDirectory::fromIndexItemArray(), RexxActivation::getMethodArgumentCount(), RexxActivation::getMethodArgumentList(), RexxActivation::getMethodNamedArgumentCount(), new_directory(), and OREF_NULL.

Referenced by RexxMemory::createImage().

◆ getPackage()

PackageClass * RexxContext::getPackage ( )

Return the package object for the code that's currently executing.

Returns
The package instance.

Definition at line 170 of file ContextClass.cpp.

References activation, checkValid(), and RexxActivation::getPackage().

Referenced by RexxMemory::createImage().

◆ getParentContextObject()

RexxObject * RexxContext::getParentContextObject ( )
Returns
The parent's context.

Definition at line 359 of file ContextClass.cpp.

References activation, checkValid(), and RexxActivation::getParentContextObject().

Referenced by RexxMemory::createImage().

◆ getRS()

RexxObject * RexxContext::getRS ( )

Return the execution context return status

Returns
The .RS value of the context.

Definition at line 349 of file ContextClass.cpp.

References activation, checkValid(), and RexxActivation::getContextReturnStatus().

Referenced by RexxMemory::createImage().

◆ getStackFrames()

RexxObject * RexxContext::getStackFrames ( )

Retrieve the stack frames from the current context.

Returns
A list of the current stack frames.

Definition at line 386 of file ContextClass.cpp.

References activation, checkValid(), and RexxActivation::getStackFrames().

Referenced by RexxMemory::createImage().

◆ getVariables()

RexxObject * RexxContext::getVariables ( )

Return a supplier for all of the variables in the current context.

Returns
A supplier object for iterating over the variables

Definition at line 231 of file ContextClass.cpp.

References activation, checkValid(), and RexxActivation::getAllLocalVariables().

Referenced by RexxMemory::createImage(), and RexxBlock::RexxBlock().

◆ live()

void RexxContext::live ( size_t  liveMark)
virtual

Reimplemented from RexxObject.

Definition at line 104 of file ContextClass.cpp.

References activation, and memory_mark.

◆ liveGeneral()

void RexxContext::liveGeneral ( int  reason)
virtual

Reimplemented from RexxObject.

Definition at line 113 of file ContextClass.cpp.

References activation, and memory_mark_general.

◆ newRexx()

RexxObject * RexxContext::newRexx ( RexxObject **  args,
size_t  argc,
size_t  named_argc 
)

The Rexx accessible class NEW method. This raises an error because RexxContext objects can only be created by the internal interpreter.

Parameters
argsThe NEW args
argcThe count of arguments
Returns
Never returns.

Definition at line 96 of file ContextClass.cpp.

References Error_Unsupported_new_method, reportException(), and TheNilObject.

Referenced by RexxMemory::createImage().

◆ operator delete() [1/2]

void RexxContext::operator delete ( void *  )
inline

Definition at line 59 of file ContextClass.hpp.

◆ operator delete() [2/2]

void RexxContext::operator delete ( void *  ,
void *   
)
inline

Definition at line 57 of file ContextClass.hpp.

◆ operator new() [1/2]

void * RexxContext::operator new ( size_t  size)

Allocate a new RexxContext object

Parameters
sizeThe size of the object.
Returns
The newly allocated object.

Definition at line 68 of file ContextClass.cpp.

References new_object(), and T_RexxContext.

◆ operator new() [2/2]

void* RexxContext::operator new ( size_t  ,
void *  ptr 
)
inline

Definition at line 56 of file ContextClass.hpp.

◆ setArgs()

RexxObject * RexxContext::setArgs ( RexxObject positionalArguments,
RexxObject **  named_arglist,
size_t  named_argcount 
)

Member Data Documentation

◆ activation

◆ classInstance

RexxClass * RexxContext::classInstance = OREF_NULL
static

Definition at line 98 of file ContextClass.hpp.


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