RexxObject Class Reference

#include <ObjectClass.hpp>

Inheritance diagram for RexxObject:
[legend]

Public Member Functions

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 ()
 
void live (size_t)
 
void liveGeneral (int reason)
 
void flatten (RexxEnvelope *)
 
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 ()
 
RexxStringprimitiveMakeString ()
 
void copyIntoTail (RexxCompoundTail *buffer)
 
RexxArraymakeArray ()
 
RexxStringstringValue ()
 
RexxStringrequestString ()
 
RexxStringrequestStringNoNOSTRING ()
 
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 *)
 
RexxMethodinstanceMethod (RexxString *)
 
RexxSupplierinstanceMethods (RexxClass *)
 
RexxMethodinstanceMethodRexx (RexxString *)
 
RexxSupplierinstanceMethodsRexx (RexxClass *)
 
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 messageSend (RexxString *, RexxObject **, size_t, size_t, RexxObject *, ProtectedObject &, bool processUnknown=true)
 
RexxMethodcheckPrivate (RexxMethod *)
 
void processUnknown (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 ()
 
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 ()
 
void hasUninit ()
 
void removedUninit ()
 
void printObject ()
 
RexxObjectclone ()
 
- Public Member Functions inherited from RexxVirtualBase
virtual RexxObjectunflatten (RexxEnvelope *)
 

Static Public Member Functions

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 PCPPM operatorMethods []
 
static RexxClassclassInstance = OREF_NULL
 

Additional Inherited Members

- Public Attributes inherited from RexxInternalObject
ObjectHeader header
 
RexxBehaviourbehaviour
 
- Protected Member Functions inherited from RexxVirtualBase
virtual ~RexxVirtualBase ()
 
virtual void baseVirtual ()
 

Detailed Description

Definition at line 323 of file ObjectClass.hpp.

Constructor & Destructor Documentation

◆ RexxObject() [1/2]

RexxObject::RexxObject ( )
inline

Definition at line 339 of file ObjectClass.hpp.

Referenced by newObject(), and newRexx().

◆ RexxObject() [2/2]

RexxObject::RexxObject ( RESTORETYPE  restoreType)
inline

Definition at line 344 of file ObjectClass.hpp.

◆ ~RexxObject()

virtual RexxObject::~RexxObject ( )
inlinevirtual

Definition at line 380 of file ObjectClass.hpp.

Member Function Documentation

◆ addObjectVariables()

void RexxObject::addObjectVariables ( RexxVariableDictionary dictionary)

Definition at line 2368 of file ObjectClass.cpp.

References OrefSet, and RexxVariableDictionary::setNextDictionary().

Referenced by copyObjectVariables().

◆ behaviourObject()

RexxBehaviour* RexxObject::behaviourObject ( )
inline

Definition at line 491 of file ObjectClass.hpp.

References RexxInternalObject::behaviour.

Referenced by id().

◆ checkPrivate()

◆ classObject()

◆ compareTo()

wholenumber_t RexxObject::compareTo ( RexxObject other)
virtual

Wrapper around the compareTo() method that validates and extracts integer value.

Parameters
otherThe other comparison object
Returns
-1, 0, 1 depending on the comparison result.

Reimplemented in RexxInteger, RexxNumberString, and RexxString.

Definition at line 190 of file ObjectClass.cpp.

References Error_Invalid_whole_number_compareto, Error_No_result_object_message, numberValue(), OREF_NULL, reportException(), and sendMessage().

Referenced by BaseSortComparator::compare(), and RexxString::compareTo().

◆ concatBlank()

RexxString * RexxObject::concatBlank ( RexxObject otherObj)

Blank concatentation operation supported by the Object class. This converts the object into a string form, then asks the converted object to perform the concatenaton.

Parameters
otherObjThe object to concatenate.
Returns
The concatenation result.

Definition at line 2693 of file ObjectClass.cpp.

References RexxString::concatBlank(), and REQUEST_STRING().

Referenced by RexxMemory::createImage().

◆ concatRexx()

RexxString * RexxObject::concatRexx ( RexxObject otherObj)

Concatentation operation supported by the Object class. This converts the object into a string form, then asks the converted object to perform the concatenaton.

Parameters
otherObjThe object to concatenate.
Returns
The concatenation result.

Definition at line 2676 of file ObjectClass.cpp.

References RexxString::concatRexx(), and REQUEST_STRING().

Referenced by RexxMemory::createImage().

◆ copy()

◆ copyIntoTail()

void RexxObject::copyIntoTail ( RexxCompoundTail buffer)
virtual

Reimplemented from RexxInternalObject.

Reimplemented in RexxInteger.

Definition at line 1131 of file ObjectClass.cpp.

References RexxString::copyIntoTail(), and REQUEST_STRING().

Referenced by RexxCompoundTail::buildTail(), and RexxCompoundTail::buildUnresolvedTail().

◆ copyObjectVariables()

void RexxObject::copyObjectVariables ( RexxObject newObject)

◆ copyRexx()

RexxObject * RexxObject::copyRexx ( )

Definition at line 2733 of file ObjectClass.cpp.

References copy().

Referenced by RexxMemory::createImage().

◆ createInstance()

void RexxObject::createInstance ( )
static

Create initial class object at bootstrap time.

Definition at line 72 of file ObjectClass.cpp.

References CLASS_CREATE.

Referenced by RexxMemory::createImage().

◆ decodeMessageName()

void RexxObject::decodeMessageName ( RexxObject target,
RexxObject message,
RexxString *&  messageName,
RexxObject *&  startScope 
)
static

A static method that can be used to decode the various message argument varieties used with start(), startWith(), and the Message class new.

Parameters
messageThe input message. This can be a message name or an array containing a message name/startscope pairing.
messageName
startScope

Definition at line 1965 of file ObjectClass.cpp.

References ARG_ONE, ARG_TWO, arrayArgument(), ActivityManager::currentActivity, Error_Execution_super, Error_Incorrect_method_message, RexxArray::get(), RexxArray::getDimension(), RexxActivationBase::getReceiver(), RexxActivity::getTopStackFrame(), isOfClass, OREF_NULL, reportException(), requiredArgument(), RexxArray::size(), stringArgument(), and RexxString::upper().

Referenced by RexxMessage::newRexx(), send(), sendWith(), and startCommon().

◆ defaultName()

◆ defaultNameRexx()

RexxString * RexxObject::defaultNameRexx ( )

Definition at line 2725 of file ObjectClass.cpp.

References defaultName().

Referenced by RexxMemory::createImage().

◆ defMethod()

◆ defMethods()

◆ doubleValue()

bool RexxObject::doubleValue ( double &  result)
virtual

◆ equal()

RexxObject * RexxObject::equal ( RexxObject other)

Definition at line 405 of file ObjectClass.cpp.

References ARG_ONE, requiredArgument(), TheFalseObject, and TheTrueObject.

Referenced by RexxMemory::createImage().

◆ equalValue()

◆ flatten()

void RexxObject::flatten ( RexxEnvelope envelope)
virtual

◆ getCSelf() [1/2]

void * RexxObject::getCSelf ( )

Attempt to get a CSELF value from an object instance for a native context.

Returns
An unwrapperd CSELF value, if one can be found.

Definition at line 2802 of file ObjectClass.cpp.

References getObjectVariable(), isInstanceOf(), OREF_NULL, TheBufferClass, and ThePointerClass.

Referenced by RexxNativeActivation::cself().

◆ getCSelf() [2/2]

void * RexxObject::getCSelf ( RexxObject scope)

Attempt to get a CSELF value from an object instance, starting from a given scope value and checking each of the super scopes for the class

Parameters
scopeThe starting scope for the search.
Returns
An unwrappered CSELF value, if one can be found.

Definition at line 2834 of file ObjectClass.cpp.

References getObjectVariable(), isInstanceOf(), OREF_NULL, superScope(), TheBufferClass, TheNilObject, and ThePointerClass.

◆ getObjectVariable() [1/2]

RexxObject * RexxObject::getObjectVariable ( RexxString name)

Search through all of the scopes looking for a variable of the given name. This will return the first match.

Parameters
nameThe target name.
Returns
The value associated with the variable or OREF_NULL if no matching variable is found.

Definition at line 2312 of file ObjectClass.cpp.

References RexxVariableDictionary::getNextDictionary(), OREF_NULL, and RexxVariableDictionary::realValue().

Referenced by getCSelf(), and objectName().

◆ getObjectVariable() [2/2]

RexxObject * RexxObject::getObjectVariable ( RexxString name,
RexxObject scope 
)

◆ getObjectVariables()

◆ guardOff()

void RexxObject::guardOff ( RexxActivity activity,
RexxObject scope 
)

Release a guard lock on the target object at the given scope.

Parameters
activityThe activity we're running on.
scopeThe scope that needs to be released.

Definition at line 2445 of file ObjectClass.cpp.

References getObjectVariables(), and RexxVariableDictionary::release().

Referenced by GuardLock::~GuardLock().

◆ guardOn()

void RexxObject::guardOn ( RexxActivity activity,
RexxObject scope 
)

Obtain a guard lock on the target object at the given scope.

Parameters
activityThe activity we're running on.
scopeThe scope that needs to be locked.

Definition at line 2432 of file ObjectClass.cpp.

References getObjectVariables(), and RexxVariableDictionary::reserve().

Referenced by GuardLock::GuardLock().

◆ hash()

HashCode RexxObject::hash ( )
virtual

Hash an exported object. Of we're a non-primitive one, this will require us to send the HASHCODE message to request a hash value.

Returns
A "hashed hash" that can be used by the map collections.

Reimplemented from RexxInternalObject.

Reimplemented in RexxClass.

Definition at line 376 of file ObjectClass.cpp.

References RexxInternalObject::getHashValue(), RexxInternalObject::isBaseClass(), and sendMessage().

Referenced by RexxInteger::hashCode(), RexxNumberString::hashCode(), RexxHashTable::hashIndex(), and RexxHashTable::hashStringIndex().

◆ hashCode()

RexxObject * RexxObject::hashCode ( )

Default implementation of the HASHCODE method.

Returns
The object's hash code value.

Definition at line 360 of file ObjectClass.cpp.

References RexxInternalObject::getHashValue(), and new_string().

Referenced by RexxMemory::createImage().

◆ hasMethod()

◆ hasMethodRexx()

RexxObject * RexxObject::hasMethodRexx ( RexxString message)

Definition at line 2760 of file ObjectClass.cpp.

References ARG_ONE, hasMethod(), stringArgument(), and RexxString::upper().

Referenced by RexxMemory::createImage().

◆ hasUninitMethod()

bool RexxObject::hasUninitMethod ( )

Definition at line 2520 of file ObjectClass.cpp.

References hasMethod(), and TheTrueObject.

Referenced by RexxClass::subclass().

◆ id()

RexxString * RexxObject::id ( void  )

◆ identityHashRexx()

RexxInteger * RexxObject::identityHashRexx ( )

Return a unique identity hash value for this object. This hash will be unique among the set of currently active Rexx objects.

Returns
The identity hash value as an integer object.

Definition at line 2502 of file ObjectClass.cpp.

References RexxInternalObject::identityHash(), and new_integer().

Referenced by RexxMemory::createImage().

◆ idString()

const char * RexxObject::idString ( void  )

Definition at line 2453 of file ObjectClass.cpp.

References RexxString::getStringData(), id(), and OREF_NULL.

◆ init()

RexxObject * RexxObject::init ( void  )

Definition at line 2486 of file ObjectClass.cpp.

References OREF_NULL.

Referenced by RexxMemory::createImage().

◆ initializeNewObject() [1/2]

void RexxObject::initializeNewObject ( size_t  mark,
void *  vft,
RexxBehaviour b 
)
inline

◆ initializeNewObject() [2/2]

◆ instanceMethod()

RexxMethod * RexxObject::instanceMethod ( RexxString method_name)
virtual

Retrieve the method instance for an object's defined method.

Parameters
method_nameThe method name.
Returns
The method object that implements the object method.

Reimplemented from RexxInternalObject.

Reimplemented in RexxInteger, and RexxNumberString.

Definition at line 273 of file ObjectClass.cpp.

References ARG_ONE, RexxInternalObject::behaviour, RexxBehaviour::getMethodDictionary(), OREF_NULL, stringArgument(), RexxTable::stringGet(), TheNilObject, and RexxString::upper().

Referenced by RexxInteger::instanceMethod(), RexxNumberString::instanceMethod(), instanceMethodRexx(), requestRexx(), and SecurityManager::SecurityManager().

◆ instanceMethodRexx()

RexxMethod * RexxObject::instanceMethodRexx ( RexxString method_name)

Retrieve the method instance for an object's defined method.

Parameters
method_nameThe method name.
Returns
The method object that implements the object method.

Definition at line 332 of file ObjectClass.cpp.

References instanceMethod().

Referenced by RexxMemory::createImage().

◆ instanceMethods()

RexxSupplier * RexxObject::instanceMethods ( RexxClass class_object)
virtual

Return a supplier containing the methods implemented by an object. Depending on the argument, this is either A) all of the methods, B) just the explicitly set instance methods, or C) the methods provided by a given class.

