Determining what a CFTypeRef is?

Kristina Brooks picture Kristina Brooks · Aug 12, 2010 · Viewed 9.2k times · Source

I have a function which returns CFTypeRef. I have no idea what it really is. How do I determine that? For example it might be a CFStringRef.

Answer

Dave DeLong picture Dave DeLong · Aug 12, 2010

CFGetTypeID():

if (CFGetTypeID(myObjectRef) == CFStringGetTypeID()) {
  //i haz a string
}