Up

Functions

Authors

Richard Frith-Macdonald

Contents -

  1. Function index
  2. Macro index
  3. GSCategories functions
  4. GSIArray functions
  5. GSIMap functions
  6. GSObjCRuntime functions
  7. behavior functions
  8. Unicode functions
  9. GSObjCRuntime macros

Function index

Function

Macro index

Macro

GSCategories functions

GSCurrentThread

NSThread* GSCurrentThread();

Description forthcoming.


GSCurrentThreadDictionary

NSMutableDictionary* GSCurrentThreadDictionary();

Description forthcoming.


GSDebugFunctionMsg

NSString* GSDebugFunctionMsg(const char* func, const char* file, int line, NSString* fmt);

Description forthcoming.


GSDebugMethodMsg

NSString* GSDebugMethodMsg(id obj, SEL sel, const char* file, int line, NSString* fmt);

Description forthcoming.


GSDebugSet

BOOL GSDebugSet(NSString* level);

Description forthcoming.


GSEncodingName

NSString* GSEncodingName(NSStringEncoding availableEncodingValue);

Description forthcoming.


GetEncodingName

NSString* GetEncodingName(NSStringEncoding availableEncodingValue);

Description forthcoming.


NSDecimalFromComponents

void NSDecimalFromComponents(NSDecimal* result, unsigned long long int mantissa, short int exponent, BOOL negative);

Description forthcoming.


NSStandardLibraryPaths

NSArray* NSStandardLibraryPaths();

Description forthcoming.


GSIArray functions

GSIArrayAddItem

void GSIArrayAddItem(GSIArray array, GSIArrayItem item);

Description forthcoming.


GSIArrayAddItemNoRetain

void GSIArrayAddItemNoRetain(GSIArray array, GSIArrayItem item);

Description forthcoming.


GSIArrayCapacity

unsigned int GSIArrayCapacity(GSIArray array);

Description forthcoming.


GSIArrayCheckSort

void GSIArrayCheckSort(GSIArray array, NSComparisonResult(*) sorter);

Description forthcoming.


GSIArrayClear

void GSIArrayClear(GSIArray array);

Description forthcoming.


GSIArrayCopyWithZone

GSIArray GSIArrayCopyWithZone(GSIArray array, NSZone* zone);

Description forthcoming.


GSIArrayCount

unsigned int GSIArrayCount(GSIArray array);

Description forthcoming.


GSIArrayEmpty

void GSIArrayEmpty(GSIArray array);

Description forthcoming.


GSIArrayGrow

void GSIArrayGrow(GSIArray array);

Description forthcoming.


GSIArrayGrowTo

void GSIArrayGrowTo(GSIArray array, unsigned int next);

Description forthcoming.


GSIArrayInitWithZoneAndCapacity

GSIArray GSIArrayInitWithZoneAndCapacity(GSIArray array, NSZone* zone, size_t capacity);

Description forthcoming.


GSIArrayInsertItem

void GSIArrayInsertItem(GSIArray array, GSIArrayItem item, unsigned int index);

Description forthcoming.


GSIArrayInsertItemNoRetain

void GSIArrayInsertItemNoRetain(GSIArray array, GSIArrayItem item, unsigned int index);

Description forthcoming.


GSIArrayInsertSorted

void GSIArrayInsertSorted(GSIArray array, GSIArrayItem item, NSComparisonResult(*) sorter);

Description forthcoming.


GSIArrayInsertSortedNoRetain

void GSIArrayInsertSortedNoRetain(GSIArray array, GSIArrayItem item, NSComparisonResult(*) sorter);

Description forthcoming.


GSIArrayInsertionPosition

unsigned int GSIArrayInsertionPosition(GSIArray array, GSIArrayItem item, NSComparisonResult(*) sorter);

Description forthcoming.


GSIArrayItemAtIndex

GSIArrayItem GSIArrayItemAtIndex(GSIArray array, unsigned int index);

Description forthcoming.


GSIArrayItems

GSIArrayItem* GSIArrayItems(GSIArray array);

Description forthcoming.


GSIArrayLastItem

GSIArrayItem GSIArrayLastItem(GSIArray array);

Description forthcoming.


GSIArrayRemoveAllItems

void GSIArrayRemoveAllItems(GSIArray array);

Description forthcoming.


GSIArrayRemoveItemAtIndex

