Caused by: java.lang.IllegalArgumentException: Platform java.lang.Class annotated [] requires explicit JsonAdapter to be registered
I get the above error when using a RealmList with Moshi.
public class MenuModel implements RealmModel
{
@Json(name = "menugroups")
private RealmList<MenuGroupModel> menugroups = null;
}
I have researched this a bit and found the following:
https://github.com/realm/realm-java/issues/2711
The solution there says I need to use a RealmListAdapter. I have copied the code to my project. I, however, have no idea how and where to implement this adapter.
How do I use it?