Skip to main content

Posts

Android VS Other Mobile Operating Systems - ABNHive

iOS iOS, an operating system from Apple, was originally developed for the iPhone. Later it was extended to support iPod Touch, iPad and Apple TV. Apple’s App Store contains more than 500,000 applications and boasts more than 25 billion downloads collectively. It holds the reputation of intelligent UI creator which is based on the concept of direct manipulation, using multi-touch gestures. Android Android is a Linux based mobile operating system developed by the Open Handset Alliance led by Google. Android boasts large community of developers writing applications extending the functionality of the devices. It has 450,000 apps in its Android Market and download exceeds 10 billion count. BlackBerry OS BlackBerry OS is developed by Research In Motion (RIM) for its line of smartphones. This operating system is known for its native support for corporate e-mail through MIDP allowing complete wireless activation and synchronization with Microsoft Exchange and Lotus Do...

Broadcast receivers in Android - ABNHive

It responds to system-wide broadcast announcements. It used to display a persistent icon in the status bar of the device, vibrate, play a sound, flashlights, etc. to indicate to the user that something significant has happened in the background. System Generated Events The following table lists a few important system events. android.intent.action.BATTERY_CHANGED - Sticky broadcast containing the charging state, level, and other information about the battery. android.intent.action.BATTERY_LOW - Indicates low battery condition on the device. android.intent.action.BATTERY_OKAY - Indicates the battery is now okay after being low. android.intent.action.DATE_CHANGED - The date has changed. android.intent.action.REBOOT - Have the device reboot. android.intent.action.BOOT_COMPLETED  - This is broadcast once after the system has finished booting. android.intent.action.BUG_REPORT  - Show activity for reporting a bug. android.intent.action.CALL  - Perform a...

Services in Android - ABNHive

A service is a component which runs in the background without direct interaction with the user.  A service extends the base class Service . Services run with a higher priority than inactive or invisible activities and therefore it is less likely that the Android system terminates them for resource management. The only reason Android will stop a Service prematurely is to provide additional resources for a foreground component usually an Activity. When this happens, your Service can be configured to restart automatically. You can start a service if it is not running using Context.startService(), connect (bind) to a running service using Context.bindService(), and communicate with the running service through an interface that the service exposes. Each service class must have a corresponding <service> declaration in the AndroidManifest.xml file for its package. Types of Services Bound Service Service which call indefinitely in between activity. An Android component m...

Essential Guide to Setting up Emulators- ABNHive

An Android emulator is an Android Virtual Device (AVD) that represents a specific Android device. You can use an Android emulator as a platform to run and test your applications on your PC. Installing Emulator on PC Steps are given below Open SDK Manager from Android Studio, click Tools > SDK Manager. Click SDK Tools section Click to tick Android Emulator and Intel x86 Emulator Accelerator - HAXM Installer (If available) Click OK Button Wait to complete download It will automatically download Android Emulator Creating AVD After downloading the Emulator we need to Create AVD (Android Virtual Device).  Click  Tools > AVD Manager. Click Create New Virtual Device Icon Now choose device  If a download option is there, just click to download Device Image Configure Device Now Android Studio creates AVD Click the green icon to run Emulator - Aswin Bhim Nath

Activities in Android - ABNHive

An activity represents a single screen with a user interface. For example, a simple activity might present a set of choice buttons. Activities work together to form user experience in the app. For example, clicking a button on the first screen might replace that screen with another screen containing other widgets, a web page, a movie, or text information. Activities are typically created by extending the Android class Activity. Activity class automatically takes care of creating a window for you in which you can place your user interface (UI) with the method setContentView(View).  Methods in Activity Class. Every Activity has Methods which we can override.  onCreate(Bundle) initializes the activity. Two of the most important methods at your disposal here are setContentView(View) with a layout resource defining your UI, and findViewById(int), to retrieve the widgets in that UI that you need to interact with programmatically. onPause() is where you...

Android Application Components Activities, Services, Broadcast Recievers, Content Providers - ABNHive

Application components are the essential building blocks of Android app development.  Each component is an entry point through which the system or a user can enter your app. There are 4 types of components in android Activities Services Broadcast receivers Content providers Let's dive into the deep.  Activities This is a component that represents a single screen with a user interface or simply an entry point for interacting with the user. Example, an email app might have one activity that shows a list of new emails. Activities work together to form a cohesive user experience in the app. For example, clicking a button on the first screen might replace that screen with another screen containing other widgets, a web page, a movie, or text information. Activities are typically created by subclassing (extending) the Android class Activity.  click here   to know more about Activity. Services This runs in the background ...

Begin to code the First android app - ABNHive

We discussed android a lot in previous articles. Now let's begin to code. Before that, we need to know about Android Studio. Android Studio is the official Integrated Development Environment (IDE). Before reading this you should read this  portion. Why we need the Android studio A flexible Gradle-based build system A fast and feature-rich emulator A unified environment where you can develop for all Android devices Instant Run to push changes to your running app without building a new APK Code templates and GitHub integration to help you build common app features and import sample code Extensive testing tools and frameworks Lint tools to catch the performance, usability, version compatibility, and other problems C++ and NDK support Built-in support for Google Cloud Platform, making it easy to integrate Google Cloud Messaging and App Engine Now Download Android Studio and other tools. I mentioned about tools in  here . Let's create a HelloWorld Applica...