android - 使用 FirebaseListAdapter 需要对 gradle 进行哪些更改?

标签 android listview firebase firebase-realtime-database firebaseui

嗯,我已经完成了一个使用 FirebaseListAdapter 的项目,但是通过最近的 Firebase 更新,我必须在依赖项中进行哪些修改才能继续使用 FirebaseListAdapter

我的最后一个 gradle(app) 文件:

dependencies {
    compile fileTree(dir: 'libs', include: ['*.jar'])
    compile 'com.android.support:appcompat-v7:23.0.1'
    compile 'com.android.support:design:23.0.1'
    compile 'com.android.support:support-v4:23.0.1'
    compile 'com.android.support:cardview-v7:23.0.1'
    compile 'de.hdodenhof:circleimageview:2.1.0'
    /* Firebase SDK */
    compile 'com.firebase:firebase-client-android:2.4.0'

    /* Firebase UI */
    compile 'com.firebaseui:firebase-ui:0.2.2'

    /* For Google Play Services */
    compile 'com.google.android.gms:play-services-safetynet:8.3.0'
    compile 'com.google.android.gms:play-services-auth:8.3.0'
}

我的最后一个 gradle 文件:

buildscript {
    repositories {
        jcenter()
    }
    dependencies {
        classpath 'com.android.tools.build:gradle:2.2.2'

        // NOTE: Do not place your application dependencies here; they      
        // in the individual module build.gradle files
    }
}

最佳答案

您必须添加此依赖项:

// FirebaseUI Database only
compile 'com.firebaseui:firebase-ui-database:1.0.1'

在此处检查兼容性 between versions :

| FirebaseUI Version | Firebase/Play Services Version |
|--------------------|--------------------------------|
| 1.0.1              | 10.0.0                         |
| 1.0.0              | 9.8.0                          |
| 0.6.2              | 9.8.0                          |
| 0.6.1              | 9.6.1                          |
| 0.6.0              | 9.6.0                          |
| 0.5.3              | 9.4.0                          |
| 0.4.4              | 9.4.0                          |
| 0.4.3              | 9.2.1                          |
| 0.4.2              | 9.2.0                          |
| 0.4.1              | 9.0.2                          |
| 0.4.0              | 9.0.0                          |

关于android - 使用 FirebaseListAdapter 需要对 gradle 进行哪些更改?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/41185323/

相关文章:

c# - 如何在 C# 中从 FireBase 数据库获取 NodeId?

android - 如何从 Activity 启动 Fragment?

listview - ExtJS3.x 中 ListView 上的滚动事件

Android ListView setSelectionFromTop 不工作

android - Firebase 云消息在后台崩溃

firebase - 如何限制对 Firestore 中用户拥有的文档的写入?

java - 在嵌套数组中提取数组 Java

android - 错误 :org. gradle.internal.UncheckedException: 构建命令失败

android - 如何使用 Genymotion 使用 Wifi Direct(Wi-Fi 点对点 Wifi P2P)运行 android 应用程序?

android - 使用卡片 View 创建 'line connected' recyclerview