Class PackagePage
- java.lang.Object
-
- org.jacoco.report.internal.html.page.ReportPage
-
- org.jacoco.report.internal.html.page.NodePage<NodeType>
-
- org.jacoco.report.internal.html.page.TablePage<IPackageCoverage>
-
- org.jacoco.report.internal.html.page.PackagePage
-
- All Implemented Interfaces:
ILinkable,ITableItem
public class PackagePage extends TablePage<IPackageCoverage>
Page showing coverage information for a Java package. The page contains a table with all classes of the package.
-
-
Field Summary
Fields Modifier and Type Field Description private PackageSourcePagepackageSourcePageprivate booleansourceCoverageExists-
Fields inherited from class org.jacoco.report.internal.html.page.ReportPage
context, folder
-
-
Constructor Summary
Constructors Constructor Description PackagePage(IPackageCoverage node, ReportPage parent, ISourceFileLocator locator, ReportOutputFolder folder, IHTMLReportContext context)Creates a new visitor in the given context.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected java.lang.StringgetFileName()Specifies the local file name of this page.java.lang.StringgetLinkLabel()Returns the display label used for the link.protected java.lang.StringgetOnload()Returns the onload handler for this page.protected voidinfoLinks(HTMLElement span)Inserts additional links on the top right corner.voidrender()Renders this page's content and optionally additional pages.private voidrenderClasses()-
Methods inherited from class org.jacoco.report.internal.html.page.NodePage
getLinkStyle, getNode
-
Methods inherited from class org.jacoco.report.internal.html.page.ReportPage
getLink, isRootPage
-
-
-
-
Field Detail
-
packageSourcePage
private final PackageSourcePage packageSourcePage
-
sourceCoverageExists
private final boolean sourceCoverageExists
-
-
Constructor Detail
-
PackagePage
public PackagePage(IPackageCoverage node, ReportPage parent, ISourceFileLocator locator, ReportOutputFolder folder, IHTMLReportContext context)
Creates a new visitor in the given context.- Parameters:
node- coverage data for this packageparent- optional hierarchical parentlocator- source locatorfolder- base folder to create this page incontext- settings context
-
-
Method Detail
-
render
public void render() throws java.io.IOExceptionDescription copied from class:ReportPageRenders this page's content and optionally additional pages. This method must be called at most once.- Overrides:
renderin classReportPage- Throws:
java.io.IOException- if the page can't be written
-
renderClasses
private void renderClasses() throws java.io.IOException- Throws:
java.io.IOException
-
getOnload
protected java.lang.String getOnload()
Description copied from class:ReportPageReturns the onload handler for this page.- Overrides:
getOnloadin classReportPage- Returns:
- handler or
null
-
getFileName
protected java.lang.String getFileName()
Description copied from class:ReportPageSpecifies the local file name of this page.- Specified by:
getFileNamein classReportPage- Returns:
- local file name
-
getLinkLabel
public java.lang.String getLinkLabel()
Description copied from interface:ILinkableReturns the display label used for the link.- Specified by:
getLinkLabelin interfaceILinkable- Overrides:
getLinkLabelin classNodePage<IPackageCoverage>- Returns:
- display label
-
infoLinks
protected void infoLinks(HTMLElement span) throws java.io.IOException
Description copied from class:ReportPageInserts additional links on the top right corner.- Overrides:
infoLinksin classReportPage- Parameters:
span- parent element- Throws:
java.io.IOException- in case of IO problems with the report writer
-
-