I'm in the early stages of an iPhone app and I have a question. I did some searching but did not find what I was looking for.
There are features in iPhone OS4 that I would like to take advantage of, but I would like for my app to also run on 3.X.
It looks like I want to develop against the 4.0 SDK and do the following:
respondsToSelector:
for any
new method in an existing framework
or any method in a new framework
before making that callAm I close? What's recommended?
Pointers to similar questions welcome.
UPDATE:
Just as a note - if you are trying to check for a new framework, you're best chance is to call respondsToSelector:
on a class method against the class object instead of using an instance method.
Backward compatibility property allows the app to use the interface of its older version. If the developers have used several tools for both backward and forward compatibility of your iOS app, it will fail to work with the new iOS 13. For that reason, and the app update is essential.
Yes, that's exactly how you do it!
The only other trick I can think of that you have not already mentioned is that you build against the latest SDK (i.e., 4.0 in this case) and set the target to be the earliest you want to support (3.0 in this case).
You might like to try using the 3.2 SDK to create a universal (iPhone/iPad) app. This is an Apple template that uses this same method to work with two different APIs.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With