Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- package com.hakiki95.appbiodata.api;
- import retrofit2.Retrofit;
- import retrofit2.converter.gson.GsonConverterFactory;
- /**
- * Created by hakiki95 on 4/16/2017.
- */
- public class Retroserver {
- private static final String base_url = "http://192.168.2.5/CrudPHPApi/";
- private static Retrofit retrofit;
- public static Retrofit getClient()
- {
- if(retrofit == null)
- {
- retrofit = new Retrofit.Builder()
- .baseUrl(base_url)
- .addConverterFactory(GsonConverterFactory.create())
- .build();
- }
- return retrofit;
- }
- }
Add Comment
Please, Sign In to add comment