Parameters
class_objectThe target class object (optional).
Returns
A supplier with the appropriate method set.

Reimplemented from RexxInternalObject.

Reimplemented in RexxInteger, and RexxNumberString.

Definition at line 317 of file ObjectClass.cpp.

References RexxInternalObject::behaviour, and RexxBehaviour::getMethods().

Referenced by RexxInteger::instanceMethods(), RexxNumberString::instanceMethods(), and instanceMethodsRexx().

◆ instanceMethodsRexx()

RexxSupplier * RexxObject::instanceMethodsRexx ( RexxClass class_object)

Return a supplier containing the methods implemented by an object. Depending on the argument, this is either A) all of the methods, B) just the explicitly set instance methods, or C) the methods provided by a given class.

Parameters
class_objectThe target class object (optional).
Returns
A supplier with the appropriate method set.

Definition at line 349 of file ObjectClass.cpp.

References instanceMethods().

Referenced by RexxMemory::createImage().

◆ integerValue()

RexxInteger * RexxObject::integerValue ( size_t  precision)
virtual

◆ isEqual()

bool RexxObject::isEqual ( RexxObject other)
virtual

◆ isInstanceOf()

bool RexxObject::isInstanceOf ( RexxClass other)
virtual

◆ isInstanceOfRexx()

