Questions tagged as 'retrofit'

1
answer

Treating associative JSON in PHP

I have a Java application: Gson gson = new Gson(); String json = gson.toJson(pedido); DataServiceGenerator dataServiceGenerator = new DataServiceGenerator(); Webservice service = dataServiceGenerator.createService(Webservice.c...
asked by 05.07.2018 / 01:59
0
answers

How to return the searched content to another class via Retrofit

I have a problem that is as follows, I have a service class (DataService) that brings the api data using Retrofit2. So far so good, but when the data is returned I can access the body of the response through response.body () in the anonymous met...
asked by 28.05.2018 / 21:27
1
answer

pass parameters on a request in the retrofit

I'm studying retrofit and I came across the following problem: I'm performing a get request on the url link But when I mount the request I can not add the posts / 1 parameter How's my code: @GET("posts") Call<ModelJson[]>...
asked by 17.05.2018 / 19:37
0
answers

Synchronize android database with server

Good afternoon, I have an android application, the implementation of the database was done using Realm, I currently have to synchronize the android data with Firebase database realtime, I did not use the standard Apis of Firebase for persiste...
asked by 16.04.2018 / 19:49
0
answers

POST request sending a String via Retrofit on Android

I need a lot of help from you, I'm trying to make a POST request via Retrofit, just send a parameter: { "select":"select id || ' | ' ||senha_terminal,nome,login_web,null,5,null n2,7,senha_terminal,senha_web,data_inclusao from usuario where id...
asked by 28.03.2018 / 14:57
0
answers

Retrofit encode URL

How do I make my url containing a "+" be sent by retrofit with "encode" but currently the result url is: http://api.xxxx.com.br/aluno?campo=220+2d+ And then my backend enede this + as a space, which gives me several problems. The result...
asked by 28.02.2018 / 19:00
0
answers

Remove unicode from the response api from Instagram

As you can see in the image, this is an answer I'm getting from Instagram's api in my android studio ... I need to know if there is any way to remove or read those unicodes that I find to be emotion / emojis. You can not print the text tha...
asked by 12.01.2018 / 01:18
1
answer

ListView selecting position

I have a code that needs it to select the item by its position ... In case he is already selecting but he randomly selects. listView.setOnItemLongClickListener(new AdapterView.OnItemLongClickListener() { @Override public boolean onItemLong...
asked by 25.09.2017 / 17:05
1
answer

Android Retrofit POST

I'm having trouble with a program I'm creating, I tried to see some issues here in the stack or on other sites and I could not solve them. I have a connection that generates a list of data that comes from my bank, and I need it as soon as I clic...
asked by 21.09.2017 / 21:35
0
answers

Problem with RetroFit Return on Android

I'm trying to connect to the local network, using RetroFit . On the local network I have a Rest that returns a json, but when I run the event for this to happen, an error occurs I have an interface class for RetroFit public interface...
asked by 21.08.2017 / 16:46