void GSIArrayRemoveItemAtIndex(GSIArray array, unsigned int index);

Description forthcoming.


GSIArrayRemoveItemAtIndexNoRelease

void GSIArrayRemoveItemAtIndexNoRelease(GSIArray array, unsigned int index);

Description forthcoming.


GSIArrayRemoveItemsFromIndex

void GSIArrayRemoveItemsFromIndex(GSIArray array, unsigned int index);

Description forthcoming.


GSIArrayRemoveLastItem

void GSIArrayRemoveLastItem(GSIArray array);

Description forthcoming.


GSIArraySetItemAtIndex

void GSIArraySetItemAtIndex(GSIArray array, GSIArrayItem item, unsigned int index);

Description forthcoming.


GSIMap functions

GSIMapAddKey

GSIMapNode GSIMapAddKey(GSIMapTable map, GSIMapKey key);

Description forthcoming.


GSIMapAddKeyNoRetain

GSIMapNode GSIMapAddKeyNoRetain(GSIMapTable map, GSIMapKey key);

Description forthcoming.


GSIMapAddNodeToBucket

void GSIMapAddNodeToBucket(GSIMapBucket bucket, GSIMapNode node);

Description forthcoming.


GSIMapAddNodeToMap

void GSIMapAddNodeToMap(GSIMapTable map, GSIMapNode node);

Description forthcoming.


GSIMapAddPair

GSIMapNode GSIMapAddPair(GSIMapTable map, GSIMapKey key, GSIMapVal value);

Description forthcoming.


GSIMapAddPairNoRetain

GSIMapNode GSIMapAddPairNoRetain(GSIMapTable map, GSIMapKey key, GSIMapVal value);

Description forthcoming.


GSIMapBucketForKey

GSIMapBucket GSIMapBucketForKey(GSIMapTable map, GSIMapKey key);

Description forthcoming.


GSIMapCleanMap

void GSIMapCleanMap(GSIMapTable map);

Description forthcoming.


GSIMapEmptyMap

void GSIMapEmptyMap(GSIMapTable map);

Description forthcoming.


GSIMapEndEnumerator

void GSIMapEndEnumerator(GSIMapEnumerator enumerator);

Tidies up after map enumeration... effectively destroys the enumerator.


GSIMapEnumeratorBucket

GSIMapBucket GSIMapEnumeratorBucket(GSIMapEnumerator enumerator);

Returns the bucket from which the next node in the enumeration will come. Once the next node has been enumerated, you can use the bucket and node to remove the node from the map using the GSIMapRemoveNodeFromMap() function.


GSIMapEnumeratorForMap

GSIMapEnumerator_t GSIMapEnumeratorForMap(GSIMapTable map);

Enumerating
Create an return an enumerator for the specified map.
You must call GSIMapEndEnumerator() when you have finished with the enumerator.
WARNING You should not alter a map while an enumeration is in progress. The results of doing so are reasonably unpredictable.
Remember, DON'T MESS WITH A MAP WHILE YOU'RE ENUMERATING IT.


GSIMapEnumeratorNextNode

GSIMapNode GSIMapEnumeratorNextNode(GSIMapEnumerator enumerator);

Returns the next node in the map, or a nul pointer if at the end.


GSIMapFreeNode

void GSIMapFreeNode(GSIMapTable map, GSIMapNode node);

Description forthcoming.


GSIMapInitWithZoneAndCapacity

void GSIMapInitWithZoneAndCapacity(GSIMapTable map, NSZone* zone, size_t capacity);

Description forthcoming.


GSIMapLinkNodeIntoBucket

void GSIMapLinkNodeIntoBucket(GSIMapBucket bucket, GSIMapNode node);

Description forthcoming.


GSIMapMoreNodes

void GSIMapMoreNodes(GSIMapTable map, unsigned int required);

Description forthcoming.


GSIMapNewNode

GSIMapNode GSIMapNewNode(GSIMapTable map, GSIMapKey key);

Description forthcoming.


GSIMapNodeForKey

GSIMapNode GSIMapNodeForKey(GSIMapTable map, GSIMapKey key);

Description forthcoming.


GSIMapNodeForKeyInBucket

GSIMapNode GSIMapNodeForKeyInBucket(GSIMapTable map, GSIMapBucket bucket, GSIMapKey key);

Description forthcoming.


GSIMapNodeForSimpleKey

