Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Language IDEs » Java Development Tools (JDT) » Java search, indexing source attached to jar files
Java search, indexing source attached to jar files [message #546739] Wed, 14 July 2010 03:25 Go to next message
Bruce Kelly is currently offline Bruce KellyFriend
Messages: 63
Registered: July 2009
Member
To help us split a single large Eclipse project into multiple smaller
Eclipse projects I have created a classpath container that operates in a
similar fashion to the PDE "External Plug-in Libraries" project.

The custom classpath container attaches a source zip file to each of the jar
files.
Using Java search I can find any Java element except constant fields (static
final fields).
The warning about searching for constants is displayed, but I assumed that
as the source is available there should be no problem.

When I enable tracing of the search processing, I can see that the jar files
from the custom classpath container are indexed, but not the attached
source files.

With tracing enabled I have also seen that when the PDE project is created
the Eclipse SDK source bundles are indexed. So there appears to be some
mechanism to have attached source indexed by the background job. However the
source bundles for locally developed Eclipse plug-ins included in a target
platform are not indexed.

Does anyone know how to have the source files attached to jar files indexed
by the background job?

It would also be good if the PDE project could get all source bundles in a
target indexed, and not just the Eclipse SDK bundles.

Namaste, Bruce
Re: Java search, indexing source attached to jar files [message #547928 is a reply to message #546739] Tue, 20 July 2010 08:24 Go to previous messageGo to next message
Satyam Kandula is currently offline Satyam KandulaFriend
Messages: 444
Registered: July 2009
Senior Member
For jars, the indexing is always done only for the classes-- the sources are not considered. That should be true for even the plugins unless the plugin is a project in your workspace.
Re: Java search, indexing source attached to jar files [message #671911 is a reply to message #547928] Thu, 19 May 2011 10:34 Go to previous messageGo to next message
Swapnil Jain is currently offline Swapnil JainFriend
Messages: 3
Registered: May 2011
Junior Member
Hi

I want to know what eclipse actually does while indexing of the external Jar files.
I mean what it stores during indexing, because even after indexing , if i look for call hierarchy then it opens all the Jar files again and does something.

Please help

Swapnil
Re: Java search, indexing source attached to jar files [message #672169 is a reply to message #671911] Fri, 20 May 2011 07:08 Go to previous messageGo to next message
Satyam Kandula is currently offline Satyam KandulaFriend
Messages: 444
Registered: July 2009
Senior Member
Eclipse just stores all the file names for any reference or declaration names in the indexes. During the search, once the file names are found, it opens the appropriate files, parses the file if necessary and creates a model element.
Re: Java search, indexing source attached to jar files [message #672178 is a reply to message #672169] Fri, 20 May 2011 08:37 Go to previous messageGo to next message
Swapnil Jain is currently offline Swapnil JainFriend
Messages: 3
Registered: May 2011
Junior Member
Then why does it open the JAR files again every time i check the call hierarchy of any method?

[Updated on: Fri, 20 May 2011 08:37]

Report message to a moderator

Re: Java search, indexing source attached to jar files [message #673282 is a reply to message #672178] Mon, 23 May 2011 05:40 Go to previous message
Satyam Kandula is currently offline Satyam KandulaFriend
Messages: 444
Registered: July 2009
Senior Member
I have mentioned that appropriate files are opened during search. By appropriate files, I meant class files that could be in jar files.
Previous Topic:Find Class Dialog
Next Topic:An internal error occurred during: "Processing JSP changes since last activation"
Goto Forum:
  


Current Time: Fri Nov 28 10:13:59 GMT 2014

Powered by FUDForum. Page generated in 0.01749 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software