RexxInteger Class Reference

#include <IntegerClass.hpp>

Inheritance diagram for RexxInteger:
[legend]

Public Member Functions

 RexxInteger (RESTORETYPE restoreType)
 
 RexxInteger (wholenumber_t intValue)
 
void * operator new (size_t size, void *ptr)
 
void * operator new (size_t)
 
void live (size_t)
 
void liveGeneral (int reason)
 
void flatten (RexxEnvelope *)
 
virtual HashCode getHashValue ()
 
virtual wholenumber_t compareTo (RexxObject *)
 
bool numberValue (wholenumber_t &result, size_t precision)
 
bool numberValue (wholenumber_t &result)
 
bool unsignedNumberValue (stringsize_t &result, size_t precision)
 
bool unsignedNumberValue (stringsize_t &result)
 
bool doubleValue (double &result)
 
RexxNumberStringnumberString ()
 
RexxIntegerintegerValue (size_t)
 
RexxStringmakeString ()
 
void copyIntoTail (RexxCompoundTail *)
 
RexxIntegerhasMethod (RexxString *)
 
RexxStringprimitiveMakeString ()
 
RexxStringstringValue ()
 
RexxArraymakeArray ()
 
bool truthValue (int)
 
virtual bool logicalValue (logical_t &)
 
bool isInstanceOf (RexxClass *)
 
RexxMethodinstanceMethod (RexxString *)
 
RexxSupplierinstanceMethods (RexxClass *)
 
bool isEqual (RexxObject *)
 
wholenumber_t strictComp (RexxObject *, RexxString *alternativeOperator=OREF_NULL, RexxInteger **alternativeOperatorResultPtr=NULL)
 
wholenumber_t comp (RexxObject *other, RexxString *alternativeOperator=OREF_NULL, RexxInteger **alternativeOperatorResultPtr=NULL)
 
RexxIntegerequal (RexxObject *)
 
RexxIntegerstrictEqual (RexxObject *)
 
RexxIntegernotEqual (RexxObject *)
 
RexxIntegerstrictNotEqual (RexxObject *)
 
RexxIntegerisGreaterThan (RexxObject *)
 
RexxIntegerisLessThan (RexxObject *)
 
RexxIntegerisGreaterOrEqual (RexxObject *)
 
RexxIntegerisLessOrEqual (RexxObject *)
 
RexxIntegerstrictGreaterThan (RexxObject *)
 
RexxIntegerstrictLessThan (RexxObject *)
 
RexxIntegerstrictGreaterOrEqual (RexxObject *)
 
RexxIntegerstrictLessOrEqual (RexxObject *)
 
RexxObjecthashCode ()
 
RexxObjectunknown (RexxString *, RexxArray *, RexxDirectory *)
 
RexxObjectplus (RexxInteger *)
 
RexxObjectminus (RexxInteger *)
 
RexxObjectmultiply (RexxInteger *)
 
RexxObjectdivide (RexxInteger *)
 
RexxObjectintegerDivide (RexxInteger *)
 
RexxObjectremainder (RexxInteger *)
 
RexxObjectpower (RexxObject *)
 
RexxObjectnotOp ()
 
RexxObjectoperatorNot (RexxObject *)
 
RexxObjectandOp (RexxObject *)
 
RexxObjectorOp (RexxObject *)
 
RexxObjectxorOp (RexxObject *)
 
RexxObjectabs ()
 
RexxObjectsign ()
 
RexxObjectMax (RexxObject **, size_t, size_t)
 
RexxObjectMin (RexxObject **, size_t, size_t)
 
RexxObjecttrunc (RexxObject *)
 
RexxObjectfloor ()
 
RexxObjectceiling ()
 
RexxObjectround ()
 
RexxObjectformat (RexxObject *, RexxObject *, RexxObject *, RexxObject *)
 
RexxObjectd2c (RexxObject *)
 
RexxObjectd2x (RexxObject *)
 
