@Test public void embeddedTableOfContents() { HtmlDocumentBuilder builder = mock(HtmlDocumentBuilder.class); SplitOutlineItem item = mock(SplitOutlineItem.class); File htmlOutputFile = mock(File.class); SplittingHtmlDocumentBuilder splittingBuilder = markupToEclipseHelp.createSplittingBuilder(builder, item, htmlOutputFile, ""); assertFalse(splittingBuilder.isEmbeddedTableOfContents()); markupToEclipseHelp.embeddedTableOfContents = true; splittingBuilder = markupToEclipseHelp.createSplittingBuilder(builder, item, htmlOutputFile, ""); assertTrue(splittingBuilder.isEmbeddedTableOfContents()); }
protected SplittingHtmlDocumentBuilder createSplittingBuilder(HtmlDocumentBuilder builder, SplitOutlineItem item, File htmlOutputFile, String relativePath) { SplittingHtmlDocumentBuilder splittingBuilder = new SplittingHtmlDocumentBuilder(); splittingBuilder.setRootBuilder(builder); splittingBuilder.setOutline(item); splittingBuilder.setEmbeddedTableOfContents(embeddedTableOfContents); splittingBuilder.setRootFile(htmlOutputFile); splittingBuilder.setNavigationImages(navigationImages); splittingBuilder .setNavigationImagePath(computeResourcePath(splittingBuilder.getNavigationImagePath(), relativePath)); splittingBuilder.setFormatting(formatOutput); return splittingBuilder; }
MarkupToEclipseHelpMojo extends AbstractMojo { protected SplittingHtmlDocumentBuilder createSplittingBuilder(HtmlDocumentBuilder builder, SplitOutlineItem item, File htmlOutputFile, String relativePath) { SplittingHtmlDocumentBuilder splittingBuilder = new SplittingHtmlDocumentBuilder(); splittingBuilder.setRootBuilder(builder); splittingBuilder.setOutline(item); splittingBuilder.setEmbeddedTableOfContents(embeddedTableOfContents); splittingBuilder.setRootFile(htmlOutputFile); splittingBuilder.setNavigationImages(navigationImages); splittingBuilder .setNavigationImagePath(computeResourcePath(splittingBuilder.getNavigationImagePath(), relativePath)); splittingBuilder.setFormatting(formatOutput); return splittingBuilder; } }
MarkupToEclipseHelpMojo extends AbstractMojo { protected SplittingHtmlDocumentBuilder createSplittingBuilder(HtmlDocumentBuilder builder, SplitOutlineItem item, File htmlOutputFile, String relativePath) { SplittingHtmlDocumentBuilder splittingBuilder = new SplittingHtmlDocumentBuilder(); splittingBuilder.setRootBuilder(builder); splittingBuilder.setOutline(item); splittingBuilder.setEmbeddedTableOfContents(embeddedTableOfContents); splittingBuilder.setRootFile(htmlOutputFile); splittingBuilder.setNavigationImages(navigationImages); splittingBuilder .setNavigationImagePath(computeResourcePath(splittingBuilder.getNavigationImagePath(), relativePath)); splittingBuilder.setFormatting(formatOutput); return splittingBuilder; }  }
MarkupToEclipseHelpMojo extends AbstractMojo { protected SplittingHtmlDocumentBuilder createSplittingBuilder(HtmlDocumentBuilder builder, SplitOutlineItem item, File htmlOutputFile, String relativePath) { SplittingHtmlDocumentBuilder splittingBuilder = new SplittingHtmlDocumentBuilder(); splittingBuilder.setRootBuilder(builder); splittingBuilder.setOutline(item); splittingBuilder.setEmbeddedTableOfContents(embeddedTableOfContents); splittingBuilder.setRootFile(htmlOutputFile); splittingBuilder.setNavigationImages(navigationImages); splittingBuilder .setNavigationImagePath(computeResourcePath(splittingBuilder.getNavigationImagePath(), relativePath)); splittingBuilder.setFormatting(formatOutput); return splittingBuilder; }  void execute(); }
MarkupToEclipseHelpMojo extends AbstractMojo { protected SplittingHtmlDocumentBuilder createSplittingBuilder(HtmlDocumentBuilder builder, SplitOutlineItem item, File htmlOutputFile, String relativePath) { SplittingHtmlDocumentBuilder splittingBuilder = new SplittingHtmlDocumentBuilder(); splittingBuilder.setRootBuilder(builder); splittingBuilder.setOutline(item); splittingBuilder.setEmbeddedTableOfContents(embeddedTableOfContents); splittingBuilder.setRootFile(htmlOutputFile); splittingBuilder.setNavigationImages(navigationImages); splittingBuilder .setNavigationImagePath(computeResourcePath(splittingBuilder.getNavigationImagePath(), relativePath)); splittingBuilder.setFormatting(formatOutput); return splittingBuilder; }  void execute();  }