Interface TreeItemFactory
- All Known Implementing Classes:
FavoritesView.DefaultFavoritesFactory, IndexView.DefaultIndexFactory, TOCView.DefaultTOCFactory
public interface TreeItemFactory
A factory for creating TreeItems. This can be used to reuse the parsers.
-
Method Summary
Modifier and TypeMethodDescriptionCreates a default TreeItem.createItem(String tagName, Hashtable attributes, HelpSet hs, Locale locale) Creates a TreeItem from the given data.Lists all the error messages.Ends parsing.voidparsingStarted(URL source) Starts parsing.voidprocessDOCTYPE(String root, String publicID, String systemID) Processes a DOCTYPE.voidA Processing Instruction.voidreportMessage(String msg, boolean validParse) Reports a parsing error.
-
Method Details
-
parsingStarted
Starts parsing.- Parameters:
source- The URL of the document being parsed.
-
processDOCTYPE
-
processPI
-
createItem
Creates a TreeItem from the given data.- Parameters:
tagName- The name of the tag (for example, treeItem, or tocItem)attributes- A hashtable with all the attributes. Null is a valid value.hs- A HelpSet that provides context.lang- The locale.- Returns:
- A TreeItem.
-
createItem
-
reportMessage
Reports a parsing error.- Parameters:
msg- The message to report.validParse- Whether the result of the parse is still valid.
-
listMessages
Enumeration listMessages()Lists all the error messages. -
parsingEnded
Ends parsing. Last chance to do something to the node. Return null to be sure the result is discarded.
-