GSIMapNode GSIMapNodeForSimpleKey(GSIMapTable map, GSIMapKey key);

Description forthcoming.


GSIMapPickBucket

GSIMapBucket GSIMapPickBucket(unsigned int hash, GSIMapBucket buckets, size_t bucketCount);

Description forthcoming.


GSIMapRemangleBuckets

void GSIMapRemangleBuckets(GSIMapTable map, GSIMapBucket old_buckets, size_t old_bucketCount, GSIMapBucket new_buckets, size_t new_bucketCount);

Description forthcoming.


GSIMapRemoveKey

void GSIMapRemoveKey(GSIMapTable map, GSIMapKey key);

Description forthcoming.


GSIMapRemoveNodeFromBucket

void GSIMapRemoveNodeFromBucket(GSIMapBucket bucket, GSIMapNode node);

Description forthcoming.


GSIMapRemoveNodeFromMap

void GSIMapRemoveNodeFromMap(GSIMapTable map, GSIMapBucket bkt, GSIMapNode node);

Description forthcoming.


GSIMapResize

void GSIMapResize(GSIMapTable map, size_t new_capacity);

Description forthcoming.


GSIMapRightSizeMap

void GSIMapRightSizeMap(GSIMapTable map, size_t capacity);

Description forthcoming.


GSIMapUnlinkNodeFromBucket

void GSIMapUnlinkNodeFromBucket(GSIMapBucket bucket, GSIMapNode node);

Description forthcoming.


GSObjCRuntime functions

GSAutoreleasedBuffer

void* GSAutoreleasedBuffer(unsigned int size);

Quickly return autoreleased data storage area.


GSCGetInstanceVariableDefinition

GSIVar GSCGetInstanceVariableDefinition(Class class, const char* name);

Returns the pointer to the instance variable structure for the instance variable name in the specified class. This function searches the specified class and its superclasses.
It should be safe to use this function in +load implementations.
This function should currently (June 2003) be considered WIP. Please follow potential changes (Name, parameters,...) closely until it stabilizes.


GSFindInstanceVariable

BOOL GSFindInstanceVariable(id obj, const char* name, const char** type, unsigned int* size, int* offset);

Deprecated... use GSObjCFindVariable()


GSGetClassMethodNotInherited

GSMethod GSGetClassMethodNotInherited(Class class, SEL sel);

Returns the pointer to the class method structure for the selector in the specified class. This function only searches the specified class and not its superclasses.
To obtain the implementation pointer IMP use returnValue->method_imp which should be safe across all runtimes.
It should be safe to use this function in +load implementations.
This function should currently (June 2003) be considered WIP. Please follow potential changes (Name, parameters,...) closely until it stabilizes.


GSGetInstanceMethodNotInherited

GSMethod GSGetInstanceMethodNotInherited(Class class, SEL sel);

Returns the pointer to the instance method structure for the selector in the specified class. This function only searches the specified class and not its superclasses.
To obtain the implementation pointer IMP use returnValue->method_imp which should be safe across all runtimes.
It should be safe to use this function in +load implementations.
This function should currently (June 2003) be considered WIP. Please follow potential changes (Name, parameters,...) closely until it stabilizes.


GSGetValue

id GSGetValue(NSObject* self, NSString* key, SEL sel, const char* type, unsigned int size, int offset);

Deprecated... use GSObjCGetValue()


GSGetVariable

void GSGetVariable(id obj, int offset, unsigned int size, void* data);

Deprecated... use GSObjCGetVariable()


GSLastErrorStr

const char* GSLastErrorStr(long int error_id);

Returns a system error message on a variety of systems


GSObjCAddClassBehavior

void GSObjCAddClassBehavior(Class receiver, Class behavior);

A Behavior can be seen as a "Protocol with an implementation" or a "Class without any instance variables". A key feature of behaviors is that they give a degree of multiple inheritance.

Behavior methods, when added to a class, override the class's superclass methods, but not the class's methods.

It's not the case that a class adding behaviors from another class must have "no instance vars". The receiver class just has to have the same layout as the behavior class (optionally with some additional ivars after those of the behavior class).

This function provides Behaviors without adding any new syntax to the Objective C language. Simply define a class with the methods you want to add, then call this function with that class as the behavior argument.

This function should be called in the +initialize method of the receiver.

If you add several behaviors to a class, be aware that the order of the additions is significant.


GSObjCAddClasses