RexxObject * RexxObject::isInstanceOfRexx ( RexxClass other)

The Rexx external version of the instance of.

Parameters
otherThe other test class.
Returns
.true if this class is an instance of the target class. .false otherwise.

Definition at line 244 of file ObjectClass.cpp.

References ARG_ONE, isInstanceOf(), requiredArgument(), TheFalseObject, and TheTrueObject.

Referenced by RexxMemory::createImage().

◆ koper()

RexxObject::koper ( operator_plus  )

◆ live()

void RexxObject::live ( size_t  liveMark)
virtual

◆ liveGeneral()

◆ logicalValue()

bool RexxObject::logicalValue ( logical_t result)
virtual

Convert an object to a logical value without raising an error.

Parameters
resultThe converted value.
Returns
true if this converted ok, false for an invalid logical.

Reimplemented from RexxInternalObject.

Reimplemented in RexxInteger, RexxNumberString, and RexxString.

Definition at line 456 of file ObjectClass.cpp.

References RexxString::logicalValue(), and REQUEST_STRING().

Referenced by RexxNativeActivation::objectToValue().

◆ makeArray()

RexxArray * RexxObject::makeArray ( void  )
virtual

◆ makeArrayRexx()

RexxObject * RexxObject::makeArrayRexx ( )

◆ makeString()

