<bdo id='YeQzR'></bdo><ul id='YeQzR'></ul>

<tfoot id='YeQzR'></tfoot>
  • <legend id='YeQzR'><style id='YeQzR'><dir id='YeQzR'><q id='YeQzR'></q></dir></style></legend>

    <small id='YeQzR'></small><noframes id='YeQzR'>

      <i id='YeQzR'><tr id='YeQzR'><dt id='YeQzR'><q id='YeQzR'><span id='YeQzR'><b id='YeQzR'><form id='YeQzR'><ins id='YeQzR'></ins><ul id='YeQzR'></ul><sub id='YeQzR'></sub></form><legend id='YeQzR'></legend><bdo id='YeQzR'><pre id='YeQzR'><center id='YeQzR'></center></pre></bdo></b><th id='YeQzR'></th></span></q></dt></tr></i><div id='YeQzR'><tfoot id='YeQzR'></tfoot><dl id='YeQzR'><fieldset id='YeQzR'></fieldset></dl></div>

        如何获取主类的 Java 类依赖项列表?

        How do I get a list of Java class dependencies for a main class?(如何获取主类的 Java 类依赖项列表?)
      1. <legend id='NclJs'><style id='NclJs'><dir id='NclJs'><q id='NclJs'></q></dir></style></legend>
          <bdo id='NclJs'></bdo><ul id='NclJs'></ul>
        • <small id='NclJs'></small><noframes id='NclJs'>

              <i id='NclJs'><tr id='NclJs'><dt id='NclJs'><q id='NclJs'><span id='NclJs'><b id='NclJs'><form id='NclJs'><ins id='NclJs'></ins><ul id='NclJs'></ul><sub id='NclJs'></sub></form><legend id='NclJs'></legend><bdo id='NclJs'><pre id='NclJs'><center id='NclJs'></center></pre></bdo></b><th id='NclJs'></th></span></q></dt></tr></i><div id='NclJs'><tfoot id='NclJs'></tfoot><dl id='NclJs'><fieldset id='NclJs'></fieldset></dl></div>
                <tbody id='NclJs'></tbody>
                  <tfoot id='NclJs'></tfoot>
                  本文介绍了如何获取主类的 Java 类依赖项列表?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着跟版网的小编来一起学习吧!

                  问题描述

                  有没有办法找到一个java主类的所有类依赖?

                  Is there a way to find all the class dependencies of a java main class?

                  我一直在手动筛选主类的导入及其导入,但后来意识到,因为不必导入同一个包中的类,所以我整理了一个不完整的列表.

                  I have been manually sifting through the imports of the main class and it's imports but then realized that, because one does not have to import classes that are in the same package, I was putting together an incomplete list.

                  我需要一些能够递归地找到依赖关系的东西(可能达到定义的深度).

                  I need something that will find dependencies recursively (perhaps to a defined depth).

                  推荐答案

                  只用 javac 就可以轻松搞定.删除你的类文件,然后编译主类.javac 将递归编译它需要的任何类(前提是您不将包私有类/接口隐藏在奇怪命名的文件中).当然,这不包括任何递归 hack.

                  It can be eaily done with just javac. Delete your class files and then compile the main class. javac will recursively compile any classes it needs (providing you don't hide package private classes/interfaces in strangely named files). Of course, this doesn't cover any recursive hacks.

                  这篇关于如何获取主类的 Java 类依赖项列表?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持跟版网!

                  本站部分内容来源互联网,如果有图片或者内容侵犯了您的权益,请联系我们,我们会在确认后第一时间进行删除!

                  相关文档推荐

                  How to send data to COM PORT using JAVA?(如何使用 JAVA 向 COM PORT 发送数据?)
                  How to make a report page direction to change to quot;rtlquot;?(如何使报表页面方向更改为“rtl?)
                  Use cyrillic .properties file in eclipse project(在 Eclipse 项目中使用西里尔文 .properties 文件)
                  Is there any way to detect an RTL language in Java?(有没有办法在 Java 中检测 RTL 语言?)
                  How to load resource bundle messages from DB in Java?(如何在 Java 中从 DB 加载资源包消息?)
                  How do I change the default locale settings in Java to make them consistent?(如何更改 Java 中的默认语言环境设置以使其保持一致?)
                    • <bdo id='6GZtI'></bdo><ul id='6GZtI'></ul>
                        <tbody id='6GZtI'></tbody>

                      1. <tfoot id='6GZtI'></tfoot>
                      2. <i id='6GZtI'><tr id='6GZtI'><dt id='6GZtI'><q id='6GZtI'><span id='6GZtI'><b id='6GZtI'><form id='6GZtI'><ins id='6GZtI'></ins><ul id='6GZtI'></ul><sub id='6GZtI'></sub></form><legend id='6GZtI'></legend><bdo id='6GZtI'><pre id='6GZtI'><center id='6GZtI'></center></pre></bdo></b><th id='6GZtI'></th></span></q></dt></tr></i><div id='6GZtI'><tfoot id='6GZtI'></tfoot><dl id='6GZtI'><fieldset id='6GZtI'></fieldset></dl></div>

                          <small id='6GZtI'></small><noframes id='6GZtI'>

                            <legend id='6GZtI'><style id='6GZtI'><dir id='6GZtI'><q id='6GZtI'></q></dir></style></legend>