我正在尝试从服务器获取数据Realm
并将其发送到服务器retrofit
,用于解析和序列化我正在使用LoganSquare
client = new Retrofit.Builder()
.baseUrl(REST_ENDPOINT)
.client(okHttpClient)
.addConverterFactory(LoganSquareConverterFactory.create())
.build();
这就是我访问记录的方式
Appointment appointments = DB.getInstance(mContext).selectNotSyncAppointmentsData();
RestApi.AppointmentsDataApi service = getAppointmentsDataApi();
Call<APResponse> call = service.createUpdateAppointmentsData(appointments);
我收到以下错误
createUpdateAppointmentData : onFailure Class io.realm.AppointmentRealmProxy could not be mapped to a JSON object. Perhaps it hasn't been annotated with @JsonObject?