◆ makeStringRexx()

RexxObject * RexxObject::makeStringRexx ( )

Definition at line 2709 of file ObjectClass.cpp.

References makeString().

Referenced by RexxMemory::createImage().

◆ mdict()

RexxObject* RexxObject::mdict ( )

◆ messageSend() [1/2]

◆ messageSend() [2/2]

bool RexxObject::messageSend ( RexxString msgname,
RexxObject **  arguments,
size_t  count,
size_t  named_count,
RexxObject startscope,
ProtectedObject result,
bool  processUnknown = true 
)

◆ methodLookup()

RexxMethod * RexxObject::methodLookup ( RexxString name)

◆ newObject()

RexxObject* RexxObject::newObject ( )
inline

Definition at line 336 of file ObjectClass.hpp.

References RexxObject().

◆ newRexx()

RexxObject * RexxObject::newRexx ( RexxObject **  arguments,
size_t  argCount,
size_t  named_argCount 
)

Definition at line 2528 of file ObjectClass.cpp.

References RexxObject().

Referenced by RexxMemory::createImage(), and RexxArray::toString().

◆ notEqual()

RexxObject * RexxObject::notEqual ( RexxObject other)

Definition at line 425 of file ObjectClass.cpp.

References ARG_ONE, requiredArgument(), TheFalseObject, and TheTrueObject.

Referenced by RexxMemory::createImage().

◆ numberString()

◆ numberValue() [1/2]

bool RexxObject::numberValue ( wholenumber_t result)
virtual

Reimplemented from RexxInternalObject.

Reimplemented in RexxInteger, RexxNumberString, RexxStem, and RexxString.

Definition at line 1019 of file ObjectClass.cpp.

References RexxString::numberValue(), and REQUEST_STRING().

◆ numberValue() [2/2]

◆ objectName()

◆ objectNameEquals()

RexxObject * RexxObject::objectNameEquals ( RexxObject name)

◆ operator delete() [1/4]

void RexxObject::operator delete ( void *  )
inline

Definition at line 329 of file ObjectClass.hpp.

◆ operator delete() [2/4]

void RexxObject::operator delete ( void *  ,
RexxClass  
)
inline

Definition at line 330 of file ObjectClass.hpp.

◆ operator delete() [3/4]

void RexxObject::operator delete ( void *  ,
RexxClass ,
RexxObject **  ,
size_t   
)
inline

Definition at line 331 of file ObjectClass.hpp.

