Archives for Android - Page 14

Android

Learn to create screen wireframes for Android Lollipop with Pencil

Prototype GUI is always an important part of an Android project. It lets to have a better idea about rendering of an application. Among available tools, Pencil is a great solution. Pencil is an open source prototyping GUI solution based on XUL Runner and so multiplatform ! Source code can be found on Github here : At this stage, you…
Continue Reading
Android

Create a real time line graph in Android with AChartEngine

AChartEngine is one of the oldest library available to create graph on Android. Solution is functional but lacks of some fresh in front of new libraries that implement Material Design specifications. However, it’s interesting to study it to learn how to create real time line graph with it. First, we need to get AChartEngine. It can be downloaded as a…
Continue Reading
Android

Create a real time line graph in Android with GraphView

In Android applications, there are a lot of use cases in which you must create graphs. Fortunately, a lot of open source libraries exist letting you to easily create line graphs, bar graphs or other style of graphs. These libraries have the main advantages to be designed entirely for Android and so, they are optimized. Among the main libraries, we're…
Continue Reading
Android

Schedule tasks on Android Lollipop with JobScheduler API

Before Android Lollipop , there was just one solution to schedule tasks on Android. You must use the AlarmManager system service acquired thanks to the following method call : (AlarmManager) getSystemService(); The AlarmManager was functional but had some major disadvantages. First, it doesn’t consider if the device is connected to a power plug, idle or connected to a unmetered network.…
Continue Reading
Android

How to use Cryptography in Android applications ?

When you made an Android applications, you must very often store data in file to persist applications state or games state. For example, you can store some data of a game that lets users to restart game to the same state. Major concern comes from advanced that would change these data to cheat in your game ! To avoid this…
Continue Reading
Android

Backup and Restore data from the Cloud thanks to Android Backup API

When Android’s user installs your app on a particular device and start to use it, you can store some data letting him to use easily the application. You can also store high score or other data for a game. If user must make a restore of his system or if user changes his device, it’s great to let him to…
Continue Reading
Android

Getting started with Google Maps Android API V2 – Part 1

Google Maps provides to Android developers a powerful API to display maps in applications. Google Maps API V2 is now part of Google Play Services. 1. Get Google Play Services First, you need to get Google Play Services to use in your Android application. If you use Android Studio, you must simply add the following dependency to your Gradle build…
Continue Reading
Android

How to get user current location with GPS or Network in Android?

Thanks to smartphones, modern mobile applications can benefit from GPS installed to get user current location. This information adds a lot of value to an application. Web’s giants have understood this since long time. So, in your next application, you could use GPS or Network to get user current location and add value to your application. For example, if you…
Continue Reading
Android

How to check if internet connection is enabled in Android ?

Today, a simple article exposing a snippet code lets you to know if user’s internet connection is enabled in Android. It can be very important to know if user is connected before to send internet requests that are useless. First, you must add following permissions to your Android Manifest : <uses-permission android:name="; /> <uses-permission android:name="; /> I presume that you…
Continue Reading
Android

Learn how to parse JSON in Android with Gson

Previously you had learnt to consume a REST Web Service in JSON and parse result to display data in an Android application. To start from basics, I show you raw method that uses only standard SDK and no third-party libraries. I think it's better when you begin to understand how things work. Now, you know raw method so we can…
Continue Reading