Dig Deeper into Service, Async Task & Thread

What is the difference between Service, Async Task & Thread? Service A Service is an application component that can perform long-running operations in the background and does not provide a user interface. Services can run the even if the activity that triggers it, is no longer active. When to use? For the task which does […]

Continue reading

Glide vs. Picasso

While comparing the sizes of the .jar file of both the libraries, Glide is almost 3.5 times larger than Picasso in size.   both libraries have almost same syntax if you want to simply load the image from the URL and display them into the image view.   One thing in which Glide dominates is, […]

Continue reading

Comparison of Android networking libraries

According to various benchmarks on various parameter Retrofit is prefered over Volley     https://stackoverflow.com/questions/16902716/comparison-of-android-networking-libraries-okhttp-retrofit-and-volley https://stackoverflow.com/questions/42106170/android-volley-vs-retrofit-which-is-better-and-why?noredirect=1&lq=1 https://medium.com/@mohitkumar0571/fast-android-networking-vs-retrofit-vs-volley-32ca4a0e4030 http://instructure.github.io/blog/2013/12/09/volley-vs-retrofit/ https://stackoverflow.com/questions/25346813/google-volley-vs-android-async-http https://medium.com/@sotti/android-networking-ii-okhttp-retrofit-moshi-and-picasso-c381f6c0efd8 https://stackoverflow.com/questions/25739620/why-should-i-use-okhttp-instead-of-android-httpclient-and-asynctask http://instructure.github.io/blog/2013/12/09/volley-vs-retrofit/ https://github.com/amitshekhariitbhu/Fast-Android-Networking https://stackoverflow.com/questions/25739620/why-should-i-use-okhttp-instead-of-android-httpclient-and-asynctask

Continue reading

Volley in Android

Volley is a networking library was introduced to make networking calls much easier, faster without writing tons of code. Volley is now officially supported by Google. By default all the volley network calls works asynchronously, so we don’t have to worry about using asyncTask anymore. Volley provides a lot of features few of them are:- […]

Continue reading

OkHTTP

Android initially provide two HTTP clients Apache HTTP Client and HttpURLConnection for receiving and sending data. DrawBack of Apache HTTP Client and HttpURLConnection Each of these clients required a lot of boilerplate code as it has to place inside the AsyncTask or Background Threads. It becomes very complicated for cancelling an HTTP request or connection […]

Continue reading

Architectural Design in android

Why Architectural Design like MVC/MVP ? MVC/MVP aims to decouple components as much as possible: As proper MVP and MVC implementations have the following characteristics: Readable and maintainable code Modular code which provides high degree of decoupling More testable code Code which is fun to work with   We various type of Variation in these  […]

Continue reading

Apache HttpClient

Apache HttpClient The Apache HttpClient library allows us to make HTTP requests. Add HttpClient Library to your project

For latest Version:-  https://mvnrepository.com/artifact/org.apache.httpcomponents/httpclient Creating HTTP Client and HTTP Post

Building Post Parameters:- The following code will create post parameters pair with key and value.

URL Encoding POST data:-Before making HTTP request you need […]

Continue reading

Common API in Android

Networking Libraries Retrofit by Square Volley by Google OkHTTP by Square HttpURLConnection HttpClient Comparison of Android networking libraries Image loading library Picasso Glide Picasso vs Glide   Push Notifications Firebase Google Cloud Messaging   Dependency Injection Butter Knife   JSON Reader Android provide inbuild JSON reader, but it is easier to use These Third part API. […]

Continue reading

Kotlin

Kotlin Kotlin is an open source, statically typed language based on Java Virtual Machine (JVM), with 100% interoperable with Java. Note:- You can also compile it to JavaScript or Native for building code that can run on iOS. Interoperable with Java, i.e. You can have Java and Kotlin code existing side by side in the […]

Continue reading

Android Sensor

The Android classifies sensors in three categories:- Motion Sensors:- These are used to measure acceleration forces and rotational forces along with three axes. Environmental sensors:– These are used to measure the environmental changes such as temperature, humidity etc. Position sensors:-These are used to measure the physical position of a device. Android Sensor API Some important […]

Continue reading

Android ProGuard

ProGuard is a free Java class file shrinker, optimizer, obfuscator, and preverifier. It detects and removes unused classes, fields, methods, and attributes. It optimizes bytecode and removes unused instructions. It renames the remaining classes, fields, and methods using short meaningless names. The resulting applications and libraries are smaller, faster, and a bit better hardened against […]

Continue reading

Android Lint

The Android lint tool is a static code analysis tool that checks your Android project source files for potential bugs and optimization improvements for correctness, security, performance, usability, accessibility, and internationalization. Here are some examples of the types of errors that it looks for: Missing translations (and unused translations) Layout performance problems (all the issues […]

Continue reading

ListView

ListView ListView is a view which displays a list of scrollable items. The list items are automatically inserted to the list using an adapter. A lot of information can be displayed As users reach the end, more results are generated and displayed Each row of data is clickable and can perform some action. Adapter An […]

Continue reading

EveryThing About Android’s Runtime Permission

Runtime Permission introduced in android version M. It is one of the major security fixes for Android. Prior to Android Marshmallow, all permissions are asked at installation time, and once the app is installed, it can use all these permissions with any acknowledgement to users. The user is left with the option either to install […]

Continue reading

Basic UI elements

TextView:- It is used to display text. EditView:- It enables one to edit. Button:- It is used to perform the certain task when clicked. ImageView:- To display an image. ImageButton:- This is a button with an image instead by the text. AutoCompleteTextView:- Same as editView plus it shows a list of completion suggestions automatically while […]

Continue reading

Interview Questions Basic Level-3

What is runtime permission? Refer What is Localization in Android? It is the process of rendering the content of an app into other languages and customizing your app for different targets, regions etc. How to localize the App? If we need to support three languages, we have to create three alternatives of strings.xml, each stored […]

Continue reading

Annotation

Annotation means “a note by way of explanation or comments added to a text or diagram”. Annotation is Metadata, which conveys some additional information to the compiler. Annotation in Java start with @ Example:- @Override It indicates that you are overriding a method. It assures that the subclass method is overriding the parent class method. […]

Continue reading