
问题集
multi type of question!
NO Exception?
分享内容!
展开
-
自定义LinearLayoutManager 固定recyclerView 滑动区间
computeHorizontalScrollExtent 是 RecyclerView 提供的一个方法,用于计算当前可见区域的宽度。computeHorizontalScrollRange 是 RecyclerView 提供的一个方法,用于计算可滚动的总范围。作用:返回当前滚动窗口中可见部分的宽度(水平方向)。这个值可以帮助确定用户当前能够看到的内容范围。原创 2025-02-07 19:57:56 · 166 阅读 · 0 评论 -
compileDebugKotlin FAILED Unresolved reference: xxxx
compileDebugKotlin FAILED Unresolved reference: xxxx原创 2022-06-02 16:18:20 · 681 阅读 · 0 评论 -
Unable to start service Intent { act=xx.xx.xx } U=0: not found
在执行AIDL 通信的时候,我们需要绑定service报错:Unable to start service Intent { act=xx.xx.xx } U=0: not found后使用intent.component解决 private fun startRemoteService() { Log.d(TAG, "---------------------------startRemoteService: ") val intent = Intent原创 2022-03-29 10:33:24 · 2694 阅读 · 0 评论 -
ERROR: commit 60acc70: missing Change-Id in message footer
我在合并多次commit的时候,不小心删除Change-Id,导致push失败remote: Processing changes: refs: 1 remote: Processing changes: refs: 1, done remote: ERROR: commit 60acc70: missing Change-Id in message footer remote: remote: Hint: to automatically ins原创 2022-02-23 09:44:43 · 506 阅读 · 0 评论 -
The minCompileSdk (30) specified in a dependency‘s AAR metadata (META-INF/com/android/build/gradle/a
The minCompileSdk (30) specified in adependency’s AAR metadata (META-INF/com/android/build/gradle/aar-metadata.properties)is greater than this module’s compileSdkVersion (android-28).Dependency: androidx.media:media:1.4.3.AAR metadata file: C:\Users\xx原创 2022-01-19 17:47:06 · 4422 阅读 · 0 评论 -
解决:androidstudio sdk build-Tools 更新不了
1.android SDK 更新不了sdkAll packages are not available for download!2.下载build-tools 失败Failed download to build_tools 28.0.3最近更新build-tools更新不了,终于在stackoverflow找到了解决方法。1.File–>setting–Appearance$Behavior–>System Settings2.选择 HTTP Proxy,auto-detect原创 2021-11-30 11:16:59 · 980 阅读 · 0 评论 -
Gradle-7.0.3 build.gradle字段有改变
如果你使用最新的 Gradle-7.0.3build.gradle文件里 defaultConfig 作用域内个别字段有变化。 defaultConfig { applicationId "com.example.myapplication" minSdk 21 //这里 targetSdk 31 //这里 versionCode 1 versionName "1.0" testInstrument原创 2021-11-14 16:54:37 · 939 阅读 · 0 评论 -
解决 kotlin 作为依赖库AAR的时候看不到源码
1.背景当kotlin语言编写的library的被其他App项目引用,在debug调试的时候,无法查看具体的代码逻辑。这时候就需要导入自己的源代码来进行调试。2.方案project—>右键—>library Properties…导入自己的源码即可。文件夹定位到main文件夹。...原创 2021-11-09 20:04:39 · 5240 阅读 · 0 评论 -
SSL peer shut down incorrectly
SSL peer shut down incorrectly一般需要翻墙获取,一般配置阿里云库project–>build.gradle文件里把阿里的服务放到前面// Top-level build file where you can add configuration options common to all sub-projects/modules.buildscript { repositories { maven { url 'https://jitpac原创 2021-11-03 18:15:48 · 232 阅读 · 0 评论 -
download maven-metadata.xml slow 下载卡住
download maven-metadata.xml 下载不下来,使用Gradle 线下模式(offline Mode)软件环境:Androidstudio 4.2.2 win10原创 2021-10-12 09:57:45 · 468 阅读 · 0 评论 -
TextView 换行且显示省略号
TextView 以往使用singleLine= false,但是目前废弃了。使用maxLines来指定行数,且固定textview的width。 <TextView android:id="@+id/product_des" android:layout_width="wrap_content" android:layout_height="wrap_content" android:maxEms="12"原创 2021-09-29 12:04:33 · 318 阅读 · 0 评论 -
Android 7.0 Log exceeds limit of 23 characters
问题 Caused by: java.lang.IllegalArgumentException: Log tag "xxxxxx_1.0.2021-08-02-2024.1" exceeds limit of 23 characters Log类说明public static boolean isLoggable (String tag, int level)tag String: The tag to check. This value may be null.leve原创 2021-08-02 20:53:46 · 292 阅读 · 0 评论 -
AIDL 找不到符号 方法 readFromParcel(Parcel)
1.AIDL 找不到符号 方法 readFromParcel(Parcel)解决方法:如果需要传入传出(in out)参数Book需要重写Bean对象的方法2.aidl 找不到符号把Java文件放到Java文件夹下,aidl文件放到aidl文件夹下,重新编译。...原创 2021-04-28 22:40:27 · 1323 阅读 · 0 评论 -
GreenDao @Convert注解的使用
@Convert 转换的意思,有时候bean对象里包含一些对象,我们可以使用@ToOne @ToMany,但是有时候不是对象的情况就不好处理了。GreenDao 默认不支持集合对象images.所有需要转换类型。@Entitypublic class DataBean { @Id private Long id;//_id @Property(nameInDb = "uid") private String _id; private List<Stri原创 2021-03-09 17:24:22 · 1358 阅读 · 0 评论 -
c++ 问题集
#define _CRT_SECURE_NO_WARNINGS‘EXIT_SUCCESS’ was not declared in this scope#include <stdlib.h>https://www.runoob.com/cprogramming/c-standard-library-stdlib-h.html原创 2021-02-20 22:08:32 · 468 阅读 · 0 评论 -
Mac 安装nodemon 失败 Error: EACCES: permission denied, access ‘/usr/local/lib/node_modules‘
npm WARN checkPermissions Missing write access to /usr/local/lib/node_modulesnpm ERR! code EACCESnpm ERR! syscall accessnpm ERR! path /usr/local/lib/node_modulesnpm ERR! errno -13npm ERR! Error: EACCES: permission denied, access '/usr/local/lib/node_m原创 2021-01-27 16:47:30 · 716 阅读 · 0 评论 -
Tomcat 问题汇总
1.配置java 环境变量1.1 找到java安装的目录1.2 配置环境变量桌面–此电脑–属性–高级系统设置2.tomcat 启动闪屏3.tomcat 启动日志乱码原创 2020-11-02 11:46:21 · 389 阅读 · 0 评论 -
AndroidStudio各种问题汇总
1.连接网络原创 2020-10-22 23:48:03 · 242 阅读 · 0 评论 -
mac flutter no devices解决方法
flutter 默认找不到设备,在Androidstudio里,找到terminal输入一下命令。需要配置flutter的两个属性android sdk路径:flutter config --android-sdk ~/Documents/...sdkandroid studio文件夹路径flutter config --android-studio-dir ~/Application/Android Studio然后重启。...原创 2020-06-02 08:12:24 · 1510 阅读 · 0 评论 -
运行flutter应用时,Running Gradle task assembleDebug 无反应
1.修改项目build.gradlebuildscript { repositories { google() jcenter() //添加// maven { url 'https://maven.aliyun.com/repository/google' } maven { url 'https://maven.aliyun.com/repository/jcenter' } maven { url 'h原创 2020-05-28 20:11:08 · 1835 阅读 · 0 评论 -
Attempt to invoke virtual method 'java.lang.Class dalvik.system.DexPathList$Element.findClass(java.l
Caused by: java.lang.NullPointerException: Attempt to invoke virtual method 'java.lang.Class dalvik.system.DexPathList$Element.findClass(java.lang.String, java.lang.ClassLoader, java.util.List)' on a ...原创 2020-03-26 22:10:07 · 529 阅读 · 0 评论 -
Android原生模拟器 导入文件 问题(android emulator import file)及解决方法
1.导入文件到模拟器我们在使用官方模拟器的时候,一般通过Device File Explorer 设备管理器导入。但是你导入以后,在模拟器里看不到这个文件。 但其实导入的文件是在sd卡的根目录,已经通过程序测试。具体原因未知。快捷导入快捷导入文件就是拖动文件到模拟器里,如果是apk,它会自动安装,如果是其他文件,它会自动导入sd卡的downloads文件夹下。且能够显示文件。...原创 2020-03-17 12:58:33 · 1773 阅读 · 0 评论 -
androidstudio 关联源码及Androidstudio4.2 jdk.table.xml 问题
很多同学在使用androidstudio的使用继承某些类要重写父类的方法,但是重写的方法的参数,不能直观的看到它的意图。如果你引入了源码的就可以清晰的看到。比如:public class CityAdapter extends BaseExpandableListAdapter { @Override public View getGroupView(int groupPositi...原创 2020-03-15 21:09:27 · 977 阅读 · 0 评论 -
BottomNavigationActivity 出现顶部白色条框,底部遮挡内容--解决
我们在创建Project的时候,如果选用了BottomNavigationActivity 来创建activity,等你在fragment里布局得时候,你会发现顶部会出现白色条框,高度相当一个bar的高度。白色条框解决:activity_main.xml删除这句,它有一个actionBar的高度。 android:paddingTop="?attr/actionBarSize">顶...原创 2020-03-07 23:44:56 · 2120 阅读 · 9 评论 -
java.lang.IllegalStateException: View can not be anchored to the the parent CoordinatorLayout
java.lang.IllegalStateException: View can not be anchored to the the parent CoordinatorLayout视图无法使用父布局CoordinatorLayout作为锚点。解决:app:layout_anchor="@id/main_content"改为:app:layout_anchor="@id/viewpa...原创 2020-03-06 14:30:30 · 476 阅读 · 1 评论 -
greendao 错误问题
greendao 错误问题greendao 错误问题greendao 错误问题原创 2020-02-21 18:55:49 · 294 阅读 · 0 评论 -
WARNING: API 'variant.getJavaCompiler()' is obsolete and has been replaced with 'variant.getJavaComp
WARNING: API 'variant.getJavaCompiler()' is obsolete and has been replaced with 'variant.getJavaCompileProvider()'.It will be removed at the end of 2019.For more information, see https://d.android.c...原创 2020-02-21 12:35:48 · 465 阅读 · 0 评论