RexxObjectevaluate (RexxActivation *, RexxExpressionStack *)
 
RexxObjectgetValue (RexxActivation *)
 
RexxObjectgetValue (RexxVariableDictionary *)
 
RexxObjectgetRealValue (RexxActivation *)
 
RexxObjectgetRealValue (RexxVariableDictionary *)
 
RexxStringconcat (RexxString *)
 
RexxStringconcatBlank (RexxString *)
 
void setString (RexxString *string)
 
RexxClassclassObject ()
 
 koper (integer_operator_not) inline wholenumber_t getValue()
 
wholenumber_t wholeNumber ()
 
stringsize_t stringSize ()
 
wholenumber_t incrementValue ()
 
wholenumber_t decrementValue ()
 
RexxStringgetStringrep ()
 
- 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 ()
 
bool hasUninitMethod ()
 
RexxObjectinit ()
 
void uninit ()
 
RexxObjectcopy ()
 
HashCode hash ()
 
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)
 
RexxObjectisInstanceOfRexx (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)
 
 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 *)
 
HashCode identityHash ()
 
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 PCPPM operatorMethods []
 
static RexxIntegerClassclassInstance = OREF_NULL
 
static RexxIntegerfalseObject = OREF_NULL
 
static RexxIntegertrueObject = OREF_NULL
 
static RexxIntegernullPointer = OREF_NULL
 
static RexxIntegerintegerZero = OREF_NULL
 
static RexxIntegerintegerOne = OREF_NULL
 
static RexxIntegerintegerTwo = OREF_NULL
 
static RexxIntegerintegerThree = OREF_NULL
 
static RexxIntegerintegerFour = OREF_NULL
 
static RexxIntegerintegerFive = OREF_NULL
 
static RexxIntegerintegerSix = OREF_NULL
 
static RexxIntegerintegerSeven = OREF_NULL
 
static RexxIntegerintegerEight = OREF_NULL
 
static RexxIntegerintegerNine = OREF_NULL
 
static RexxIntegerintegerMinusOne = OREF_NULL
 
- Static Public Attributes inherited from RexxObject
static PCPPM operatorMethods []
 
static RexxClassclassInstance = OREF_NULL
 

Protected Attributes

RexxStringstringrep
 
wholenumber_t value
 

Static Protected Attributes

static wholenumber_t validMaxWhole []
 

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 56 of file IntegerClass.hpp.

Constructor & Destructor Documentation

◆ RexxInteger() [1/2]

RexxInteger::RexxInteger ( RESTORETYPE  restoreType)
inline

Definition at line 58 of file IntegerClass.hpp.

◆ RexxInteger() [2/2]

RexxInteger::RexxInteger ( wholenumber_t  intValue)
inline

Definition at line 59 of file IntegerClass.hpp.

References value.

Member Function Documentation

◆ abs()

RexxObject * RexxInteger::abs ( void  )

◆ andOp()

◆ ceiling()

RexxObject * RexxInteger::ceiling ( )

Calculate the ceiling value for a numeric value

Returns
The ceiling value.

Definition at line 1217 of file IntegerClass.cpp.

Referenced by RexxMemory::createImage().

◆ classObject()

RexxClass * RexxInteger::classObject ( )

Definition at line 1376 of file IntegerClass.cpp.

References TheStringClass.

Referenced by RexxMemory::createImage().

◆ comp()

wholenumber_t RexxInteger::comp ( RexxObject other,
RexxString alternativeOperator = OREF_NULL,
RexxInteger **  alternativeOperatorResultPtr = NULL 
)

Do a comparison operation between an Integer object and another object.

Parameters
otherThe other object.
Returns
true if the two objects compare equal, false for an unequal result.

Definition at line 718 of file IntegerClass.cpp.

References ARG_ONE, RexxNumberString::comp(), Numerics::DEFAULT_DIGITS, RexxInternalObject::isSameType(), number_digits(), numberString(), requiredArgument(), and value.

