JaCoCo 1.1
JaCoCo XML code coverage report, version 1.1, as JaCoCo’s DTD report.dtd defines it, translated to XML Schema.
Read by pyEDAA.Reports.CodeCoverage.JaCoCo.Document - see JaCoCo XML - for a report naming
the DTD by its public identifier -//JACOCO//DTD Report 1.1//EN.
JaCoCo publishes no XML Schema, only the DTD. The translation keeps the DTD’s elements, attributes, their order and
which are required, and allows no other attribute. Where the DTD’s CDATA holds a number, the attribute has a
numeric type: a count, a line number, a time stamp in milliseconds since the epoch. As the DTD, it allows either groups
or packages in a report or group, and a line without its counts.
Download
JaCoCo-1.1.xsd (4.4 kiB)
Validate a report
xmllint --schema JaCoCo-1.1.xsd --noout jacoco.xml
Source
1<?xml version="1.0" encoding="UTF-8"?>
2<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" elementFormDefault="qualified">
3 <xs:annotation>
4 <xs:documentation>
5 JaCoCo XML code coverage report, version 1.1: a translation of JaCoCo's DTD 'report.dtd' to XML Schema.
6
7 The DTD's public identifier is '-//JACOCO//DTD Report 1.1//EN'. Elements, attributes, their order and which are
8 required follow the DTD; no other attribute is allowed. Where the DTD's CDATA holds a number, the attribute has a
9 numeric type: a count, a line number, a time stamp in milliseconds since the epoch.
10 </xs:documentation>
11 </xs:annotation>
12
13 <xs:simpleType name="CounterType">
14 <xs:restriction base="xs:string">
15 <xs:enumeration value="INSTRUCTION"/>
16 <xs:enumeration value="BRANCH"/>
17 <xs:enumeration value="LINE"/>
18 <xs:enumeration value="COMPLEXITY"/>
19 <xs:enumeration value="METHOD"/>
20 <xs:enumeration value="CLASS"/>
21 </xs:restriction>
22 </xs:simpleType>
23
24 <xs:element name="report">
25 <xs:complexType>
26 <xs:sequence>
27 <xs:element ref="sessioninfo" minOccurs="0" maxOccurs="unbounded"/>
28 <xs:choice>
29 <xs:element ref="group" minOccurs="0" maxOccurs="unbounded"/>
30 <xs:element ref="package" minOccurs="0" maxOccurs="unbounded"/>
31 </xs:choice>
32 <xs:element ref="counter" minOccurs="0" maxOccurs="unbounded"/>
33 </xs:sequence>
34 <xs:attribute name="name" type="xs:string" use="required"/>
35 </xs:complexType>
36 </xs:element>
37
38 <xs:element name="sessioninfo">
39 <xs:complexType>
40 <xs:attribute name="id" type="xs:string" use="required"/>
41 <xs:attribute name="start" type="xs:nonNegativeInteger" use="required"/>
42 <xs:attribute name="dump" type="xs:nonNegativeInteger" use="required"/>
43 </xs:complexType>
44 </xs:element>
45
46 <xs:element name="group">
47 <xs:complexType>
48 <xs:sequence>
49 <xs:choice>
50 <xs:element ref="group" minOccurs="0" maxOccurs="unbounded"/>
51 <xs:element ref="package" minOccurs="0" maxOccurs="unbounded"/>
52 </xs:choice>
53 <xs:element ref="counter" minOccurs="0" maxOccurs="unbounded"/>
54 </xs:sequence>
55 <xs:attribute name="name" type="xs:string" use="required"/>
56 </xs:complexType>
57 </xs:element>
58
59 <xs:element name="package">
60 <xs:complexType>
61 <xs:sequence>
62 <xs:choice minOccurs="0" maxOccurs="unbounded">
63 <xs:element ref="class"/>
64 <xs:element ref="sourcefile"/>
65 </xs:choice>
66 <xs:element ref="counter" minOccurs="0" maxOccurs="unbounded"/>
67 </xs:sequence>
68 <xs:attribute name="name" type="xs:string" use="required"/>
69 </xs:complexType>
70 </xs:element>
71
72 <xs:element name="class">
73 <xs:complexType>
74 <xs:sequence>
75 <xs:element ref="method" minOccurs="0" maxOccurs="unbounded"/>
76 <xs:element ref="counter" minOccurs="0" maxOccurs="unbounded"/>
77 </xs:sequence>
78 <xs:attribute name="name" type="xs:string" use="required"/>
79 <xs:attribute name="sourcefilename" type="xs:string" use="optional"/>
80 </xs:complexType>
81 </xs:element>
82
83 <xs:element name="method">
84 <xs:complexType>
85 <xs:sequence>
86 <xs:element ref="counter" minOccurs="0" maxOccurs="unbounded"/>
87 </xs:sequence>
88 <xs:attribute name="name" type="xs:string" use="required"/>
89 <xs:attribute name="desc" type="xs:string" use="required"/>
90 <xs:attribute name="line" type="xs:positiveInteger" use="optional"/>
91 </xs:complexType>
92 </xs:element>
93
94 <xs:element name="sourcefile">
95 <xs:complexType>
96 <xs:sequence>
97 <xs:element ref="line" minOccurs="0" maxOccurs="unbounded"/>
98 <xs:element ref="counter" minOccurs="0" maxOccurs="unbounded"/>
99 </xs:sequence>
100 <xs:attribute name="name" type="xs:string" use="required"/>
101 </xs:complexType>
102 </xs:element>
103
104 <xs:element name="line">
105 <xs:complexType>
106 <xs:attribute name="nr" type="xs:positiveInteger" use="required"/>
107 <xs:attribute name="mi" type="xs:nonNegativeInteger" use="optional"/>
108 <xs:attribute name="ci" type="xs:nonNegativeInteger" use="optional"/>
109 <xs:attribute name="mb" type="xs:nonNegativeInteger" use="optional"/>
110 <xs:attribute name="cb" type="xs:nonNegativeInteger" use="optional"/>
111 </xs:complexType>
112 </xs:element>
113
114 <xs:element name="counter">
115 <xs:complexType>
116 <xs:attribute name="type" type="CounterType" use="required"/>
117 <xs:attribute name="missed" type="xs:nonNegativeInteger" use="required"/>
118 <xs:attribute name="covered" type="xs:nonNegativeInteger" use="required"/>
119 </xs:complexType>
120 </xs:element>
121</xs:schema>