|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.jacoco.report.internal.xml.XMLElement
org.jacoco.report.internal.html.HTMLElement
public class HTMLElement
A XMLElement with utility methods to create XHTML documents. It
provides methods of HTML tags to avoid magic strings in the generators.
| Field Summary |
|---|
| Fields inherited from class org.jacoco.report.internal.xml.XMLElement |
|---|
writer |
| Constructor Summary | |
|---|---|
HTMLElement(OutputStream output,
String encoding)
Creates a html root element of a XHTML document. |
|
| Method Summary | |
|---|---|
HTMLElement |
a(ILinkable linkable,
ReportOutputFolder base)
Creates a link to the given ILinkable. |
HTMLElement |
a(String hrefattr)
Creates a 'a' element. |
HTMLElement |
a(String hrefattr,
String classattr)
Creates a 'a' element. |
HTMLElement |
body()
Creates a 'body' element. |
HTMLElement |
code()
Creates a 'code' element. |
HTMLElement |
div(String classattr)
Creates a 'div' element. |
HTMLElement |
element(String name)
Creates a new child element for this element. |
HTMLElement |
h1()
Creates a 'h1' element. |
HTMLElement |
head()
Creates a 'head' element. |
void |
img(String srcattr,
int widthattr,
int heightattr,
String titleattr)
Creates a 'img' element. |
HTMLElement |
link(String relattr,
String hrefattr,
String typeattr)
Creates a 'link' element. |
HTMLElement |
meta(String httpequivattr,
String contentattr)
Creates a 'meta' element. |
HTMLElement |
p()
Creates a 'p' element. |
HTMLElement |
pre(String classattr)
Creates a 'pre' element. |
void |
script(String srcattr)
Creates a JavaScript 'script' element. |
HTMLElement |
span()
Creates a 'span' element. |
HTMLElement |
span(String classattr)
Creates a 'span' element. |
HTMLElement |
span(String classattr,
String idattr)
Creates a 'span' element. |
HTMLElement |
table(String classattr)
Creates a 'table' element. |
HTMLElement |
tbody()
Creates a 'tbody' element. |
HTMLElement |
td()
Creates a 'td' element. |
HTMLElement |
td(String classattr)
Creates a 'td' element. |
HTMLElement |
tfoot()
Creates a 'tfoot' element. |
HTMLElement |
thead()
Creates a 'thead' element. |
HTMLElement |
title()
Creates a 'title' element. |
HTMLElement |
tr()
Creates a 'tr' element. |
| Methods inherited from class org.jacoco.report.internal.xml.XMLElement |
|---|
attr, attr, attr, close, text |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public HTMLElement(OutputStream output,
String encoding)
throws IOException
html root element of a XHTML document.
encoding - character encoding used for outputoutput - output stream will be closed if the root element is closed
IOException - in case of problems with the underlying output| Method Detail |
|---|
public HTMLElement element(String name)
throws IOException
XMLElement
element in class XMLElementname - name of the child element
IOException - in case of problems with the underlying output
public HTMLElement head()
throws IOException
IOException - in case of problems with the underlying output
public HTMLElement body()
throws IOException
IOException - in case of problems with the underlying output
public HTMLElement meta(String httpequivattr,
String contentattr)
throws IOException
httpequivattr - value of the http-equiv attributecontentattr - value for the content attribute
IOException - in case of problems with the underlying output
public HTMLElement link(String relattr,
String hrefattr,
String typeattr)
throws IOException
relattr - value of the rel attributehrefattr - value for the href attributetypeattr - value for the type attribute
IOException - in case of problems with the underlying output
public HTMLElement title()
throws IOException
IOException - in case of problems with the underlying output
public HTMLElement h1()
throws IOException
IOException - in case of problems with the underlying output
public HTMLElement p()
throws IOException
IOException - in case of problems with the underlying output
public HTMLElement span()
throws IOException
IOException - in case of problems with the underlying output
public HTMLElement span(String classattr)
throws IOException
classattr - value of the class attribute
IOException - in case of problems with the underlying output
public HTMLElement span(String classattr,
String idattr)
throws IOException
classattr - value of the class attributeidattr - value of the id attribute
IOException - in case of problems with the underlying output
public HTMLElement div(String classattr)
throws IOException
classattr - value of the class attribute
IOException - in case of problems with the underlying output
public HTMLElement code()
throws IOException
IOException - in case of problems with the underlying output
public HTMLElement pre(String classattr)
throws IOException
classattr - value of the class attribute
IOException - in case of problems with the underlying output
public HTMLElement a(String hrefattr)
throws IOException
hrefattr - value of the href attribute
IOException - in case of problems with the underlying output
public HTMLElement a(String hrefattr,
String classattr)
throws IOException
hrefattr - value of the href attributeclassattr - value of the class attribute
IOException - in case of problems with the underlying output
public HTMLElement a(ILinkable linkable,
ReportOutputFolder base)
throws IOException
ILinkable.
linkable - object to link tobase - base folder where the link should be placed
IOException - in case of problems with the underlying output
public HTMLElement table(String classattr)
throws IOException
classattr - value of the class attribute
IOException - in case of problems with the underlying output
public HTMLElement thead()
throws IOException
IOException - in case of problems with the underlying output
public HTMLElement tfoot()
throws IOException
IOException - in case of problems with the underlying output
public HTMLElement tbody()
throws IOException
IOException - in case of problems with the underlying output
public HTMLElement tr()
throws IOException
IOException - in case of problems with the underlying output
public HTMLElement td()
throws IOException
IOException - in case of problems with the underlying output
public HTMLElement td(String classattr)
throws IOException
classattr - value of the class attribute
IOException - in case of problems with the underlying output
public void img(String srcattr,
int widthattr,
int heightattr,
String titleattr)
throws IOException
srcattr - value of the src attributewidthattr - value of the width attributeheightattr - value of the height attributetitleattr - value of the title and alt attribute
IOException - in case of problems with the underlying output
public void script(String srcattr)
throws IOException
srcattr - value of the src attribute
IOException - in case of problems with the underlying output
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||