◆ operator delete() [4/4]

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

Definition at line 328 of file ObjectClass.hpp.

◆ operator new() [1/3]

void* RexxObject::operator new ( size_t  size,
void *  objectPtr 
)
inline

Definition at line 327 of file ObjectClass.hpp.

◆ operator new() [2/3]

SUBTRACT DIVIDE REMAINDER NULLSTRING BLANK BACKSLASH_EQUAL BACKSLASH_GREATERTHAN BACKSLASH_LESSTHAN LESSTHAN_EQUAL STRICT_BACKSLASH_EQUAL STRICT_BACKSLASH_GREATERTHAN STRICT_BACKSLASH_LESSTHAN STRICT_LESSTHAN_EQUAL GREATERTHAN_LESSTHAN OR BACKSLASH void * RexxObject::operator new ( size_t  size,
RexxClass classObject 
)

◆ operator new() [3/3]

void * RexxObject::operator new ( size_t  size,
RexxClass classObject,
RexxObject **  args,
size_t  argCount,
size_t  named_argCount 
)

Definition at line 2654 of file ObjectClass.cpp.

◆ operator RexxInternalObject *()

RexxObject::operator RexxInternalObject * ( )
inline

Definition at line 338 of file ObjectClass.hpp.

◆ oref()

RexxString * RexxObject::oref ( )

Definition at line 2016 of file ObjectClass.cpp.

References new_string().

◆ pmdict()

RexxObject* RexxObject::pmdict ( )

◆ primitiveMakeString()

RexxString * RexxObject::primitiveMakeString ( )
virtual

Reimplemented from RexxInternalObject.

Reimplemented in RexxInteger, and RexxNumberString.

Definition at line 1143 of file ObjectClass.cpp.

References TheNilObject.

Referenced by requestString(), and requestStringNoNOSTRING().

◆ processProtectedMethod()

void RexxObject::processProtectedMethod ( RexxString messageName,
RexxMethod targetMethod,
RexxObject **  arguments,
size_t  count,
size_t  named_count,
ProtectedObject result 
)

◆ processUnknown()

void RexxObject::processUnknown ( RexxString messageName,
RexxObject **  arguments,
size_t  count,
size_t  named_count,
ProtectedObject result 
)

◆ requestArray()

◆ requestDirectory()

◆ requestInteger()

RexxInteger * RexxObject::requestInteger ( size_t  precision)

◆ requestNumber()

bool RexxObject::requestNumber ( wholenumber_t result,
size_t  precision 
)

Request an object to convert itself into a number value.

Parameters
resultThe numeric result value.
precisionThe precision used for the conversion.
Returns
true if the object converted ok, false for a conversion failure.

Definition at line 1403 of file ObjectClass.cpp.

References RexxInternalObject::isBaseClass(), and numberValue().

Referenced by RexxInstructionDo::controlSetup(), RexxInstructionDo::execute(), optionalIntegerArg(), requiredIntegerArg(), and RexxSource::traceNew().

◆ requestRexx()

◆ requestString()

◆ requestStringNoNOSTRING()

RexxString * RexxObject::requestStringNoNOSTRING ( )

◆ requestUnsignedNumber()

bool RexxObject::requestUnsignedNumber ( stringsize_t result,
size_t  precision 
)

Request an object to convert itself into a number value.

Parameters
resultThe numeric result value.
precisionThe precision used for the conversion.
Returns
true if the object converted ok, false for a conversion failure.

Definition at line 1427 of file ObjectClass.cpp.

References RexxInternalObject::isBaseClass(), and unsignedNumberValue().

Referenced by RexxInstructionNumeric::execute(), RexxTrigger::integerTrigger(), RexxSource::optionsDirective(), and RexxSource::useNew().

◆ requiredInteger()

RexxInteger * RexxObject::requiredInteger ( RexxString kind,
size_t  position,
size_t  precision 
)

◆ requiredNonNegative()

◆ requiredNumber()

wholenumber_t RexxObject::requiredNumber ( RexxString kind,
size_t  position,
size_t  precision = Numerics::ARGUMENT_DIGITS 
)

◆ requiredPositive()

stringsize_t RexxObject::requiredPositive ( RexxString kind,
size_t  position,
size_t  precision = Numerics::ARGUMENT_DIGITS 
)

◆ requiredString() [1/3]

RexxString * RexxObject::requiredString ( )

Handle a string request for a required string value where the caller wishes to handle the error itself.

Returns
The object's string value, or OREF_NULL if this is not a string.

Definition at line 1330 of file ObjectClass.cpp.

References RexxInternalObject::isBaseClass(), makeString(), and sendMessage().