void GSObjCAddClasses(NSArray* classes);

Description forthcoming.


GSObjCFindVariable

BOOL GSObjCFindVariable(id obj, const char* name, const char** type, unsigned int* size, int* offset);

This function is used to locate information about the instance variable of obj called name. It returns YES if the variable was found, NO otherwise. If it returns YES, then the values pointed to by type, size, and offset will be set (except where they are null pointers).


GSObjCGetInstanceVariableDefinition

GSIVar GSObjCGetInstanceVariableDefinition(Class class, NSString* name);

Returns the pointer to the instance variable structure for the instance variable name in the specified class. This function searches the specified class and its superclasses.
It is not necessarily safe to use this function in +load implementations.
This function should currently (June 2003) be considered WIP. Please follow potential changes (Name, parameters,...) closely until it stabilizes.


GSObjCGetValue

id GSObjCGetValue(NSObject* self, NSString* key, SEL sel, const char* type, unsigned int size, int offset);

This is used internally by the key-value coding methods, to get a value from an object either via an accessor method (if sel is supplied), or via direct access (if type, size, and offset are supplied).
Automatic conversion between NSNumber and C scalar types is performed.
If type is null and can't be determined from the selector, the [NSObject -handleQueryWithUnboundKey:] method is called to try to get a value.


GSObjCGetVariable

void GSObjCGetVariable(id obj, int offset, unsigned int size, void* data);

Gets the value from an instance variable in obj
This function performs no checking... you should use it only where you are providing information from a call to GSFindVariable() and you know that the data area provided is the correct size.


GSObjCMakeClass

NSValue* GSObjCMakeClass(NSString* name, NSString* superName, NSDictionary* iVars);

references: http://www.macdevcenter.com/pub/a/mac/2002/05/31/runtime_parttwo.html?page=1 http://developer.apple.com/techpubs/macosx/Cocoa/ObjectiveC/9objc_runtime_reference/_Adding_Classes.html http://developer.apple.com/techpubs/macosx/Cocoa/ObjectiveC/9objc_runtime_reference/_Class_Defi__Structures.html ObjcRuntimeUtilities.m by Nicola Pero

Create a Class structure for use by the ObjectiveC runtime and return an NSValue object pointing to it. The class will not be added to the runtime (you must do that later using the GSObjCAddClasses() function).

The iVars dictionary lists the instance variable names and their types.


GSObjCMethodNames

NSArray* GSObjCMethodNames(id obj);

This method returns an array listing the names of all the instance methods available to obj, whether they belong to the class of obj or one of its superclasses.
If obj is a class, this returns the class methods.
Returns nil if obj is nil .


GSObjCSetValue

void GSObjCSetValue(NSObject* self, NSString* key, id val, SEL sel, const char* type, unsigned int size, int offset);

This is used internally by the key-value coding methods, to set a value in an object either via an accessor method (if sel is supplied), or via direct access (if type, size, and offset are supplied).
Automatic conversion between NSNumber and C scalar types is performed.
If type is null and can't be determined from the selector, the [NSObject -handleTakeValue:forUnboundKey:] method is called to try to set a value.


GSObjCSetVariable

void GSObjCSetVariable(id obj, int offset, unsigned int size, const void* data);

Sets the value in an instance variable in obj
This function performs no checking... you should use it only where you are providing information from a call to GSObjCFindVariable() and you know that the data area provided is the correct size.


GSObjCVariableNames

NSArray* GSObjCVariableNames(id obj);

This method returns an array listing the names of all the instance variables present in the instance obj, whether they belong to the class of obj or one of its superclasses.
Returns nil if obj is nil.


GSObjCZone

NSZone* GSObjCZone(NSObject* obj);

Return the zone in which an object belongs, without using the zone method


GSPrintf

BOOL GSPrintf(FILE* fptr, NSString* format,...);

Prints a message to fptr using the format string provided and any additional arguments. The format string is interpreted as by the NSString formatted initialisers, and understands the '%@' syntax for printing an object.

The data is written to the file pointer in the default CString encoding if possible, as a UTF8 string otherwise.

This function is recommended for printing general log messages. For debug messages use NSDebugLog() and friends. For error logging use NSLog() , and for warnings you might consider NSWarnLog() .


GSSetValue

void GSSetValue(NSObject* self, NSString* key, id val, SEL sel, const char* type, unsigned int size, int offset);

