Question

I want to make my App backward compatbible to API level 8 (Android 2.2).

My problem is, that Android Beam requires API level 14 (Android 4.0).

Is it possible to implements this function without creating two apks?

public class Beam extends Activity implements CreateNdefMessageCallback,OnNdefPushCompleteCallback {
    ...
}
Was it helpful?

Solution

As long as the code that uses this function is not run on a device that does not support it, you will not have an issue.

Just check the current SDK level and hide the function from the user if the device does not support it.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top