I'm using Gson to work with json, let's say it has this class
class Track(
@SerializedName("id") val id: Long,
@SerializedName("name") val name: String,
@SerializedName("modality") val modality: String,
@SerializedName("paper")...
How do I read this code with the GSON library?
{
"profissao": {
"jornalista": [
"escritor",
"legal",
"fotografo"
],
"programador": [
"focado",
"exatas",...
I'm using Gson in a web service and I need to prevent some attributes from being serialized and others that are prevented from being deserialized. One of the reasons for preventing a serialization is due to the loop that is entered when serializ...
Good evening, how are you?
I'm developing an Android APP and it consumes data from a webservice, however I'm having trouble getting some information into the APP.
This is the JSON that I return to my APP:
{
"cod":1
,"dados":...
I'm trying to convert a JSONObject item to an ArrayList and for this I created this function from an example I saw here in the forum:
public static ArrayList<Produto> converte(JSONObject jsonObject){
ArrayList<ArrayList>...
Talk about it, all right?
Has anyone used the Gson library in the same project where the SDK was used?
The problem happened when I used the Facebook SDK to allow in-app login through the Facebook account. This routine also worked perfectly...
When I try to send an ArrayList via @POST to be saved in my webserver with Retrofit2, the ArrayList is saved, however I am getting the following error:
java.lang.IllegalStateException: Expected BEGIN_ARRAY but was STRING at line 1 column 1...
Good afternoon!
I am trying to consume an API in android but I am having difficulty because in the JSON file it brings a category, I tried to add the variable "acronym" but it did not work; the JSON returned in the variable response is this:...
When using the GSON library for JSON manipulation, I noticed that when parsers are done the date is being changed, it's tiny, but it's enough to break my unit test with JUnit . >
Follow a sketch code to show the strange beh...
I have a JSON that represents a test query:
{"dctitle":"TestesStatus",
"oslc_cmtotalCount":2,
"oslc_cmresults":
[
{"dctitle":"33643640",
"rdfabout":"XXXXXXXXXXX",
"dbid":"XXXXXXXXXXX",
"depto":"XXXXXXXXXXX",
"sigla"...