CFSetCreateMutableCopy(_:_:_:)
Creates a new mutable set with the values from another set.
Declaration
func CFSetCreateMutableCopy(_ allocator: CFAllocator!, _ capacity: CFIndex, _ theSet: CFSet!) -> CFMutableSet!Parameters
- allocator:
The allocator to use to allocate memory for the new set and its storage for values. Pass
NULLor Kcfallocatordefault to use the current default allocator. - capacity:
The maximum number of values that can be contained by the new set. The set starts with the same number of values as
theSetand can grow to this number of values (and it can have less).Pass
0to specify that the maximum capacity is not limited. If non-0,capacitymust be greater than or equal to the count oftheSet. - theSet:
The set to copy. The pointer values from
theSetare copied into the new set. The values are also retained by the new set. The count of the new set is the same as the count oftheSet. The new set uses the same callbacks astheSet.
Return Value
A new mutable set that contains the same values as theSet. Ownership follows the The Create Rule.