Referenced by equal(), isGreaterOrEqual(), isGreaterThan(), isLessOrEqual(), isLessThan(), and notEqual().

◆ compareTo()

wholenumber_t RexxInteger::compareTo ( RexxObject other)
virtual

Wrapper around the compareTo() method that does string sort comparisons.

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

Reimplemented from RexxObject.

Definition at line 433 of file IntegerClass.cpp.

References RexxString::compareTo(), and stringValue().

◆ concat()

RexxString * RexxInteger::concat ( RexxString other)

◆ concatBlank()

RexxString * RexxInteger::concatBlank ( RexxString other)

◆ copyIntoTail()

void RexxInteger::copyIntoTail ( RexxCompoundTail tail)
virtual

◆ createInstance()

void RexxInteger::createInstance ( )
static

Definition at line 1395 of file IntegerClass.cpp.

References CLASS_CREATE, and TheIntegerClass.

Referenced by RexxMemory::create().

◆ d2c()

RexxObject * RexxInteger::d2c ( RexxObject length)

Definition at line 1246 of file IntegerClass.cpp.

References RexxNumberString::d2xD2c(), and numberString().

Referenced by RexxMemory::createImage().

◆ d2x()

RexxObject * RexxInteger::d2x ( RexxObject length)

Definition at line 1256 of file IntegerClass.cpp.

References RexxNumberString::d2xD2c(), and numberString().

Referenced by RexxMemory::createImage().

◆ decrementValue()

wholenumber_t RexxInteger::decrementValue ( )
inline

Definition at line 147 of file IntegerClass.hpp.

References value.

Referenced by RexxMemory::setOref().

◆ divide()

RexxObject * RexxInteger::divide ( RexxInteger other)

Definition at line 591 of file IntegerClass.cpp.

References integer_forward.

Referenced by RexxMemory::createImage().

◆ doubleValue()

bool RexxInteger::doubleValue ( double &  result)
virtual

Convert an integer object into a double value.

Parameters
valueThe returned value.
Returns
true if this converted ok, false for any errors. This always returns true for the Integer class.

Reimplemented from RexxObject.

Definition at line 244 of file IntegerClass.cpp.

References wholeNumber().

◆ equal()

RexxInteger * RexxInteger::equal ( RexxObject other)

Definition at line 785 of file IntegerClass.cpp.

References comp(), OREF_NULL, TheFalseObject, TheNilObject, and TheTrueObject.

Referenced by RexxMemory::createImage().

◆ evaluate()

RexxObject * RexxInteger::evaluate ( RexxActivation context,
RexxExpressionStack stack 
)
virtual

◆ flatten()

void RexxInteger::flatten ( RexxEnvelope envelope)
virtual

Reimplemented from RexxObject.

Definition at line 116 of file IntegerClass.cpp.

References cleanUpFlatten, flatten_reference, and setUpFlatten.

◆ floor()

RexxObject * RexxInteger::floor ( )

Calculate the floor value for a numeric value

Returns
The floor value.

Definition at line 1206 of file IntegerClass.cpp.

Referenced by RexxMemory::createImage().

◆ format()

RexxObject * RexxInteger::format ( RexxObject Integers,
RexxObject Decimals,
RexxObject MathExp,
RexxObject ExpTrigger 
)

Definition at line 1234 of file IntegerClass.cpp.

References RexxNumberString::formatRexx(), and numberString().

Referenced by RexxMemory::createImage().

◆ getHashValue()

HashCode RexxInteger::getHashValue ( )
virtual

Get the primitive hash value of this String object.

Returns
The calculated string hash for the string.

Reimplemented from RexxInternalObject.

Definition at line 92 of file IntegerClass.cpp.

References RexxString::getHashValue(), and stringValue().

◆ getRealValue() [1/2]

RexxObject * RexxInteger::getRealValue ( RexxActivation context)
virtual

Reimplemented from RexxInternalObject.

