@@ -0,0 +1,1716 @@
+package local.tomo.login.json.deserializer;%0A%0Aimport android.util.Log;%0A%0Aimport com.google.gson.JsonDeserializationContext;%0Aimport com.google.gson.JsonDeserializer;%0Aimport com.google.gson.JsonElement;%0Aimport com.google.gson.JsonParseException;%0A%0Aimport java.lang.reflect.Type;%0Aimport java.util.Date;%0A%0Aimport local.tomo.login.model.Medicament;%0A%0A/**%0A * Created by tomo on 2016-06-13.%0A */%0Apublic class MedicamentDeserializer implements JsonDeserializer%3CMedicament%3E %7B%0A    @Override%0A    public Medicament deserialize(JsonElement json, Type typeOfT, JsonDeserializationContext context) throws JsonParseException %7B%0A        JsonElement id = json.getAsJsonObject().get(%22id%22);%0A        JsonElement name = json.getAsJsonObject().get(%22name%22);%0A        JsonElement producent = json.getAsJsonObject().get(%22producent%22);%0A        JsonElement price = json.getAsJsonObject().get(%22price%22);%0A        JsonElement kind = json.getAsJsonObject().get(%22kind%22);%0A        JsonElement productLineID = json.getAsJsonObject().get(%22productLineID%22);%0A        JsonElement packageID = json.getAsJsonObject().get(%22packageID%22);%0A        JsonElement dateExpiration = json.getAsJsonObject().get(%22dateExpiration%22);%0A        Medicament medicament = new Medicament();%0A        medicament.setId(id.getAsInt());%0A        medicament.setName(name.getAsString());%0A        medicament.setProducent(producent.getAsString());%0A        medicament.setPrice(price.getAsDouble());%0A        medicament.setKind(kind.getAsString());%0A        medicament.setProductLineID(productLineID.getAsInt());%0A        medicament.setPackageID(packageID.getAsInt());%0A        Date date = new Date(dateExpiration.getAsLong());%0A        medicament.setDateExpiration(date);%0A%0A        return medicament;%0A    %7D%0A%7D%0A

add json deserializer