javax.help
Class IndexView
- Serializable
Navigational View information for an Index
static String | publicIDString - PublicID (known to this XML processor) to the DTD for version 1.0 of the Index
|
static String | publicIDString_V2 - PublicID (known to this XML processor) to the DTD for version 2.0 of the Index
|
IndexView(HelpSet hs, String name, String label, Hashtable params) - Construct an IndexView with some given data.
|
IndexView(HelpSet hs, String name, String label, Locale locale, Hashtable params) - Constructs an IndexView with some given data.
|
Component | createNavigator(HelpModel model) - create a navigator for a given model.
|
DefaultMutableTreeNode | getDataAsTree() - Gets a DefaultMutableTreeNode representing the
information in this view instance.
|
String | getMergeType() - Get the Index navigators mergeType.
|
static DefaultMutableTreeNode | parse(URL url, HelpSet hs, Locale locale, TreeItemFactory factory) - Public method for parsing an Index in a URL.
|
publicIDString
public static final String publicIDString
PublicID (known to this XML processor) to the DTD for version 1.0 of the Index
publicIDString_V2
public static final String publicIDString_V2
PublicID (known to this XML processor) to the DTD for version 2.0 of the Index
IndexView
public IndexView(HelpSet hs,
String name,
String label,
Hashtable params)
Construct an IndexView with some given data. Locale defaults to that
of the HelpSet.
hs
- The HelpSet that provides context informationname
- The name of the Viewlabel
- The label (to show the user) of the Viewparams
- A hashtable providing different key/values for this type.
A null for params is valid.
IndexView
public IndexView(HelpSet hs,
String name,
String label,
Locale locale,
Hashtable params)
Constructs an IndexView with some given data.
hs
- The HelpSet that provides context informationname
- The name of the Viewlabel
- The label (to show the user) of the Viewlocale
- The default locale to interpret the data in this TOC. A
null for locale will be interpreted as the defaultLocale.params
- A Hashtable providing different key/values for this type
A null for params is valid.
createNavigator
public Component createNavigator(HelpModel model)
create a navigator for a given model.
- createNavigator in interface NavigatorView
model
- The HelpModel to create this navigator with. A null model
is valid.
- The appropriate Component for this view.
getDataAsTree
public DefaultMutableTreeNode getDataAsTree()
Gets a DefaultMutableTreeNode representing the
information in this view instance.
The default implementation parses the data in the URL, but a subclass may
override this method and provide a different implemenation. For example,
it may create the tree programatically.
getMergeType
public String getMergeType()
Get the Index navigators mergeType. Overrides getMergeType in NavigatorView
- getMergeType in interface NavigatorView
parse
public static DefaultMutableTreeNode parse(URL url,
HelpSet hs,
Locale locale,
TreeItemFactory factory)
Public method for parsing an Index in a URL.
It returns a DefaultMutableTreeNode and its children
that correspond to the indexitems in the Index. The factory is invoked to create
the TreeItems that are included in the DefaultMutableTreeNode as user
data.
url
- Location of the Index. If null, causes null value to be returned.hs
- The HelpSet context for this Index. Null hs is ignored.locale
- The default locale to interpret the data in this Index. Null
locale is treated as the default locale.factory
- A factory instance that is used to create the IndexItems
- a TreeNode that represents the Index. Returns null if parsing errors
were encountered.