I am trying to convert ArrayList of custom class to JsonArray. Below is my code. It executes fine but some JsonArray elements come as zeros even though they are numbers in the A
List<> is a normal java object, and can be successfully transformed using standard gson object api. List in gson looks like this:
"libraries": [ { //Containing object }, { //Containing object } ], ...