Skip to content
This repository was archived by the owner on Apr 13, 2023. It is now read-only.
This repository was archived by the owner on Apr 13, 2023. It is now read-only.

报这个是什么错误额? #37

Description

@i91h1r

ClassNotFoundException: Didn't find class "androidx.collection.LruCache" on path: DexPathList[

在model 中加上相关的缓存代码

public class HomeNewRecommendModel implements HomeNewRecommendContract.Model {
@OverRide
public Observable getHomeNewRecommendData(String baby_id) {
return HomeIndexAPI.get().getHomeNewRecommendData(baby_id).compose(new DefaultTransformer<>()).compose(
RxCache.getDefault().transformObservable("my_home/v317" + baby_id,new TypeToken(){}.getType(),
CacheStrategy.firstCache())).map(new CacheResult.MapFunc());
}
}

Activity

  1. XuanJiAndroid commented on Oct 28, 2019

    @XuanJiAndroid

    同样的问题,应该是库里面用了androidx的东西,但原项目内没有迁移到androidx

    java.lang.NoClassDefFoundError: Failed resolution of: Landroidx/collection/LruCache

  2. XuanJiAndroid commented on Oct 28, 2019

    @XuanJiAndroid

    已解决,将版本修改成2.3.3即可,参考issues/32

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions