static sqInt
makeDirEntryNamesizecreateDatemodDateisDirfileSizeposixPermissionsisSymlink(char *entryName, sqInt entryNameSize, sqInt createDate, sqInt modifiedDate, sqInt dirFlag, squeakFileOffsetType  fileSize, sqInt posixPermissions, sqInt symlinkFlag)
{
	// FilePlugin>>#makeDirEntryName:size:createDate:modDate:isDir:fileSize:posixPermissions:isSymlink:
    sqInt createDateOop;
    sqInt fileSizeOop;
    sqInt i;
    sqInt modDateOop;
    sqInt nameString;
    sqInt posixPermissionsOop;
    sqInt results;
    char *stringPtr;


	/* allocate storage for results, remapping newly allocated
	   oops in case GC happens during allocation */

	pushRemappableOop(instantiateClassindexableSize(classArray(), 7));
	pushRemappableOop(instantiateClassindexableSize(classString(), entryNameSize));
	pushRemappableOop(positive32BitIntegerFor(createDate));
	pushRemappableOop(positive32BitIntegerFor(modifiedDate));
	pushRemappableOop(positive64BitIntegerFor(fileSize));
	pushRemappableOop(positive32BitIntegerFor(posixPermissions));
	posixPermissionsOop = popRemappableOop();
	fileSizeOop = popRemappableOop();
	modDateOop = popRemappableOop();
	createDateOop = popRemappableOop();
	nameString = popRemappableOop();

	/* copy name into Smalltalk string */

results = popRemappableOop();
	stringPtr = firstIndexableField(nameString);
	for (i = 0; i < entryNameSize; i += 1) {
stringPtr[i] = (entryName[i]);
	}
	storePointerofObjectwithValue(0, results, nameString);
	storePointerofObjectwithValue(1, results, createDateOop);
	storePointerofObjectwithValue(2, results, modDateOop);
	if (dirFlag) {
storePointerofObjectwithValue(3, results, trueObject());
	}
	else {
storePointerofObjectwithValue(3, results, falseObject());
	}
	storePointerofObjectwithValue(4, results, fileSizeOop);
	storePointerofObjectwithValue(5, results, posixPermissionsOop);
	if (symlinkFlag) {
storePointerofObjectwithValue(6, results, trueObject());
	}
	else {
storePointerofObjectwithValue(6, results, falseObject());
	}
	return results;
}
Example #2
0
primitiveDaylightSavings(void)
{
	sqInt _return_value;

	_return_value = (((sqLocDaylightSavings())) ? trueObject() : falseObject());
	if (failed()) {
		return null;
	}
	popthenPush(1, _return_value);
	return null;
}
Example #3
0
primitiveMeasurementMetric(void)
{
	sqInt _return_value;

	_return_value = (((sqLocMeasurementMetric())) ? trueObject() : falseObject());
	if (failed()) {
		return null;
	}
	popthenPush(1, _return_value);
	return null;
}
Example #4
0
primitiveCurrencyNotation(void)
{
	sqInt _return_value;

	_return_value = (((sqLocCurrencyNotation())) ? trueObject() : falseObject());
	if (failed()) {
		return null;
	}
	popthenPush(1, _return_value);
	return null;
}