Contents

NSMapInsertKnownAbsent(_:_:_:)

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

Declaration

func NSMapInsertKnownAbsent(_ table: NSMapTable<AnyObject, AnyObject>, _ key: UnsafeRawPointer?, _ value: UnsafeRawPointer?)

Discussion

Inserts key (which must not be notAKeyMarker) and value into table. Unlike NSMapInsert, this function raises NSInvalidArgumentException if table already includes a key that matches key.

key is compared with notAKeyMarker using pointer comparison; if key is identical to notAKeyMarker, raises NSInvalidArgumentException.

See Also

Related Documentation

Functions