【仅供内部供应商使用,不提供对外解答和培训】

Page tree

Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Code Block
languagegroovy
title添加模块依赖
linenumberstrue
    compile fileTree(include: ['*.jar'], dir: 'libs')  // 依赖部分jar包文件
 
    compile ('com.fr.android:bi-sdk:+', {// BI功能对应模块.

        //  可能的冲突版本 需要排除
//        exclude group: 'com.google.zxing',  module:core:3.1.0'// 内部使用
compile 'core'
//        exclude group: 'com.jiechic.library',  module:xUtils:2.6.14'
compile 'xUtils'
//        exclude group: 'com.android.support',  module: 'appcompat-v7:23.2.0'
compile'
//        exclude group: 'com.android.support',  module: 'recyclerview-v7:23.4.0'

    })
    compile ('com.fr.android:report-sdk:+', {// 添加SDK report模块依赖
报表对应模块.

        //  可能的冲突版本 需要排除
//    transitive    = false
})
compile (exclude group: 'com.fr.android:bi-sdk:+google.zxing', {  module: 'core'
// 添加SDK  bi模块依赖
    transitive = false
})
compile (exclude group: 'com.fr.android:platform:+jiechic.library',  { module: 'xUtils'
//  添加SDK 核心模块依赖
    transitive = false
})
compile (exclude group: 'com.fr.android:core:+android.support', {  module: 'appcompat-v7'
//   添加SDK 核心模块依赖
    transitiveexclude = false  // 去除对应lib内部引用
})

compile (group: 'com.android.support',  module: 'recyclerview-v7'
    })
	// 根据需要加载对应的插件模块
    compile 'com.fr.android:gislocation:+',     {// 可选插件 地图模块依赖定位插件,获取经纬度
    transitive = false
})
compile ('com.fr.android:locationvpn:+', {          // 可选插件VPN插件,登录Sangfor VPN 定位模块依赖服务器
    transitive = false
})
compile ('com.fr.android:vpngis:+',   {// 可选插件 vpn模块依赖
    transitive =// false
})
GIS插件,显示GIS地图图表
    compile ('com.fr.android:push-xg:+', {// 可选插件 信鸽推送模块依赖
   // transitive = false
})推送插件, 集成信鸽推送服务

添加后,build.gradle如下所示

4. 在该模块清单文件的application标签中添加属性

...

如上,工程配置完毕,FR SDK已经成功添加到您的项目中,之后可以直接引用FR相关的API,进行集成开发。您也可以参考OEM_demo和SDK_demo中的项目结构和build.gradle文件,进行工程配置。gradle文件,进行工程配置。各插件模块的使用,请参考相关插件文档。