Derived Source Search Participants

Identifier:
org.eclipse.jdt.core.derivedSourceSearchParticipant

Since:
3.46

Description:
This extension point allows clients to contribute search participants for non-Java source files that are registered under the org.eclipse.jdt.core.javaDerivedSource content type. When files with the specified extensions are discovered in source folders, JDT Core's indexing pipeline will route them to the registered search participant for indexing. The participant's indexes are also queried during search operations.

Configuration Markup:

<!ELEMENT extension (derivedSourceSearchParticipant*)>

<!ATTLIST extension

point CDATA #REQUIRED

id    CDATA #IMPLIED

name  CDATA #IMPLIED>


<!ELEMENT derivedSourceSearchParticipant EMPTY>

<!ATTLIST derivedSourceSearchParticipant

class          CDATA #REQUIRED

id             CDATA #REQUIRED

fileExtensions CDATA #REQUIRED

languageId     CDATA #IMPLIED>

Definition of a search participant for non-Java source files.



Examples:
Example of a declaration of a derivedSourceSearchParticipant:

<extension
      point="org.eclipse.jdt.core.derivedSourceSearchParticipant">
   <derivedSourceSearchParticipant
         class="co.karellen.jdt.kotlin.search.KotlinSearchParticipant"
         id="co.karellen.jdt.kotlin.derivedSourceSearchParticipant"
         fileExtensions="kt,kts"
         languageId="kotlin">
   </derivedSourceSearchParticipant>
</extension>

API Information:
The contributed class must extend org.eclipse.jdt.core.search.DerivedSourceSearchParticipant. It will be called by JDT Core's IndexManager when files matching the declared extensions are discovered in source folders. The participant is responsible for parsing the file content and calling SearchDocument.addIndexEntry() to populate the search index.

Supplied Implementation:
JDT Core provides the default Java search participant via SearchEngine.getDefaultSearchParticipant(), which handles .java and .class files. This extension point is for additional non-Java languages.


Copyright (c) 2026 Eclipse Foundation and others.
This program and the accompanying materials are made available under the terms of the Eclipse Public License 2.0 which accompanies this distribution, and is available at https://www.eclipse.org/legal/epl-2.0/ SPDX-License-Identifier: EPL-2.0