Posts

Showing posts with the label coding convention

New Admob for Android: Switching from Admob SDK to Google Play Services API

Image
Google announced on the 11th of February 2014 that they were deprecating the standalone Admob Android SDK. They will stop accepting apps using the old SDK on the 1st of August 2014. Ads will keep serving, but eventually you will have to switch over. Also, legacy AdMob will be shutting down on 31st of August 2014, you have to upgrade to new AdMob following this guide . I updated and found out that there are some points that you should notice. Know your new AdMob Ad Unit ID Apps you previously monetized in legacy AdMob used legacy Publisher IDs (which represented a string of 15 hexadecimal characters starting with the letter “a”, such as a143534390190de ) to identify the ad units and legacy Mediation IDs (which represented a string of 16 character hexadecimal characters such as e124250129089251 ) for mediation. New AdMob uses ad unit IDs to identify unique ad units in your apps, serve ads to those ad units, and manage AdMob Mediation if it's enabled. Ad unit ID has a ...

Coding convention for Android developer

Image
Hey, If you are new in Android and wondering if there is any Android Coding Standard document available, this post is for you. Check Android Code Style Guidelines for Contributors . I found the link on stackoverflow, LOL This link contains a good description of code style rules. If you are using eclipse IDE and you want to enforce this rules without remembering all of them, then you can use formatting rules provided by Android team: android-formatting.xml. Download it here You can import the file to make Eclipse follow the Android style rules. Steps are: Select Window > Preferences > Java > Code Style. Use Formatter > Import to import android-formatting.xml. Organize Imports > Import to import android.importorder. Figure 1 - Sample of code formatter preview From now on, after coding a bunch of codes, press Ctrl + Shift + F to automatically format your code. Code fun.