eclipse 正在进行 DLTK 索引
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/13345011/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me):
StackOverFlow
DLTK Indexing in progress
提问by i-CONICA
Our software which powers our business is nearly 16,000 PHP files long. It's an absolutely vast system. Zend Studio takes literally several hours to run the DLTK indexing.
我们为业务提供动力的软件有将近 16,000 个 PHP 文件。这是一个绝对庞大的系统。Zend Studio 需要几个小时来运行 DLTK 索引。
I can't find an up-to-date response on this, but there must be a way of disabling it, or restricting it to particular directories.
我找不到对此的最新响应,但必须有一种方法可以禁用它,或将其限制在特定目录中。
Also, what exactly is this process doing?
另外,这个过程到底在做什么?
Thanks.
谢谢。
回答by drew010
The DLTK indexing is a feature of Eclipse that indexes information about dynamic languages like PHP or Perl. For PHP, this includes class definitions including their properties and methods, function prototypes, resolves code that is included or required in other files as well as many other things.
DLTK 索引是 Eclipse 的一个特性,它为有关动态语言(如 PHP 或 Perl)的信息编制索引。对于 PHP,这包括类定义,包括它们的属性和方法、函数原型、解析其他文件中包含或需要的代码以及许多其他内容。
Without it, you would lose things like autocompletion for classes and functions defined by your project. It also helps with refactoring so if you rename a function, it can update all the other files that reference that function.
没有它,您将丢失项目定义的类和函数的自动完成等功能。它还有助于重构,因此如果您重命名函数,它可以更新引用该函数的所有其他文件。
It's generally a good thing but I feel your pain and have ran into the same issue a number of times.
这通常是一件好事,但我感觉到你的痛苦,并且多次遇到同样的问题。
You can prevent certain directories from being indexed by right-clicking on the folder you would like to exclude from indexing in your project and selecting Build Path
and then clicking Exclude
. This should prevent it from getting indexed by this process.
您可以通过右键单击要从项目中排除索引的文件夹并选择Build Path
然后单击来防止对某些目录进行索引Exclude
。这应该可以防止它被这个过程索引。
Alternatively, you can pull up the project properties and manage the excluded paths from there:
或者,您可以调出项目属性并从那里管理排除的路径:
回答by dav
In case if you have multiple projects and some of them you are using very rarely you can just close the project (from right click menu): this will prevent doing DLTK indexing on those closed projects.
如果您有多个项目并且其中一些您很少使用,您可以关闭项目(从右键单击菜单):这将阻止对那些关闭的项目进行 DLTK 索引。
Please note, that closing the project does NOT remove it, so if some day you need to access or change some file you can simply re-open it.
请注意,关闭项目并不会删除它,因此如果有一天您需要访问或更改某些文件,您只需重新打开它即可。
回答by AwesomeBobX64
Break out your huge code base into modules and then you can have many smaller projects in Zend Studio, each with much less to index when the dependencies are treated as libraries.
将庞大的代码库分解为模块,然后您可以在 Zend Studio 中拥有许多较小的项目,当依赖项被视为库时,每个项目的索引要少得多。