77 name = OREF_NULLSTRING;
211 p_named_arguments = named_arguments;
220 size_t argumentsCount = arguments ? arguments->
size() : 0;
221 size_t namedArgumentsCount = (named_arguments !=
OREF_NULL && named_arguments !=
TheNilObject) ? named_arguments->
items() : 0;
225 if (namedArgumentsCount != 0)
239 size_t named_argCount)
393 size_t named_argCount)
407 new_value = tailElements[0];
429 variable->
set(new_value);
541 size_t named_argCount)
567 newObj->
sendMessage(OREF_INIT, init_args, argCount, named_argCount);
571 void *RexxStem::operator
new(
size_t size)
690 variable->
set(_value);
738 _value = this->
value;
749 _value =
handleNovalue(context, tail_name, defaultValue, variable);
765 _value =
handleNovalue(context, tail_name, defaultValue, variable);
1096 variable->
set(_value);
1111 variable->
set(_value);
1284 size_t len = right - left + 1;
1287 for (
size_t i = left + 1; i <= right; i++) {
1290 if (comparator(sd, current, prev) < 0) {
1293 strings[j--] = prev;
1294 }
while (j > left && comparator(sd, current, prev = strings[j - 1]) < 0);
1295 strings[j] = current;
1301 size_t mid = (right + left) / 2;
1302 mergeSort(sd, comparator, strings, working, left, mid);
1303 mergeSort(sd, comparator, strings, working, mid + 1, right);
1304 merge(sd, comparator, strings, working, left, mid + 1, right);
1321 size_t leftEnd = mid - 1;
1325 if (comparator(sd, strings[leftEnd], strings[mid]) <= 0) {
1329 size_t leftCursor = left;
1330 size_t rightCursor = mid;
1331 size_t workingPosition = left;
1338 if (comparator(sd, fromVal, rightVal) <= 0)
1340 size_t leftInsertion =
find(sd, comparator, strings, rightVal, -1, leftCursor + 1, leftEnd);
1341 size_t toCopy = leftInsertion - leftCursor + 1;
1342 arraycopy(strings, leftCursor, working, workingPosition, toCopy);
1343 workingPosition += toCopy;
1344 working[workingPosition++] = rightVal;
1349 leftCursor = leftInsertion + 1;
1353 size_t rightInsertion =
find(sd, comparator, strings, fromVal, 0, rightCursor + 1, right);
1354 size_t toCopy = rightInsertion - rightCursor + 1;
1355 arraycopy(strings, rightCursor, working, workingPosition, toCopy);
1356 workingPosition += toCopy;
1358 working[workingPosition++] = fromVal;
1360 rightCursor = rightInsertion + 1;
1362 }
while (right >= rightCursor && mid > leftCursor);
1366 if (leftCursor < mid)
1368 arraycopy(strings, leftCursor, working, workingPosition, mid - leftCursor);
1372 arraycopy(strings, rightCursor, working, workingPosition, right - rightCursor + 1);
1375 arraycopy(working, left, strings, left, right - left + 1);
1389 for (
size_t i =
start; i <
start + count; i++)
1391 target[
index++] = source[i];
1414 size_t checkPoint = left;
1416 while (checkPoint <= right)
1419 if (comparator(sd, val, strings[checkPoint]) > limit)
1422 left = checkPoint + 1;
1427 right = checkPoint - 1;
1431 checkPoint += delta;
1437 while (left <= right)
1440 checkPoint = (left + right) / 2;
1441 if (comparator(sd, val, strings[checkPoint]) > limit)
1444 left = checkPoint + 1;
1449 right = checkPoint - 1;
1502 if (_first > count || last > count) {
1505 size_t bounds = last - _first + 1;
1514 for (j = 1, i = _first; i <= last; i++, j++)
1531 array->
put(nextValue, j + bounds);
1545 if ((firstcol == 0) && (lastcol ==
SIZE_MAX)) {
1551 aData, working, 0, bounds - 1);
1555 aData, working, 0, bounds - 1);
1569 aData, working, 0, bounds - 1);
1573 aData, working, 0, bounds - 1);
1582 for (i = 1; i <= bounds; i++) {
1585 element->
set(_value);
void reportException(wholenumber_t error)
RexxArray * new_array(size_t s)
RexxDirectory * new_directory()
RexxInteger * new_integer(wholenumber_t v)
#define markGeneralCompoundTable()
#define markCompoundTable()
#define flattenCompoundTable()
RexxString * stringArgument(RexxObject *object, RexxString *kind, size_t position)
RexxArray * REQUEST_ARRAY(RexxObject *obj)
RexxString * REQUEST_STRING(RexxObject *object)
void requiredArgument(RexxObject *object, RexxString *kind, size_t position)
#define Error_Execution_user_defined
#define Error_Execution_nostem
#define Error_Incorrect_method_noarg
#define Error_Incorrect_method_noarray
#define memory_mark(oref)
RexxObject * new_object(size_t s)
#define flatten_reference(oref, envel)
#define CLASS_CREATE(name, id, className)
#define memory_mark_general(oref)
#define setUpFlatten(type)
RexxVariable * new_variable(RexxString *n)
int compare_desc_cols(SortData *sd, RexxString *arg1, RexxString *arg2)
int compare_asc(SortData *sd, RexxString *arg1, RexxString *arg2)
int compare_desc(SortData *sd, RexxString *arg1, RexxString *arg2)
int compare_desc_i(SortData *sd, RexxString *arg1, RexxString *arg2)
int compare_asc_i_cols(SortData *sd, RexxString *arg1, RexxString *arg2)
int compare_asc_i(SortData *sd, RexxString *arg1, RexxString *arg2)
int compare_desc_i_cols(SortData *sd, RexxString *arg1, RexxString *arg2)
int compare_asc_cols(SortData *sd, RexxString *arg1, RexxString *arg2)
#define SORT_CASESENSITIVE
RexxSupplier * new_supplier(RexxArray *c, RexxArray *f)
static const size_t DEFAULT_DIGITS
RexxObject * handleNovalueEvent(RexxString *name, RexxObject *defaultValue, RexxVariable *variable)
void put(RexxObject *eref, size_t pos)
RexxObject * get(size_t pos)
static void processNewArgs(RexxObject **, size_t, RexxObject ***, size_t *, size_t, RexxObject **, RexxObject **)
RexxBehaviour * getInstanceBehaviour()
RexxCompoundElement * realVariable()
void copyFrom(RexxCompoundTable &other)
RexxCompoundElement * findEntry(RexxCompoundTail *tail)
void init(RexxStem *parent)
RexxCompoundElement * first()
RexxCompoundElement * next(RexxCompoundElement *node)
RexxString * createCompoundName(RexxString *)
RexxObject * put(RexxObject *, RexxString *)
size_t appendAllIndexesItemsTo(RexxArray *array, size_t from)
void setBehaviour(RexxBehaviour *b)
void setCompoundElement(RexxCompoundElement *element)
RexxCompoundElement * compoundElement()
void setNextStem(RexxVariable *stemVar)
RexxMessage * start(RexxObject **, size_t, size_t)
RexxNumberString * numberString()
RexxInteger * integerValue(size_t)
virtual bool doubleValue(double &result)
bool equalValue(RexxObject *other)
RexxString * stringValue()
void sendMessage(RexxString *, RexxArray *, RexxDirectory *, ProtectedObject &)
RexxDirectory * requestDirectory()
virtual bool numberValue(wholenumber_t &result, size_t precision)
virtual bool unsignedNumberValue(stringsize_t &result, size_t precision)
bool numberValue(wholenumber_t &result, size_t precision)
RexxString * createCompoundName(RexxCompoundTail *tailPart)
RexxCompoundElement * getCompoundVariable(RexxCompoundTail *name)
RexxObject * getCompoundVariableValue(RexxCompoundTail *resolved_tail)
RexxObject * remove(RexxObject **, size_t, size_t)
void mergeSort(SortData *sd, int(*comparator)(SortData *, RexxString *, RexxString *), RexxString **strings, RexxString **working, size_t left, size_t right)
RexxCompoundElement * exposeCompoundVariable(RexxCompoundTail *name)
RexxObject * newRexx(RexxObject **, size_t, size_t)
RexxObject * getCompoundVariableRealValue(RexxCompoundTail *resolved_tail)
static RexxClass * classInstance
void flatten(RexxEnvelope *)
void setElement(const char *tail, RexxObject *value)
RexxInteger * integerValue(size_t)
void copyFrom(RexxCompoundTable &_tails)
bool sort(RexxString *prefix, int order, int type, size_t start, size_t end, size_t firstcol, size_t lastcol)
RexxNumberString * numberString()
void dropCompoundVariable(RexxCompoundTail *name)
void setCompoundVariable(RexxCompoundTail *name, RexxObject *value)
RexxObject * getStemValue()
static void createInstance()
RexxObject * index(RexxObject *)
RexxString * stringValue()
bool unsignedNumberValue(stringsize_t &result, size_t precision)
RexxSupplier * supplier()
void merge(SortData *sd, int(*comparator)(SortData *, RexxString *, RexxString *), RexxString **strings, RexxString **working, size_t left, size_t mid, size_t right)
RexxCompoundElement * nextVariable(RexxNativeActivation *activation)
RexxObject * handleNovalue(RexxActivation *context, RexxString *name, RexxObject *defaultValue, RexxCompoundElement *variable)
RexxObject * bracketEqual(RexxObject **, size_t, size_t)
size_t find(SortData *sd, int(*comparator)(SortData *, RexxString *, RexxString *), RexxString **strings, RexxString *val, int bnd, size_t left, size_t right)
RexxCompoundElement * findCompoundVariable(RexxCompoundTail *name)
void expose(RexxCompoundElement *variable)
RexxObject * evaluateCompoundVariableValue(RexxActivation *context, RexxString *stemVariableName, RexxCompoundTail *resolved_tail)
void dropElement(const char *tail)
RexxCompoundElement * findByValue(RexxObject *target)
RexxObject * bracket(RexxObject **, size_t, size_t)
RexxObject * getElement(size_t tail)
RexxDirectory * toDirectory()
RexxObject * realCompoundVariableValue(RexxCompoundTail *resolved_tail)
RexxObject * removeItem(RexxObject *)
RexxObject * request(RexxString *)
void liveGeneral(int reason)
RexxObject * hasIndex(RexxObject **, size_t, size_t)
void setValue(RexxObject *value)
RexxObject * hasItem(RexxObject *)
void arraycopy(RexxString **source, size_t start, RexxString **target, size_t index, size_t count)
RexxObject * unknown(RexxString *, RexxArray *, RexxDirectory *)
bool doubleValue(double &result)
int sortCaselessCompare(RexxString *other)
bool strCompare(const char *s)
int sortCompare(RexxString *other)
void set(RexxObject *value)
RexxObject * getVariableValue()
stringsize_t columnLength