objective c - How does CFBridgingRelease act on objects retained in a Core Foundation container? -
i'm creating cfmutablearray
, populating dynamically cfstring
s.
if i'm bridging
cfmutablearray
onnsmutablearray
usingcfbridgingrelease
, happens children?when access entries in array afterwards, can treat them arc-managed
nsstring
s or should fancy incfarraycallbacks
struct handle transfer automatically?
if i'm bridging cfmutablearray on nsmutablearray using cfbridgingrelease, happens children?
likely, nothing. of course, depends on you've put cfarray you're casting. if have put c-types aren't toll-free bridged objective-c types (some parts of corefoundation still not bridged yet), behavior of resulting ns-type undefined.
when access entries in array afterwards, can treat them arc-managed nsstrings or should fancy in cfarraycallbacks struct handle transfer automatically?
you shouldn't need if you're dealing bridged types in bridged array. values contained within array have been retained (so should not sent anymore -retain
's array), , should fine pull out , use.
Comments
Post a Comment