CFRetain

Header: CFBase.h Carbon status: Supported

Retains a Core Foundation object.

CFTypeRef CFRetain (
    CFTypeRef cf
);
Parameter descriptions
cf

A generic reference of type CFTypeRef Pass a reference to a Core Foundation object that you want to retain.

function result

A generic reference of type CFTypeRef to a Core Foundation object. This is always the same reference as the parameter.

DISCUSSION

Retains a Core Foundation object by incrementing its retention count. You should retain a Core Foundation object when you receive it from elsewhere (that is, you did not create or copy it) and you want it to persist. If you retain a Core Foundation object you are responsible for releasing it (see the CFRelease function).

AVAILABILITY

Supported in Carbon. Available in Carbon 1.0.2 and later.


© 2000 Apple Computer, Inc. (Last Updated 6/30/2000)