Definition at line 1301 of file IntegerClass.cpp.

◆ getRealValue() [2/2]

RexxObject * RexxInteger::getRealValue ( RexxVariableDictionary context)
virtual

Reimplemented from RexxInternalObject.

Definition at line 1311 of file IntegerClass.cpp.

◆ getStringrep()

RexxString* RexxInteger::getStringrep ( )
inline

Definition at line 148 of file IntegerClass.hpp.

References stringrep.

Referenced by RexxString::integerValue().

◆ getValue() [1/2]

◆ getValue() [2/2]

RexxObject * RexxInteger::getValue ( RexxVariableDictionary context)
virtual

Reimplemented from RexxInternalObject.

Definition at line 1291 of file IntegerClass.cpp.

◆ hashCode()

RexxObject * RexxInteger::hashCode ( )

Exported version of the HASHCODE method for retrieving the object's hash.

Returns
A string version of the hash (generally holds binary characters).

Definition at line 740 of file IntegerClass.cpp.

References RexxObject::hash(), and new_string().

Referenced by RexxMemory::createImage().

◆ hasMethod()

RexxInteger * RexxInteger::hasMethod ( RexxString methodName)
virtual

Reimplemented from RexxObject.

Definition at line 148 of file IntegerClass.cpp.

References RexxObject::hasMethod(), and stringValue().

◆ incrementValue()

wholenumber_t RexxInteger::incrementValue ( )
inline

Definition at line 146 of file IntegerClass.hpp.

References value.

Referenced by RexxMemory::setOref().

◆ instanceMethod()

RexxMethod * RexxInteger::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 RexxObject.

Definition at line 462 of file IntegerClass.cpp.

References RexxObject::instanceMethod(), and stringValue().

◆ instanceMethods()

RexxSupplier * RexxInteger::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 RexxObject.

Definition at line 479 of file IntegerClass.cpp.

References RexxObject::instanceMethods(), and stringValue().

◆ integerDivide()

◆ integerValue()

RexxInteger * RexxInteger::integerValue ( size_t  digits)
virtual

Reimplemented from RexxObject.

Definition at line 340 of file IntegerClass.cpp.

◆ isEqual()

◆ isGreaterOrEqual()

RexxInteger * RexxInteger::isGreaterOrEqual ( RexxObject other)

Definition at line 853 of file IntegerClass.cpp.

References comp(), OREF_NULL, TheFalseObject, TheNilObject, and TheTrueObject.

Referenced by RexxMemory::createImage().

◆ isGreaterThan()

RexxInteger * RexxInteger::isGreaterThan ( RexxObject other)

Definition at line 819 of file IntegerClass.cpp.

References comp(), OREF_NULL, TheFalseObject, TheNilObject, and TheTrueObject.

Referenced by RexxMemory::createImage().

◆ isInstanceOf()

bool RexxInteger::isInstanceOf ( RexxClass other)
virtual

Override for the normal isinstanceof method. This version allows the IntegerClass to "lie" about being a string.

Parameters
otherThe comparison class
Returns
True if the string value is an instance of the target class.

Reimplemented from RexxObject.

Definition at line 448 of file IntegerClass.cpp.

References RexxObject::isInstanceOf(), and stringValue().

◆ isLessOrEqual()

RexxInteger * RexxInteger::isLessOrEqual ( RexxObject other)

Definition at line 870 of file IntegerClass.cpp.

References comp(), OREF_NULL, TheFalseObject, TheNilObject, and TheTrueObject.

Referenced by RexxMemory::createImage().

◆ isLessThan()

RexxInteger * RexxInteger::isLessThan ( RexxObject other)

Definition at line 836 of file IntegerClass.cpp.

References comp(), OREF_NULL, TheFalseObject, TheNilObject, and TheTrueObject.

Referenced by RexxMemory::createImage().

◆ koper()

RexxInteger::koper ( integer_operator_not  )
inline

