简体   繁体   中英

Cannot resolve symbol inside JAR imported in Android Studio

I am trying to work with a jar which is of a previous project that has been properly tested and works fine. I even decompiled the jar inside Android Studio and ran it and it worked fine as can be seen below: 在此处输入图片说明

But the problem is this(HashTableClass.java and HashNodeClass.java are decompiled from the jar):

Only HashTableClass is being identified and all the other classes are not being identified

这是我的build.gradle

My imported jar file contains multiple packages.Things that I have tried to get out of this mess: 1.Invalidate Cache/Restart 2.Sync Project with Gradle Files

One solution is explicit typing of the package name before the type name in the java files of the jar but that doesn't seem to be a good solution.

My question is: How do I stop this "cannot resolve symbol" mess in my JAR effectively?

我对JAR中的源文件做了一些小的更改,然后导入了一个新的JAR,问题得以解决。

我正在使用jsoup Jar文件,并且发生了这种情况,我通过从依赖项中删除它并再次添加来解决了该问题

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM