Unable to use FirebaseRecyclerAdapter

巧了我就是萌 提交于 2019-12-09 04:35:32

Can you show your build.gradle file?

Also, have you tried putting this under your package name in your java class: import com.firebase.ui.database.FirebaseRecyclerAdapter;?

I was getting the same issue, it's resolved by adding the firebase-ui dependency in build.gradle (module:app)

compile 'com.firebaseui:firebase-ui-database:0.4.0'

Also add the import in .java file where you're trying to declare it.

import com.firebase.ui.database.FirebaseRecyclerAdapter;

In your app level gradle:add the following firebase dependency

    dependencies {
 compile'com.firebaseui:firebase-ui-database:1.1.1'

The dependencies quoted above don't seem to work anymore. After about an hour of searching online, I found this; hopefully it helps someone. It certainly fixed my problem:

compile 'com.firebaseui:firebase-ui:0.4.3'

Qais

Use exactly the matched version of FireBaseRecyclerAdapter to the Versions that you have included in gradle for the Firebase Database. This link will surely help you

https://github.com/firebase/FirebaseUI-Android

In this link, you will find the matched Firebase dependency according to the version.

Go to build.gradle file, add a dependency (get the latest one from here https://github.com/firebase/FirebaseUI-Android)

The latest one on 5 October 2019 is implementation 'com.firebaseui:firebase-ui-database:6.0.2'

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!