Deprecated... use GSObjCSetValue()


GSSetVariable

void GSSetVariable(id obj, int offset, unsigned int size, const void* data);

Deprecated... use GSObjCSetVariable()


behavior functions

behavior_class_add_category

void behavior_class_add_category(Class class, struct objc_category* category);

Description forthcoming.


behavior_class_add_class

void behavior_class_add_class(Class class, Class behavior);

Description forthcoming.


behavior_class_add_methods

void behavior_class_add_methods(Class class, struct objc_method_list* methods);

Description forthcoming.


behavior_set_debug

void behavior_set_debug(int i);

Description forthcoming.


Unicode functions

GSEncodingForRegistry

NSStringEncoding GSEncodingForRegistry(NSString* registry, NSString* encoding);

Returns the NSStringEncoding that matches the specified character set registry and encoding information. For instance, for the iso8859-5 character set, the registry is iso8859 and the encoding is 5, and the returned NSStringEncoding is NSISOCyrillicStringEncoding. If there is no specific encoding, use @"0". Returns GSUndefinedEncoding if there is no match.


GSEncodingFromLocale

NSStringEncoding GSEncodingFromLocale(const char* clocale);

Try to deduce the string encoding from the locale string clocale. This function looks in the Locale.encodings file installed as part of GNUstep Base if the encoding cannot be deduced from the clocale string itself. If clocale isn't set or no match can be found, returns GSUndefinedEncoding.


GSEncodingName

NSString* GSEncodingName(NSStringEncoding encoding);

Description forthcoming.


GSFromUnicode

BOOL GSFromUnicode(unsigned char** dst, unsigned int* size, const unichar* src, unsigned int slen, NSStringEncoding enc, NSZone* zone, unsigned int options);

Function to convert from 16-bit unicode to 8-bit data.

The dst argument is a pointer to a pointer to a buffer in which the converted data is to be stored. If it is a null pointer, this function discards converted data, and is used only to determine the length of the converted data. If the zone argument is non-nul, the function is free to allocate a larger buffer if necessary, and store this new buffer in the dst argument. It will *NOT* deallocate the original buffer!

The size argument is a pointer to the initial size of the destination buffer. If the function changes the buffer size, this value will be altered to the new size. This is measured in bytes.

The src argument is a pointer to the 16-bit unicode string which is to be converted to 8-bit data.

The slen argument is the length of the 16-bit unicode string which is to be converted to 8-bit data. This is measured in 16-bit characters, not bytes.

The enc argument specifies the encoding type of the 8-bit byte sequence which is to be produced from the 16-bit unicode.

The zone argument specifies a memory zone in which the function may allocate a buffer to return data in. If this is nul, the function will fail if the originally supplied buffer is not big enough (unless dst is a null pointer... indicating that converted data is to be discarded).

The options argument controls some special behavior.

On return, the function result is a flag indicating success (YES) or failure ( NO), and on success, the value stored in size is the number of bytes in the converted data. The converted data itself is stored in the location given by dst.
NB. If the value stored in dst has been changed, it is a pointer to allocated memory which the caller is responsible for freeing, and the caller is still responsible for freeing the original buffer.


GSToUnicode

BOOL GSToUnicode(unichar** dst, unsigned int* size, const unsigned char* src, unsigned int slen, NSStringEncoding enc, NSZone* zone, unsigned int options);

Function to convert from 8-bit data to 16-bit unicode characters.

The dst argument is a pointer to a pointer to a buffer in which the converted string is to be stored. If it is a null pointer, this function discards converted data, and is used only to determine the length of the converted string. If the zone argument is non-nul, the function is free to allocate a larger buffer if necessary, and store this new buffer in the dst argument. It will *NOT* deallocate the original buffer!

The size argument is a pointer to the initial size of the destination buffer. If the function changes the buffer size, this value will be altered to the new size. This is measured in 16-bit unicode characters, not bytes.

The src argument is a pointer to the byte sequence which is to be converted to 16-bit unicode.

The slen argument is the length of the byte sequence which is to be converted to 16-bit unicode. This is measured in bytes.

The enc argument specifies the encoding type of the 8-bit byte sequence which is to be converted to 16-bit unicode.

The zone argument specifies a memory zone in which the function may allocate a buffer to return data in. If this is nul, the function will fail if the originally supplied buffer is not big enough (unless dst is a null pointer... indicating that converted data is to be discarded).

