简体   繁体   English

在没有项目的情况下浏览Eclipse中的导入

[英]Navigating through imports in Eclipse without project

在此处输入图片说明 I got my hands onto an Android project that was decompiled from .apk into an obfuscated version of a Java project (has the google, com folders and what not). 我接触到了一个Android项目,该项目从.apk反编译为Java项目的混淆版本(具有google,com文件夹等)。 I want to study the code, but it is hard, because all the paths look like aaaab().c(); 我想研究代码,但是很难,因为所有路径看起来都像aaaab().c();

Is it possible to set up Eclipse, or any other IDE to accept the folder with all the .java classes and treat it as a project so when I click on the import or the object that was created using a different class, I would navigate to that class instead of manually searching for every file? 是否可以设置Eclipse或任何其他IDE来接受包含所有.java类的文件夹并将其视为项目,所以当我单击导入或使用其他类创建的对象时,我将导航至该类,而不是手动搜索每个文件?

or any other IDE 或任何其他IDE

Well in Android Studio. Android Studio很好。 First I added a new folder with some java files and packages on my desktop, without any other files. 首先,我在桌面上添加了一个新文件夹,其中包含一些Java文件和程序包,而没有其他文件。

Then I managed to open it using Android Studio by simpling opening a folder as a project. 然后我设法通过将文件夹作为项目打开来使用Android Studio打开它。

在此处输入图片说明

After that in my project structure tab, I selected Project . 之后,在“项目结构”选项卡中,选择“ Project

在此处输入图片说明

And the files and subfolders appeared like they are present in the folder. 文件和子文件夹的显示就像在文件夹中一样。 Note that an .idea folder will be created by Android Studio when you open the project folder. 请注意,打开项目文件夹时,Android Studio将创建一个.idea文件夹。

To actually navigate through the files you can create a Java project in Android Studio, then add a new sub-package, and open the folder containing the files. 要实际浏览文件,您可以在Android Studio中创建一个Java项目,然后添加一个新的子包,并打开包含文件的文件夹。

Adding java folders to android studio project 将Java文件夹添加到android studio项目

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

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