Android开发常用依赖大全

//【FastJson】
implementation ‘com.alibaba:fastjson:1.2.55’

//【Picasso】
implementation ‘com.squareup.picasso:picasso:2.5.2’

//【屏幕适配】
implementation ‘com.zhy:autolayout:1.4.5’

//【轮播图】
implementation ‘com.youth.banner:banner:1.4.10’

//【gson依赖】
implementation ‘com.google.code.gson:gson:2.8.0’//2.8.5

//【okhttp依赖】
implementation ‘com.squareup.okhttp3:okhttp:3.12.1’

//【Interceptor日志拦截器】
implementation ‘com.squareup.okhttp3:logging-interceptor:3.12.0’//3.11.0

//【okgo依赖】
implementation ‘com.lzy.net:okgo:3.0.4’

//【Retrofit】
implementation ‘com.squareup.retrofit2:retrofit:2.6.2’

//【RetrofitGson】
implementation ‘com.squareup.retrofit2:converter-gson:2.6.2’//2.8.5

//【RetrofitRxJava】
implementation ‘com.squareup.retrofit2:adapter-rxjava2:2.6.2’

//【RxJava】
implementation ‘io.reactivex.rxjava2:rxjava:2.2.6’

//【RxAndroid】
implementation ‘io.reactivex.rxjava2:rxandroid:2.1.1’

//【glide依赖】
implementation ‘com.github.bumptech.glide:glide:4.9.0’

//【glide注解解释器】
annotationProcessor ‘com.github.bumptech.glide:compiler:4.11.0’

//【SmartRefreshLayout】让Rv也可刷新加载
implementation ‘com.scwang.smartrefresh:SmartRefreshLayout:1.1.0’

//【RecyclerView】
//implementation ‘com.android.support:recyclerview-v7:28.0.0’//非androidx
implementation ‘androidx.legacy:legacy-support-v4:1.0.0’