The options argument controls some special behavior.

On return, the function result is a flag indicating success (YES) or failure ( NO), and on success, the value stored in size is the number of characters in the converted string. The converted string itsself is stored in the location given by dst.
NB. If the value stored in dst has been changed, it is a pointer to allocated memory which the caller is responsible for freeing, and the caller is still responsible for freeing the original buffer.


GetAvailableEncodings

NSStringEncoding* GetAvailableEncodings();

Returns a nul terminated array of the available string encodings.


GetDefEncoding

NSStringEncoding GetDefEncoding();

Return the default encoding


GetEncodingName

NSString* GetEncodingName(NSStringEncoding encoding);

Description forthcoming.


chartouni

unichar chartouni(unsigned char c);

deprecated See GSToUnicode() and GSFromUnicode()


encode_chartouni

unichar encode_chartouni(unsigned char c, NSStringEncoding enc);

deprecated See GSToUnicode() and GSFromUnicode()


encode_cstrtoustr

int encode_cstrtoustr(unichar* dst, int dl, const char* src, int sl, NSStringEncoding enc);

deprecated See GSToUnicode() and GSFromUnicode()


encode_unitochar

unsigned char encode_unitochar(unichar u, NSStringEncoding enc);

deprecated See GSToUnicode() and GSFromUnicode()


encode_unitochar_strict

unsigned int encode_unitochar_strict(unichar u, NSStringEncoding enc);

deprecated See GSToUnicode() and GSFromUnicode()


encode_ustrtocstr

int encode_ustrtocstr(char* dst, int dl, const unichar* src, int sl, NSStringEncoding enc, BOOL strict);

deprecated See GSToUnicode() and GSFromUnicode()


uni_cop

unsigned char uni_cop(unichar u);

Description forthcoming.


uni_is_decomp

unichar* uni_is_decomp(unichar u);

Description forthcoming.


uni_isnonsp

BOOL uni_isnonsp(unichar u);

Description forthcoming.


uni_tolower

unichar uni_tolower(unichar ch);

Uses direct access into a two-level table to map cases.
The two-level table method is less space efficient (but still not bad) than a single table and a linear search, but it reduces the number of conditional statements to just one.


uni_toupper

unichar uni_toupper(unichar ch);

Uses direct access into a two-level table to map cases.
The two-level table method is less space efficient (but still not bad) than a single table and a linear search, but it reduces the number of conditional statements to just one.


unitochar

unsigned char unitochar(unichar u);

deprecated See GSToUnicode() and GSFromUnicode()


GSObjCRuntime macros

GS_MAX_OBJECTS_FROM_STACK

GS_MAX_OBJECTS_FROM_STACK

The number of objects to try to get from varargs into an array on the stack... if there are more than this, use the heap. NB. This MUST be a multiple of 2


GS_USEIDLIST

GS_USEIDLIST(firstObject, code,...)

This is a macro designed to minimise the use of memory allocation and deallocation when you need to work with a vararg list of objects.
The objects are unpacked from the vararg list into a 'C' array and then a code fragment you specify is able to make use of them before that 'C' array is destroyed.

The firstObject argument is the name of the formal parameter in your method or function which precedes the ',...' denoting variable args.

The code argument is a piece of objective-c code to be executed to make use of the objects stored in the 'C' array.
When this code is called the unsigned integer '__count' will contain the number of objects unpacked, and the pointer '__objects' will point to the unpacked objects, ie. firstObject followed by the vararg arguments up to (but not including) the first nil.


GS_USEIDPAIRLIST

GS_USEIDPAIRLIST(firstObject, code,...)

This is a macro designed to minimise the use of memory allocation and deallocation when you need to work with a vararg list of objects.
The objects are unpacked from the vararg list into two 'C' arrays and then a code fragment you specify is able to make use of them before that 'C' array is destroyed.

The firstObject argument is the name of the formal parameter in your method or function which precedes the ',...' denoting variable args.

The code argument is a piece of objective-c code to be executed to make use of the objects stored in the 'C' arrays.
When this code is called the unsigned integer '__count' will contain the number of objects unpacked, the pointer '__objects' will point to the first object in each pair, and the pointer '__pairs' will point to an array containing the second halves of the pairs of objects whose first halves are in '__objects'.
This lets you pack a list of the form 'key, value, key, value,...' into an array of keys and an array of values.



Up