Is it possible to create a CLHeading object in Objective C?
Since Objective-C is a dynamically typed language, you can create your own class (for example,MyFakeHeading
) and as long as it responds to all of the same selectors that CLHeading
does, you can simply cast it as a CLHeading
and pass it as a parameter instead. And, since you only need to fake out your own code, you don't even need to implement all the functionality of CLHeading
, just the parts your are using.