use of org.eclipse.help.internal.search.PluginVersionInfo in project tdi-studio-se by Talend.
the class TalendPaletteSearchIndex method getTalendDocPlugins.
protected PluginVersionInfo getTalendDocPlugins() {
Set<String> totalIds = new HashSet<String>();
IExtensionRegistry registry = Platform.getExtensionRegistry();
IExtensionPoint extensionPoint = registry.getExtensionPoint(TocFileProvider.EXTENSION_POINT_ID_TOC);
IExtension[] extensions = extensionPoint.getExtensions();
for (IExtension extension : extensions) {
try {
totalIds.add(extension.getNamespaceIdentifier());
} catch (InvalidRegistryObjectException e) {
// ignore this extension and move on
}
}
Collection<String> additionalPluginIds = BaseHelpSystem.getLocalSearchManager().getPluginsWithSearchParticipants();
totalIds.addAll(additionalPluginIds);
Iterator<String> idIter = totalIds.iterator();
while (idIter.hasNext()) {
String id = idIter.next();
if (!id.startsWith("org.talend.")) {
idIter.remove();
}
}
return new PluginVersionInfo(INDEXED_CONTRIBUTION_INFO_FILE, totalIds, indexDir, !exists());
}
Aggregations