Definition at line 141 of file IntegerClass.hpp.

References value.

◆ live()

void RexxInteger::live ( size_t  liveMark)
virtual

Reimplemented from RexxObject.

Definition at line 98 of file IntegerClass.cpp.

References memory_mark, and stringrep.

◆ liveGeneral()

void RexxInteger::liveGeneral ( int  reason)
virtual

Reimplemented from RexxObject.

Definition at line 107 of file IntegerClass.cpp.

References memory_mark_general, and stringrep.

◆ logicalValue()

bool RexxInteger::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 RexxObject.

Definition at line 386 of file IntegerClass.cpp.

References value.

◆ makeArray()

RexxArray * RexxInteger::makeArray ( void  )
virtual

Override for the default object makearray method.

Returns
The results of our string representation's makearray.

Reimplemented from RexxObject.

Definition at line 143 of file IntegerClass.cpp.

References RexxString::makeArray(), and stringValue().

◆ makeString()

RexxString * RexxInteger::makeString ( )
virtual

Reimplemented from RexxObject.

Definition at line 129 of file IntegerClass.cpp.

References stringValue().

◆ Max()

RexxObject * RexxInteger::Max ( RexxObject **  args,
size_t  argCount,
size_t  named_argCount 
)

◆ Min()

RexxObject * RexxInteger::Min ( RexxObject **  args,
size_t  argCount,
size_t  named_argCount 
)

◆ minus()

◆ multiply()

◆ notEqual()

RexxInteger * RexxInteger::notEqual ( RexxObject other)

Definition at line 802 of file IntegerClass.cpp.

References comp(), OREF_NULL, TheFalseObject, TheNilObject, and TheTrueObject.

Referenced by RexxMemory::createImage().

◆ notOp()

RexxObject * RexxInteger::notOp ( )

◆ numberString()

RexxNumberString * RexxInteger::numberString ( )
virtual

Reimplemented from RexxObject.

Definition at line 219 of file IntegerClass.cpp.

References new_numberstringFromWholenumber(), RexxString::numberString(), OREF_NULL, stringrep, and value.

Referenced by abs(), comp(), d2c(), d2x(), format(), Max(), Min(), and trunc().

◆ numberValue() [1/2]

bool RexxInteger::numberValue ( wholenumber_t result)
virtual

Convert an integer object into a whole number value using the default digits setting.

Parameters
resultThe returned result.
Returns
true if the number converts ok under the current digits setting. false for any conversion errors.

Reimplemented from RexxObject.

Definition at line 261 of file IntegerClass.cpp.

References Numerics::abs(), Numerics::MAX_WHOLENUMBER, and value.

◆ numberValue() [2/2]

bool RexxInteger::numberValue ( wholenumber_t result,
size_t  digits 
)
virtual

Convert an integer object into a whole number value using the current digits setting.

Parameters
resultThe returned result.
digitsThe digits setting to apply to the conversion.
Returns
true if the number converts ok under the current digits setting. false for any conversion errors.

Reimplemented from RexxObject.

Definition at line 284 of file IntegerClass.cpp.

References Numerics::abs(), Numerics::DEFAULT_DIGITS, Numerics::validMaxWhole, and value.

Referenced by RexxInstructionUseStrict::checkNamedArguments(), and RexxInstructionUseStrict::executeNamedArguments().

◆ operator new() [1/2]

void* RexxInteger::operator new ( size_t  size,
void *  ptr 
)
inline

Definition at line 60 of file IntegerClass.hpp.

◆ operator new() [2/2]

void * RexxInteger::operator new ( size_t  size)

◆ operatorNot()

RexxObject * RexxInteger::operatorNot ( RexxObject dummy)

◆ orOp()

◆ plus()

◆ power()

RexxObject * RexxInteger::power ( RexxObject other)

Definition at line 655 of file IntegerClass.cpp.

References integer_forward.

Referenced by RexxMemory::createImage().

◆ primitiveMakeString()

