Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我想确定在 Moshi 中在一个 Moshi 上安装两个适配器是否合法 - 我没有收到错误,但我发现在某些设备上存在问题:
Moshi moshi = new Moshi.Builder() .add(new CallLogJsonAdapter()) .add(new ContactJsonAdapter()) .build();
Moshi 允许您使用任意数量的适配器。在多个类适应同一类型的异常情况下,您首先添加的类优先。