Legacy Map Table Implementation

No overview available.

Topics

Functions

func NSAllMapTableKeys(NSMapTable<AnyObject, AnyObject>) -> [Any]

Returns all of the keys in the specified map table.

func NSAllMapTableValues(NSMapTable<AnyObject, AnyObject>) -> [Any]

Returns all of the values in the specified table.

func NSCountMapTable(NSMapTable<AnyObject, AnyObject>) -> Int

Returns the number of elements in a map table.

func NSMapInsertKnownAbsent(NSMapTable<AnyObject, AnyObject>, UnsafeRawPointer?, UnsafeRawPointer?)

Inserts a key-value pair into the specified table if the pair had not been previously added.

func NSMapRemove(NSMapTable<AnyObject, AnyObject>, UnsafeRawPointer?)

Removes a key and corresponding value from the specified table.

func NSResetMapTable(NSMapTable<AnyObject, AnyObject>)

Deletes the elements of the specified map table.

func NSStringFromMapTable(NSMapTable<AnyObject, AnyObject>) -> String

Returns a string describing the map table’s contents.

Data Types

struct NSMapEnumerator

Allows successive elements of a map table to be returned each time this structure is passed to NSNextMapEnumeratorPair(_:_:_:).

struct NSMapTableKeyCallBacks

The function pointers used to configure behavior of NSMapTable with respect to key elements within a map table.

typealias NSMapTableOptions

Constants used as components in a bitfield to specify the behavior of elements (keys and values) in an NSMapTable object.

struct NSMapTableValueCallBacks

The function pointers used to configure behavior of NSMapTable with respect to value elements within a map table.

Constants

let NSIntegerMapKeyCallBacks: NSMapTableKeyCallBacks

For keys that are pointer-sized quantities or smaller (for example, int, long, or unichar).

let NSIntMapKeyCallBacks: NSMapTableKeyCallBacks

For keys that are pointer-sized quantities or smaller (for example, int, long, or unichar).

Deprecated
let NSNonOwnedPointerOrNullMapKeyCallBacks: NSMapTableKeyCallBacks

For keys that are pointers not freed, or NULL.

let NSNonRetainedObjectMapKeyCallBacks: NSMapTableKeyCallBacks

For sets of objects, but without retaining/releasing.

let NSOwnedPointerMapKeyCallBacks: NSMapTableKeyCallBacks

For keys that are pointers, with transfer of ownership upon insertion.

Constants

let NSIntegerMapValueCallBacks: NSMapTableValueCallBacks

For values that are pointer-sized quantities, (for example, int, long, or unichar).

let NSIntMapValueCallBacks: NSMapTableValueCallBacks

For values that are pointer-sized quantities, (for example, int, long, or unichar).

Deprecated
let NSNonRetainedObjectMapValueCallBacks: NSMapTableValueCallBacks

For sets of objects, but without retaining/releasing.