Function CFDictionaryAddValue

Source
pub unsafe extern "C-unwind" fn CFDictionaryAddValue(
    the_dict: Option<&CFMutableDictionary>,
    key: *const c_void,
    value: *const c_void,
)
Available on crate feature CFDictionary only.
Expand description

Adds the key-value pair to the dictionary if no such key already exists.

Parameter theDict: The dictionary to which the value is to be added. If this parameter is not a valid mutable CFDictionary, the behavior is undefined.

Parameter key: The key of the value to add to the dictionary. The key is retained by the dictionary using the retain callback provided when the dictionary was created. If the key is not of the sort expected by the retain callback, the behavior is undefined. If a key which matches this key is already present in the dictionary, this function does nothing (“add if absent”).

Parameter value: The value to add to the dictionary. The value is retained by the dictionary using the retain callback provided when the dictionary was created. If the value is not of the sort expected by the retain callback, the behavior is undefined.