Posts

Showing posts with the label okhttp3 android

OkHttp 3 Example in Android

Image
Building Simple app using OkHttp Networking Library to get the users data from https://randomuser.me/ API. RecyclerView to show the users data in List, Square Picasso for image Loading. DiagonalLayout for showing image in diagonal shape. Step: 1 ====== Add all Libraries to build.gradle file like below compile ' com . android . support : appcompat - v7: 25.0 . 1 ' compile ' com . squareup . okhttp3 : okhttp: 3.5 . 0 ' compile ' com . squareup . picasso : picasso: 2.5 . 2 ' compile ' com . android . support : recyclerview - v7: 25.0 . 1 ' compile ' com . android . support : cardview - v7: 25.0 . 1 ' compile ' com . android . support : design: 25.0 . 1 ' compile ' com . github . florent37 : diagonallayout: 1.0 . 2 ' compile ' de . hdodenhof : circleimageview: 2.1 . 0 ' Step: 2 ====== Create a model class package com . pratap . okhttpexample . models ; import jav