Become a fan of Slashdot on Facebook

 



Forgot your password?
typodupeerror

Comment Re:Maybe not a crisis (Score 1) 636

It is actually a little harder than this, since JAVA is statically compiled. You can't have a class referenced in code if it's not available in the JVM, even if that code branch is never executed. So this will not work: if (ANDROID_2_1) { BluetoothManager.doSomething(); } There are a few good tutorials for handling this, while avoiding reflection. They take advantage of JAVA's lazy loading of static classes. The official Android blog has a post here: http://android-developers.blogspot.com/2009/04/backward-compatibility-for-android.html and here is a great, detailed tutorial: http://devtcg.blogspot.com/2009/12/gracefully-supporting-multiple-android.html With that said, sdk 2.1 isn't terribly different than sdk 1.6, really. You can write most apps using 1.6, and should for now. Code modifications go through a lengthy deprecation period before being considered for removal. Should Google really feature-freeze a platform because a single phone got released?

Slashdot Top Deals

"The whole problem with the world is that fools and fanatics are always so certain of themselves, but wiser people so full of doubts." -- Bertrand Russell

Working...