Follow Techotopia on Twitter

On-line Guides
All Guides
eBook Store
iOS / Android
Linux for Beginners
Office Productivity
Linux Installation
Linux Security
Linux Utilities
Linux Virtualization
Linux Kernel
System/Network Admin
Programming
Scripting Languages
Development Tools
Web Development
GUI Toolkits/Desktop
Databases
Mail Systems
openSolaris
Eclipse Documentation
Techotopia.com
Virtuatopia.com
Answertopia.com

How To Guides
Virtualization
General System Admin
Linux Security
Linux Filesystems
Web Servers
Graphics & Desktop
PC Hardware
Windows
Problem Solutions
Privacy Policy

  




 

 


Eclipse Platform
Release 3.5

org.eclipse.help.search
Class HelpIndexBuilder


java.lang.Object
  extended by 
org.eclipse.help.search.HelpIndexBuilder

public class HelpIndexBuilder
extends Object

Builds a help search index for a plug-in by looking for the org.eclipse.help.toc extensions in the provided manifest file. Search index is only created if index path is specified in the extension. Index will contain data for all the topics listed in all the TOCs declared in the plug-in.

If the index is created for a fragment, the manifest must point at the referenced fragment plug-in, while the destination should be the fragment itself.

Starting from the provided destination directory, index for each locale will be placed in a directory with the following path:

                  destination/nl/country/
                  
                  or
                  
                  destination/nl/country/language/ 
 

The relative directory specified in the index element of the org.eclipse.help.toc extention will be created in each of the locale-specific paths (one per locale).

An instance of HelpIndexBuilder can be cached and used multiple times for different manifest and destination values.

Since:
3.1

Constructor Summary
HelpIndexBuilder ()
          Creates a new instance of the help index builder.
 
Method Summary
 void execute ( IProgressMonitor monitor)
          Creates the plug-in search index by parsing the provided plugin.xml file, looking for TOC extensions.
  File getDestination ()
          Returns the destination directory where index should be created.
  File getManifest ()
          Returns the manifest file for this builder.
 void setDestination ( File destination)
          Sets the destination directory where index should be created.
 void setManifest ( File manifest)
          Sets the new manifest file (plugin.xml) to be used by this builder.
 
Methods inherited from class java.lang. Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

HelpIndexBuilder

public HelpIndexBuilder()
Creates a new instance of the help index builder.

Method Detail

getManifest

public 
File getManifest()
Returns the manifest file for this builder. If the target is a plug-in, it is the absolute path of plugin.xml file. If the target is a fragment, it is the absolute path of plugin.xml of the fragment plug-in.

Returns:
the file that contains TOC extensions

setManifest

public void setManifest(
File manifest)
Sets the new manifest file (plugin.xml) to be used by this builder. If the target is a plug-in, it is the absolute path of plugin.xml file. If the target is a fragment, it is the absolute path of plugin.xml of the fragment plug-in.

Parameters:
manifest - the file that contains TOC extensions

getDestination

public 
File getDestination()
Returns the destination directory where index should be created.

Returns:
the destination index directory

setDestination

public void setDestination(
File destination)
Sets the destination directory where index should be created. Locale-specific directories will be created starting from this directory.

Parameters:
destination - the directory where index should be created

execute

public void execute(
IProgressMonitor monitor)
             throws 
CoreException
Creates the plug-in search index by parsing the provided plugin.xml file, looking for TOC extensions. If at least one of them has index element, all topics listed in all the TOCs in the plug-in will be indexed and stored in the path specified by the index element.

Parameters:
monitor - the monitor to track index creation progress
Throws:
CoreException - if there are problems during index creation.

Eclipse Platform
Release 3.5

Guidelines for using Eclipse APIs.

Copyright (c) Eclipse contributors and others 2000, 2008. All rights reserved.


 
 
  Published under the terms of the Eclipse Public License Version 1.0 ("EPL") Design by Interspire