Referenced by requiredInteger(), and requiredNumber().

◆ requiredString() [2/3]

RexxString * RexxObject::requiredString ( RexxString kind,
const char *  name 
)

◆ requiredString() [3/3]

RexxString * RexxObject::requiredString ( RexxString kind,
size_t  position 
)

◆ run()

◆ send()

RexxObject * RexxObject::send ( RexxObject **  arguments,
size_t  argCount,
size_t  named_argCount 
)

Do a dynamic invocation of an object method.

Parameters
argumentsThe variable arguments passed to the method. The first argument is a required message target, which can be either a string method name or an array containing a name/scope pair. The remainder of the arguments are the message arguments.
argCount
Returns
The method result.

Definition at line 1818 of file ObjectClass.cpp.

References ARG_ONE, decodeMessageName(), messageSend(), missingArgument(), and OREF_NULL.

Referenced by RexxMemory::createImage().

◆ sendMessage() [1/16]

void RexxObject::sendMessage ( RexxString message,
RexxArray arguments,
RexxDirectory named_arguments,
ProtectedObject result 
)

Definition at line 676 of file ObjectClass.cpp.

References RexxDirectory::appendAllIndexesItemsTo(), RexxArray::copy(), RexxArray::data(), messageSend(), new_array(), OREF_NULL, RexxArray::size(), and TheNilObject.

Referenced by BUILTIN(), SecurityManager::callSecurityManager(), RexxList::classOf(), RexxActivation::closeStreams(), WithSortComparator::compare(), compareTo(), RexxArray::createMultidimensional(), RexxClass::enhanced(), Interpreter::getCurrentQueue(), hash(), RexxString::hash(), ClassDirective::install(), ExtensionDirective::install(), RexxClass::isEqual(), RexxInteger::isEqual(), RexxNumberString::isEqual(), isEqual(), RexxString::isEqual(), RexxActivity::lineIn(), makeArray(), makeString(), RexxClass::methodDictionaryCreate(), RexxClass::methods(), RexxMethod::newFileRexx(), RoutineClass::newFileRexx(), RexxIdentityTable::newRexx(), RexxList::newRexx(), RexxMessage::newRexx(), RexxMethod::newRexx(), RexxMutableBufferClass::newRexx(), RexxQueue::newRexx(), RexxRelation::newRexx(), RoutineClass::newRexx(), RexxStem::newRexx(), RexxSupplierClass::newRexx(), RexxTable::newRexx(), WeakReference::newRexx(), RexxClass::newRexx(), RexxDirectory::newRexx(), RexxActivation::novalueHandler(), objectName(), RexxArray::of(), RexxQueue::ofRexx(), RexxArray::operator new(), RexxSource::processInstall(), RexxActivity::pullInput(), RexxActivity::queue(), RexxStem::request(), RexxDirectory::requestArray(), RexxList::requestArray(), requestArray(), RexxTable::requestArray(), requestDirectory(), requestRexx(), requestString(), requestStringNoNOSTRING(), requiredString(), RexxActivation::resolveStream(), RexxSourceLiteral::RexxSourceLiteral(), MessageDispatcher::run(), RexxActivity::sayOutput(), RexxList::sectionSubclass(), RexxQueue::sectionSubclass(), RexxArray::sectionSubclass(), sendMessage(), stringValue(), RexxClass::subclass(), RexxActivity::traceInput(), RexxActivity::traceOutput(), uninit(), RexxInteger::unknown(), RexxNumberString::unknown(), and RexxStem::unknown().

◆ sendMessage() [2/16]

RexxObject * RexxObject::sendMessage ( RexxString message,
RexxArray args,
RexxDirectory named_args = OREF_NULL 
)

Definition at line 615 of file ObjectClass.cpp.

References sendMessage().

◆ sendMessage() [3/16]

RexxObject * RexxObject::sendMessage ( RexxString message,
RexxObject argument1,
RexxObject argument2 
)

Definition at line 644 of file ObjectClass.cpp.

References sendMessage().

◆ sendMessage() [4/16]

void RexxObject::sendMessage ( RexxString message,
RexxObject argument1,
RexxObject argument2,
ProtectedObject result 
)

Definition at line 707 of file ObjectClass.cpp.

References messageSend().

◆ sendMessage() [5/16]

RexxObject * RexxObject::sendMessage ( RexxString message,
RexxObject argument1,
RexxObject argument2,
RexxObject argument3 
)

Definition at line 652 of file ObjectClass.cpp.

References sendMessage().

◆ sendMessage() [6/16]

