Skip to content

Commit

Permalink
Fixed class def not found
Browse files Browse the repository at this point in the history
  • Loading branch information
tranleduy2000 committed Jun 15, 2018
1 parent 7f62369 commit bc7f97c
Show file tree
Hide file tree
Showing 24 changed files with 51 additions and 21 deletions.
4 changes: 2 additions & 2 deletions app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,8 @@ android {
minSdkVersion rootProject.ext.minSdkVersion
targetSdkVersion rootProject.ext.targetSdkVersion
multiDexEnabled true
versionCode 42
versionName "1.4.2"
versionCode 43
versionName "1.4.3"
vectorDrawables.useSupportLibrary = true
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
}
Expand Down
2 changes: 1 addition & 1 deletion app/release/output.json
Original file line number Diff line number Diff line change
@@ -1 +1 @@
[{"outputType":{"type":"APK"},"apkInfo":{"type":"MAIN","splits":[],"versionCode":42,"versionName":"1.4.2","enabled":true,"outputFile":"app-release.apk","fullName":"release","baseName":"release"},"path":"app-release.apk","properties":{}}]
[{"outputType":{"type":"APK"},"apkInfo":{"type":"MAIN","splits":[],"versionCode":43,"versionName":"1.4.3","enabled":true,"outputFile":"app-release.apk","fullName":"release","baseName":"release"},"path":"app-release.apk","properties":{}}]
Binary file added app/src/main/ic_launcher-web.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@ private ArrayList<Class> getAllClassesFromDex(boolean android, String path) {
} catch (ClassNotFoundException e1) {
}
}
} catch (IOException e) {
} catch (Exception e) {
e.printStackTrace();
}
return classes;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -91,23 +91,23 @@ public ArrayList<IClass> getAllClasses() {

public void loadFromProject(JavaProject project) {
long time = System.currentTimeMillis();
try {

CompiledClassLoader classLoader = new CompiledClassLoader(mBootClasspath, mTempDir);
ArrayList<Class> classes = classLoader.getCompiledClassesFromProject(project);
for (Class clazz : classes) {
getClassWrapper(clazz);
}
CompiledClassLoader classLoader = new CompiledClassLoader(mBootClasspath, mTempDir);
ArrayList<Class> classes = classLoader.getCompiledClassesFromProject(project);
for (Class clazz : classes) {
getClassWrapper(clazz);
}

JavaParser parser = new JavaParser();
ArrayList<File> javaSrcDirs = project.getJavaSrcDirs();
for (File javaSrcDir : javaSrcDirs) {
Collection<File> javaFiles = FileUtils.listFiles(
javaSrcDir,
new String[]{"java"},
true);
for (File javaFile : javaFiles) {
if (DLog.DEBUG) DLog.d(TAG, "loadFromProject: parsing class " + javaFile);
try {
JavaParser parser = new JavaParser();
ArrayList<File> javaSrcDirs = project.getJavaSrcDirs();
for (File javaSrcDir : javaSrcDirs) {
Collection<File> javaFiles = FileUtils.listFiles(
javaSrcDir,
new String[]{"java"},
true);
for (File javaFile : javaFiles) {
if (DLog.DEBUG) DLog.d(TAG, "loadFromProject: parsing class " + javaFile);
FileInputStream input = new FileInputStream(javaFile);
String content = IOUtils.toString(input, "UTF-8");
input.close();
Expand All @@ -116,10 +116,10 @@ public void loadFromProject(JavaProject project) {
for (IClass aClass : parseClasses) {
update(aClass);
}
} catch (Exception e) {
e.printStackTrace();
}
}
} catch (Throwable e) {
e.printStackTrace();
}

System.out.println("Loaded classes " + (System.currentTimeMillis() - time));
Expand Down
5 changes: 5 additions & 0 deletions app/src/main/res/mipmap-anydpi-v26/ic_launcher.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
<?xml version="1.0" encoding="utf-8"?>
<adaptive-icon xmlns:android="http://schemas.android.com/apk/res/android">
<background android:drawable="@color/ic_launcher_background"/>
<foreground android:drawable="@mipmap/ic_launcher_foreground"/>
</adaptive-icon>
5 changes: 5 additions & 0 deletions app/src/main/res/mipmap-anydpi-v26/ic_launcher_round.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
<?xml version="1.0" encoding="utf-8"?>
<adaptive-icon xmlns:android="http://schemas.android.com/apk/res/android">
<background android:drawable="@color/ic_launcher_background"/>
<foreground android:drawable="@mipmap/ic_launcher_foreground"/>
</adaptive-icon>
Binary file modified app/src/main/res/mipmap-hdpi/ic_launcher.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified app/src/main/res/mipmap-mdpi/ic_launcher.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified app/src/main/res/mipmap-xhdpi/ic_launcher.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified app/src/main/res/mipmap-xxhdpi/ic_launcher.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified app/src/main/res/mipmap-xxxhdpi/ic_launcher.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
20 changes: 20 additions & 0 deletions app/src/main/res/values/ic_launcher_background.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
<?xml version="1.0" encoding="utf-8"?><!--
~ Copyright (C) 2018 Tran Le Duy
~
~ This program is free software: you can redistribute it and/or modify
~ it under the terms of the GNU General Public License as published by
~ the Free Software Foundation, either version 3 of the License, or
~ (at your option) any later version.
~
~ This program is distributed in the hope that it will be useful,
~ but WITHOUT ANY WARRANTY; without even the implied warranty of
~ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
~ GNU General Public License for more details.
~
~ You should have received a copy of the GNU General Public License
~ along with this program. If not, see <https://www.gnu.org/licenses/>.
-->

<resources>
<color name="ic_launcher_background">#20242A</color>
</resources>
Binary file modified lib-n-ide-release-10/lib-n-ide-release-10.aar
Binary file not shown.

0 comments on commit bc7f97c

Please sign in to comment.