RexxString * RexxInteger::primitiveMakeString ( )
virtual

◆ remainder()

◆ round()

RexxObject * RexxInteger::round ( )

Calculate the round value for a numeric value

Returns
The round value.

Definition at line 1228 of file IntegerClass.cpp.

Referenced by RexxMemory::createImage().

◆ setString()

void RexxInteger::setString ( RexxString string)

Definition at line 349 of file IntegerClass.cpp.

References OrefSet, RexxInternalObject::setHasReferences(), and stringrep.

Referenced by RexxString::integerValue().

◆ sign()

RexxObject * RexxInteger::sign ( void  )

Definition at line 1078 of file IntegerClass.cpp.

References IntegerOne, IntegerZero, new_integer(), and value.

Referenced by RexxMemory::createImage().

◆ strictComp()

wholenumber_t RexxInteger::strictComp ( RexxObject other,
RexxString alternativeOperator = OREF_NULL,
RexxInteger **  alternativeOperatorResultPtr = NULL 
)

◆ strictEqual()

RexxInteger * RexxInteger::strictEqual ( RexxObject other)

Definition at line 748 of file IntegerClass.cpp.

References OREF_NULL, strictComp(), TheFalseObject, TheNilObject, and TheTrueObject.

Referenced by RexxMemory::createImage().

◆ strictGreaterOrEqual()

RexxInteger * RexxInteger::strictGreaterOrEqual ( RexxObject other)

Definition at line 922 of file IntegerClass.cpp.

References OREF_NULL, strictComp(), TheFalseObject, TheNilObject, and TheTrueObject.

Referenced by RexxMemory::createImage().

◆ strictGreaterThan()

RexxInteger * RexxInteger::strictGreaterThan ( RexxObject other)

Definition at line 888 of file IntegerClass.cpp.

References OREF_NULL, strictComp(), TheFalseObject, TheNilObject, and TheTrueObject.

Referenced by RexxMemory::createImage().

◆ strictLessOrEqual()

RexxInteger * RexxInteger::strictLessOrEqual ( RexxObject other)

Definition at line 939 of file IntegerClass.cpp.

References OREF_NULL, strictComp(), TheFalseObject, TheNilObject, and TheTrueObject.

Referenced by RexxMemory::createImage().

◆ strictLessThan()

RexxInteger * RexxInteger::strictLessThan ( RexxObject other)

Definition at line 905 of file IntegerClass.cpp.

References OREF_NULL, strictComp(), TheFalseObject, TheNilObject, and TheTrueObject.

Referenced by RexxMemory::createImage().

◆ strictNotEqual()

RexxInteger * RexxInteger::strictNotEqual ( RexxObject other)

Definition at line 767 of file IntegerClass.cpp.

References OREF_NULL, strictComp(), TheFalseObject, TheNilObject, and TheTrueObject.

Referenced by RexxMemory::createImage().

◆ stringSize()

stringsize_t RexxInteger::stringSize ( )
inline

Definition at line 145 of file IntegerClass.hpp.

References value.

◆ stringValue()

◆ trunc()

RexxObject * RexxInteger::trunc ( RexxObject decimals)

Definition at line 1191 of file IntegerClass.cpp.

References numberString(), and RexxNumberString::trunc().

Referenced by RexxMemory::createImage().

◆ truthValue()

bool RexxInteger::truthValue ( int  errorcode)
virtual

Reimplemented from RexxObject.

Definition at line 360 of file IntegerClass.cpp.

References reportException(), and value.

Referenced by andOp(), notOp(), operatorNot(), orOp(), and xorOp().

◆ unknown()

RexxObject * RexxInteger::unknown ( RexxString msgname,
RexxArray arguments,
RexxDirectory named_arguments 
)
virtual

Reimplemented from RexxObject.

Definition at line 411 of file IntegerClass.cpp.

References RexxObject::sendMessage(), and stringValue().

◆ unsignedNumberValue() [1/2]