void RexxObject::sendMessage ( RexxString message,
RexxObject argument1,
RexxObject argument2,
RexxObject argument3,
ProtectedObject result 
)

Definition at line 724 of file ObjectClass.cpp.

References messageSend().

◆ sendMessage() [7/16]

RexxObject * RexxObject::sendMessage ( RexxString message,
RexxObject argument1,
RexxObject argument2,
RexxObject argument3,
RexxObject argument4 
)

Definition at line 660 of file ObjectClass.cpp.

References sendMessage().

◆ sendMessage() [8/16]

void RexxObject::sendMessage ( RexxString message,
RexxObject argument1,
RexxObject argument2,
RexxObject argument3,
RexxObject argument4,
ProtectedObject result 
)

Definition at line 743 of file ObjectClass.cpp.

References messageSend().

◆ sendMessage() [9/16]

RexxObject * RexxObject::sendMessage ( RexxString message,
RexxObject argument1,
RexxObject argument2,
RexxObject argument3,
RexxObject argument4,
RexxObject argument5 
)

Definition at line 668 of file ObjectClass.cpp.

References sendMessage().

◆ sendMessage() [10/16]

void RexxObject::sendMessage ( RexxString message,
RexxObject argument1,
RexxObject argument2,
RexxObject argument3,
RexxObject argument4,
RexxObject argument5,
ProtectedObject result 
)

Definition at line 764 of file ObjectClass.cpp.

References messageSend().

◆ sendMessage() [11/16]

RexxObject * RexxObject::sendMessage ( RexxString message)

Definition at line 629 of file ObjectClass.cpp.

References sendMessage().

◆ sendMessage() [12/16]

void RexxObject::sendMessage ( RexxString message,
ProtectedObject result 
)
inline

Definition at line 461 of file ObjectClass.hpp.

References messageSend(), and OREF_NULL.

◆ sendMessage() [13/16]

RexxObject * RexxObject::sendMessage ( RexxString message,
RexxObject **  args,
size_t  argCount,
size_t  named_argCount 
)

Definition at line 622 of file ObjectClass.cpp.

References sendMessage().

◆ sendMessage() [14/16]

void RexxObject::sendMessage ( RexxString message,
RexxObject **  args,
size_t  argCount,
size_t  named_argCount,
ProtectedObject result 
)
inline

Definition at line 459 of file ObjectClass.hpp.

References messageSend().

◆ sendMessage() [15/16]

RexxObject * RexxObject::sendMessage ( RexxString message,
RexxObject argument1 
)

Definition at line 636 of file ObjectClass.cpp.

References sendMessage().

◆ sendMessage() [16/16]

void RexxObject::sendMessage ( RexxString message,
RexxObject argument1,
ProtectedObject result 
)

Definition at line 700 of file ObjectClass.cpp.

References messageSend().

◆ sendWith()

RexxObject * RexxObject::sendWith ( RexxObject message,
RexxArray arguments,
RexxObject **  named_arglist,
size_t  named_argcount 
)

Do a dynamic invocation of an object method.

Parameters
messageThe target message. This can be either a string message name or a string/scope pair to do a qualified invocation.
argumentsAn array of arguments to used with the message invocation.
Returns
The method result.

Definition at line 1744 of file ObjectClass.cpp.

References RexxDirectory::appendAllIndexesItemsTo(), ARG_TWO, arrayArgument(), NamedArguments::check(), RexxArray::copy(), RexxArray::data(), decodeMessageName(), Error_Execution_user_defined, RexxDirectory::items(), messageSend(), OREF_NULL, reportException(), requestDirectory(), RexxArray::size(), and TheNilObject.

Referenced by RexxMemory::createImage().

◆ setMdict()

RexxObject* RexxObject::setMdict ( RexxObject )

◆ setMethod()

◆ setObjectVariable()

void RexxObject::setObjectVariable ( RexxString name,
RexxObject value,
RexxObject scope 
)

Definition at line 2350 of file ObjectClass.cpp.

References getObjectVariables(), OREF_NULL, and RexxVariableDictionary::set().

Referenced by objectNameEquals().

◆ start()

RexxMessage * RexxObject::start ( RexxObject **  arguments,
size_t  argCount,
size_t  named_argCount 
)

Run a message send in another thread.

Parameters
argumentsThe list of arguments. This is an open-ended argument list. The first argument is the message, the remaining arguments are the message arguments.
argCountThe number of arguments we were invoked with.
Returns
The count of arguments.

Definition at line 1914 of file ObjectClass.cpp.

References ARG_ONE, missingArgument(), requiredArgument(), and startCommon().

Referenced by RexxArray::arraycopy(), RexxStem::arraycopy(), and RexxMemory::createImage().

