Class HtmlBookmarks
java.lang.Object
org.openpdf.toolbox.AbstractTool
org.openpdf.toolbox.plugins.HtmlBookmarks
- All Implemented Interfaces:
ActionListener, EventListener
Allows you to generate an index file in HTML containing Bookmarks to an existing PDF file.
- Since:
- 2.1.1 (imported from itexttoolbox project)
-
Field Summary
Fields inherited from class AbstractTool
arguments, internalFrame, MENU_EXECUTE, MENU_EXECUTE_PRINT, MENU_EXECUTE_PRINT_SILENT, MENU_EXECUTE_SHOW, menuoptions, versionsarray -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprivate static voidRecursive method to write Bookmark titles to the System.out.private static SectionAdds a line with the title and an anchor.protected voidCreates the internal frame.voidexecute()Executes the tool (in most cases this generates a PDF file).protected FileGets the PDF file that should be generated (or null if the output isn't a PDF file).static voidAllows you to generate an index file in HTML containing Bookmarks to an existing PDF file.voidIndicates that the value of an argument has changed.Methods inherited from class AbstractTool
actionPerformed, addVersion, getArguments, getInternalFrame, getMenubar, getUsage, getValue, setArguments, setInternalFrame, setMainArguments, setMenubar
-
Constructor Details
-
HtmlBookmarks
public HtmlBookmarks()Constructs an HtmlBookmarks object.
-
-
Method Details
-
addBookmark
Recursive method to write Bookmark titles to the System.out.- Parameters:
pdf- the path to the PDF filesection- the section to which the bookmarks should be addedbookmark- a Map containing a Bookmark (and possible kids)
-
createBookmark
Adds a line with the title and an anchor.- Parameters:
pdf- the link to the PDF filesection- the section that gets the linebookmark- the bookmark that has the data for the line- Returns:
- a subsection of section
-
main
Allows you to generate an index file in HTML containing Bookmarks to an existing PDF file.- Parameters:
args- String[]
-
createFrame
protected void createFrame()Description copied from class:AbstractToolCreates the internal frame.- Specified by:
createFramein classAbstractTool- See Also:
-
execute
public void execute()Description copied from class:AbstractToolExecutes the tool (in most cases this generates a PDF file).- Specified by:
executein classAbstractTool- See Also:
-
valueHasChanged
Description copied from class:AbstractToolIndicates that the value of an argument has changed.- Specified by:
valueHasChangedin classAbstractTool- Parameters:
arg- StringArgument- See Also:
-
getDestPathPDF
Description copied from class:AbstractToolGets the PDF file that should be generated (or null if the output isn't a PDF file).- Specified by:
getDestPathPDFin classAbstractTool- Returns:
- File
- Throws:
InstantiationException- on error- See Also:
-