CFMutableBag manages dynamic bags. The basic interface for managing bags is provided by CFBag. CFMutableBag adds functions to modify the contents of a bag.

You create a mutable bag object using either the CFBagCreateMutable(_:_:_:) or CFBagCreateMutableCopy(_:_:_:) function.

CFMutableBag provides several functions for adding and removing values from a bag. The CFBagAddValue(_:_:) function adds a value to a bag and CFBagRemoveValue(_:_:) removes values from a bag.


Creating a Mutable Bag

func CFBagCreateMutableCopy(CFAllocator!, CFIndex, CFBag!)

Creates a new mutable bag with the values from another bag.

Modifying a Mutable Bag

Data Types


A reference to a mutable bag object.