bool RexxInteger::unsignedNumberValue ( stringsize_t result)
virtual

Convert an integer object into an unsigned whole number value using the default digits setting.

Parameters
resultThe returned result.
Returns
true if the number converts ok under the current digits setting. false for any conversion errors.

Reimplemented from RexxObject.

Definition at line 306 of file IntegerClass.cpp.

References Numerics::MAX_WHOLENUMBER, and wholeNumber().

◆ unsignedNumberValue() [2/2]

bool RexxInteger::unsignedNumberValue ( stringsize_t result,
size_t  digits 
)
virtual

Convert an integer object into an unsigned whole number value using the current digits setting.

Parameters
resultThe returned result.
digitsThe digits setting to apply to the conversion.
Returns
true if the number converts ok under the current digits setting. false for any conversion errors.

Reimplemented from RexxObject.

Definition at line 328 of file IntegerClass.cpp.

References Numerics::validMaxWhole, value, and wholeNumber().

◆ wholeNumber()

wholenumber_t RexxInteger::wholeNumber ( )
inline

Definition at line 144 of file IntegerClass.hpp.

References value.

Referenced by doubleValue(), RexxQueue::locateEntry(), and unsignedNumberValue().

◆ xorOp()

Member Data Documentation

◆ classInstance

RexxIntegerClass * RexxInteger::classInstance = OREF_NULL
static

Definition at line 152 of file IntegerClass.hpp.

◆ falseObject

RexxInteger * RexxInteger::falseObject = OREF_NULL
static

Definition at line 154 of file IntegerClass.hpp.

◆ integerEight

RexxInteger * RexxInteger::integerEight = OREF_NULL
static

Definition at line 166 of file IntegerClass.hpp.

◆ integerFive

RexxInteger * RexxInteger::integerFive = OREF_NULL
static

Definition at line 163 of file IntegerClass.hpp.

◆ integerFour

RexxInteger * RexxInteger::integerFour = OREF_NULL
static

Definition at line 162 of file IntegerClass.hpp.

◆ integerMinusOne

RexxInteger * RexxInteger::integerMinusOne = OREF_NULL
static

Definition at line 168 of file IntegerClass.hpp.

◆ integerNine

RexxInteger * RexxInteger::integerNine = OREF_NULL
static

Definition at line 167 of file IntegerClass.hpp.

◆ integerOne

RexxInteger * RexxInteger::integerOne = OREF_NULL
static

Definition at line 159 of file IntegerClass.hpp.

◆ integerSeven

RexxInteger * RexxInteger::integerSeven = OREF_NULL
static

Definition at line 165 of file IntegerClass.hpp.

◆ integerSix

RexxInteger * RexxInteger::integerSix = OREF_NULL
static

Definition at line 164 of file IntegerClass.hpp.

◆ integerThree

RexxInteger * RexxInteger::integerThree = OREF_NULL
static

Definition at line 161 of file IntegerClass.hpp.

◆ integerTwo

RexxInteger * RexxInteger::integerTwo = OREF_NULL
static

Definition at line 160 of file IntegerClass.hpp.

◆ integerZero

RexxInteger * RexxInteger::integerZero = OREF_NULL
static

Definition at line 158 of file IntegerClass.hpp.

◆ nullPointer

RexxInteger * RexxInteger::nullPointer = OREF_NULL
static

Definition at line 156 of file IntegerClass.hpp.

◆ operatorMethods

PCPPM RexxInteger::operatorMethods
static

Definition at line 151 of file IntegerClass.hpp.

◆ stringrep

RexxString* RexxInteger::stringrep
protected

◆ trueObject

RexxInteger * RexxInteger::trueObject = OREF_NULL
static

Definition at line 155 of file IntegerClass.hpp.

◆ validMaxWhole

wholenumber_t RexxInteger::validMaxWhole[]
staticprotected

Definition at line 175 of file IntegerClass.hpp.

◆ value


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