◆ startCommon()

RexxMessage * RexxObject::startCommon ( RexxObject message,
RexxObject **  arguments,
size_t  argCount,
size_t  named_argCount 
)

A common method to process either a start() or a startWith() method call.

Parameters
messageThe message name (which might be an array form)
argumentsThe array of arguments.
argCountThe number of passed arguments.
Returns
The message object spun off to process this message.

Definition at line 1939 of file ObjectClass.cpp.

References decodeMessageName(), OREF_NULL, and RexxMessage::start().

Referenced by start(), and startWith().

◆ startWith()

RexxMessage * RexxObject::startWith ( RexxObject message,
RexxArray arguments,
RexxObject **  named_arglist,
size_t  named_argcount 
)

Perform a start() using arguments provided in an array wrapper.

Parameters
messageThe target message. This can be either a string, or an array containing a string/scope coupling.
argumentsThe message arguments.
Returns
The message object.

Definition at line 1854 of file ObjectClass.cpp.

References RexxDirectory::appendAllIndexesItemsTo(), ARG_ONE, ARG_TWO, arrayArgument(), NamedArguments::check(), RexxArray::copy(), RexxArray::data(), Error_Execution_user_defined, RexxDirectory::items(), OREF_NULL, reportException(), requestDirectory(), requiredArgument(), RexxArray::size(), startCommon(), and TheNilObject.

Referenced by RexxMemory::createImage().

◆ strictEqual()

RexxObject * RexxObject::strictEqual ( RexxObject other)

Definition at line 394 of file ObjectClass.cpp.

References ARG_ONE, requiredArgument(), TheFalseObject, and TheTrueObject.

Referenced by RexxMemory::createImage().

◆ strictNotEqual()

RexxObject * RexxObject::strictNotEqual ( RexxObject other)

Definition at line 416 of file ObjectClass.cpp.

References ARG_ONE, requiredArgument(), TheFalseObject, and TheTrueObject.

Referenced by RexxMemory::createImage().

◆ stringRexx()

RexxString * RexxObject::stringRexx ( )

Definition at line 2701 of file ObjectClass.cpp.

References stringValue().

Referenced by RexxMemory::createImage().

◆ stringValue()

◆ superMethod()

RexxMethod * RexxObject::superMethod ( RexxString msgName,
RexxObject startScope 
)

Definition at line 2389 of file ObjectClass.cpp.

References RexxInternalObject::behaviour, and RexxBehaviour::superMethod().

Referenced by messageSend().

◆ superScope()

RexxObject * RexxObject::superScope ( RexxObject startScope)

◆ truthValue()

◆ uninit()

void RexxObject::uninit ( void  )
virtual

Reimplemented from RexxInternalObject.

Definition at line 2508 of file ObjectClass.cpp.

References hasMethod(), sendMessage(), and TheTrueObject.

Referenced by UninitDispatcher::run().

◆ unknown()

virtual RexxObject* RexxObject::unknown ( RexxString msg,
RexxArray args,
RexxDirectory named_args 
)
inlinevirtual

Reimplemented in RexxDirectory, RexxInteger, RexxNumberString, and RexxStem.

Definition at line 385 of file ObjectClass.hpp.

References OREF_NULL.

Referenced by unknownRexx().

◆ unknownRexx()

RexxObject * RexxObject::unknownRexx ( RexxString message,
RexxArray arguments,
RexxObject **  named_arglist,
size_t  named_argcount 
)

Definition at line 2741 of file ObjectClass.cpp.

References NamedArguments::check(), TheNilObject, and unknown().

Referenced by RexxMemory::createImage().

◆ unsetMethod()

RexxObject * RexxObject::unsetMethod ( RexxString msgname)

◆ unsignedNumberValue() [1/2]

bool RexxObject::unsignedNumberValue ( stringsize_t result)
virtual

Reimplemented from RexxInternalObject.

Reimplemented in RexxInteger, RexxStem, RexxNumberString, and RexxString.

Definition at line 1037 of file ObjectClass.cpp.

References REQUEST_STRING(), and RexxString::unsignedNumberValue().

◆ unsignedNumberValue() [2/2]

bool RexxObject::unsignedNumberValue ( stringsize_t result,
size_t  precision 
)
virtual

Member Data Documentation

◆ classInstance

RexxClass * RexxObject::classInstance = OREF_NULL
static

Definition at line 571 of file ObjectClass.hpp.

◆ operatorMethods

PCPPM RexxObject::operatorMethods
static

Definition at line 568 of file ObjectClass.hpp.

Referenced by RexxBehaviour::copy().


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