//【万能适配器,需要额外配置项目gradio】
implementation ‘com.github.CymChad:BaseRecyclerViewAdapterHelper:3.0.0’//2.9.22
allprojects {
repositories {
maven { url “https://jitpack.io” }
}
}

//【Dagger】
implementation ‘com.google.dagger🗡2.19’

//【Dagger注解解释器】
annotationProcessor ‘com.google.dagger:dagger-compiler:2.19’

//【Design】
//implementation ‘com.android.support:design:28.0.0’//非androidx
implementation ‘com.google.android.material:material:1.2.0’//1.1.0

//【间隔线】
implementation ‘com.yanyusong.y_divideritemdecoration:y_divideritemdecoration:2.0’

//【ButterKnift,需要额外配置项目gradle】
implementation ‘com.jakewharton:butterknife:8.2.1’//10.2.1

//【ButterKnift注解解释器】
annotationProcessor ‘com.jakewharton:butterknife-compiler:8.2.1’
android{
compileOptions {
sourceCompatibility JavaVersion.VERSION_1_8
targetCompatibility JavaVersion.VERSION_1_8
}
}

//【ARouter】
implementation ‘com.alibaba:arouter-api:1.5.0’

//【ARouter注解解释器】
annotationProcessor ‘com.alibaba:arouter-compiler:1.2.2’

//【ZXing】
implementation ‘cn.yipianfengye.android:zxing-library:2.2’

//【XRecyclerview】
implementation ‘com.android.support:recyclerview-v7:28.0.0’
api(‘com.jcodecraeer:xrecyclerview:1.5.9’) {
exclude group: ‘com.android.support’
}

//【Flycotablayout】
implementation ‘com.flyco.tablayout:FlycoTabLayout_Lib:2.0.2@aar’

//【EventBus广播】
implementation ‘org.greenrobot:eventbus:3.1.1’

//【Kotlin公共库】
implementation “org.jetbrains.anko:anko-commons:$anko_version”
buildscript{
ext.anko_version=“0.10.8”//版本
}

//【KotlinSQLite】
implementation “org.jetbrains.anko:anko-sqlite:$anko_version”
android{
androidExtensions{
experimental= true
}
}

//【Kotlin协程】
implementation ‘org.jetbrains.kotlinx:kotlinx-coroutines-core:1.3.6’
implementation “org.jetbrains.kotlinx:kotlinx-coroutines-android:1.3.6”

//【Kotlin协程与Retrofit】
implementation “com.jakewharton.retrofit:retrofit2-kotlin-coroutines-adapter:0.9.2”

//【Kotlin Coroutines协程】
implementation “org.jetbrains.kotlinx:kotlinx-coroutines-android:1.3.3”//1.3.6

//【ViewModel】
implementation “android.arch.lifecycle:extensions:1.1.1”

//【MPAndChart表图】
implementation ‘com.github.PhilJay:MPAndroidChart:v2.1.6’
allprojects {
repositories {
maven { url ‘https://jitpack.io’ }
}
}

//ExpandView收缩布局
implementation ‘com.wkp:ExpandView:1.0.4’
https://www.jianshu.com/p/9ddbfed4c454
// room
implementation “android.arch.persistence.room:runtime:1.1.1”
// room 配合 RxJava
implementation “android.arch.persistence.room:rxjava2:1.1.1”
annotationProcessor ‘android.arch.persistence.room:compiler:1.1.1’

// XMPP通信
api ‘org.igniterealtime.smack:smack-im:4.2.0’
api ‘org.igniterealtime.smack:smack-tcp:4.2.0’
api ‘org.igniterealtime.smack:smack-android-extensions:4.2.0’
api ‘org.igniterealtime.smack:smack-android:4.2.0’

//TBS腾讯WebView
api ‘com.tencent.tbs.tbssdk:sdk:43903’
//VerticalTabLayout
implementation ‘q.rorbin:VerticalTabLayout:1.2.5’

implementation ‘org.xutils:xutils:3.3.34’
implementation ‘com.github.stuxuhai:jpinyin:1.0’//拼音
implementation ‘com.squareup:otto:1.3.8’ otto依赖
//图片文件选择器
implementation ‘com.github.wildma:PictureSelector:2.0.0’//非androidx用1.1.6,有问题
//Rxpermissions
implementation ‘com.github.tbruyelle:rxpermissions:0.10.2’//权限管理,不能用

//配置版本为Java8
android{
compileOptions {
sourceCompatibility JavaVersion.VERSION_1_8
targetCompatibility JavaVersion.VERSION_1_8
}
}

Calces 组件化:
项目gradle中引入
plugins {
id “calces.appconfig” version “3.3.0-alpha01”
}
appConfig{
debugEnable true//总开关
apps{
app{
applicationId ‘com.zmk.calces’
applicationName ‘.App’
mainActivity ‘.MainActivity’
modules ‘:store’,’:user’
}
}
modules{
store{
name ‘:store’
applicationId ‘com.zmk.store’
applicationName ‘.StoreApp’
mainActivity ‘.MainActivity’
isRunAlone false
}
user{

}
}
}
apply plugin: ‘calces.modules’//替换apply

PhotoView
implementation ‘com.github.chrisbanes:PhotoView:2.3.0’//PhotoView
allprojects {
repositories {
maven { url “https://jitpack.io” }//项目gradio
}
}
PickerView
implementation ‘com.contrarywind:Android-PickerView:4.1.9’//PickerView
//StatusBarutil状态栏框架
api ‘com.jaeger.statusbarutil:library:1.5.1’

//观察者内存泄漏,解决RxJava内存泄漏问题
implementation ‘com.uber.autodispose:autodispose-android-archcomponents:1.0.0-RC3’
implementation ‘com.uber.autodispose:autodispose-android:1.0.0-RC3’
//导入Java8

implementation ‘org.jetbrains:annotations-java5:15.0’

//图片文件选择器
implementation ‘com.github.wildma:PictureSelector:1.1.6’//androidx用2.0.0
allprojects {
repositories {
maven { url “https://jitpack.io” }
}
}

//GreenDao
buildscript {
repositories {
mavenCentral() // add repository
}
dependencies{
classpath ‘org.greenrobot:greendao-gradle-plugin:3.2.2’ // add plugin
}
}
android{
greendao {
schemaVersion 1 //当前数据库版本
}
}
apply plugin: ‘org.greenrobot.greendao’ // apply plugin
implementation ‘org.greenrobot:greendao:3.2.2’ // add library

//GSYVideoPlayer 直播视频播放器
//配置Java8
implementation ‘com.shuyu:GSYVideoPlayer:7.1.3’
defaultConfig {
minSdkVersion 19 // 19及以上
}

//disklru磁盘缓存
implementation ‘com.jakewharton:disklrucache:2.0.2’

//CardView
implementation ‘com.android.support:cardview-v7:27.1.1’

//BottomNavigationView
//导design包
implementation ‘androidx.navigation:navigation-fragment:2.0.0’
implementation ‘androidx.navigation:navigation-ui:2.0.0’

so库
android{
sourceSets {
main {
jniLibs.srcDir ‘libs’
}
}
}

评论 1
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值