Skip to content

Commit f03e5f5

Browse files
Adjusting type reference to # hash prefix instead of < > brackets as type would be too close to elements look
1 parent e878c8f commit f03e5f5

File tree

9 files changed

+9936
-9936
lines changed

9 files changed

+9936
-9936
lines changed

generator/schema2template/src/main/java/schema2template/grammar/MSVExpressionVisitorDescendantsAsHTMLString.java

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -258,11 +258,11 @@ public void onData(DataExp exp) {
258258
builder.append(
259259
"<a href=\"https://www.w3.org/TR/xmlschema-2/#"
260260
+ dti.getName()
261-
+ "\">&lt;"
261+
+ "\">#"
262262
+ dti.getName()
263-
+ "&gt;</a>");
263+
+ "</a>");
264264
} else if (exp.name.equals("anyIRI")) {
265-
builder.append("<a href=\"https://www.rfc-editor.org/rfc/rfc3987\">&lt;anyIRI\"&gt;</a>");
265+
builder.append("<a href=\"https://www.rfc-editor.org/rfc/rfc3987\">#anyIRI</a>");
266266
} else if (isPredefinedType(dt)) {
267267
// it's a MSV pre-defined type.
268268
builder.append("<!" + dti.getName() + "!>");
@@ -294,11 +294,11 @@ public void onRef(ReferenceExp exp) {
294294
builder.append(
295295
"<a href=\"https://www.w3.org/TR/xmlschema-2/#"
296296
+ exp.name
297-
+ "\">&lt;"
297+
+ "\">#"
298298
+ exp.name
299-
+ "&gt;</a>");
299+
+ "</a>");
300300
} else if (exp.name.equals("anyIRI")) {
301-
builder.append("<a href=\"https://www.rfc-editor.org/rfc/rfc3987\">&lt;anyIRI&gt;</a>");
301+
builder.append("<a href=\"https://www.rfc-editor.org/rfc/rfc3987\">#anyIRI</a>");
302302
} else {
303303
exp.exp.visit(this);
304304
}
@@ -311,11 +311,11 @@ public void onRef(ReferenceExp exp) {
311311
builder.append(
312312
"<a href=\"https://www.w3.org/TR/xmlschema-2/#"
313313
+ exp.name
314-
+ "\">&lt;"
314+
+ "\">#"
315315
+ exp.name
316-
+ "&gt;</a>");
316+
+ "</a>");
317317
} else if (exp.name.equals("anyIRI")) {
318-
builder.append("<a href=\"https://www.rfc-editor.org/rfc/rfc3987\">&lt;anyIRI&gt;</a>");
318+
builder.append("<a href=\"https://www.rfc-editor.org/rfc/rfc3987\">#anyIRI</a>");
319319
} else {
320320
builder.append("&lt;xsd:ref name=\"" + exp.name + "\"/&gt;");
321321
}

generator/schema2template/src/test/resources/test-reference/odf/generation/odf-reference/odf-package-manifest-1.0/OdfReference.html

Lines changed: 15 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ <h3><a name="element_manifest:algorithm_1">manifest:algorithm Element</a></h3>
5151
</tr>
5252
<tr>
5353
<td class="left">Child Relations</td>
54-
<td class="right">&lt;manifest:algorithm manifest:algorithm-name="<a href="https://www.w3.org/TR/xmlschema-2/#string">&lt;string&gt;</a>" manifest:initialisation-vector="<a href="https://www.w3.org/TR/xmlschema-2/#base64Binary">&lt;base64Binary&gt;</a>" &gt;&nbsp;</td>
54+
<td class="right">&lt;manifest:algorithm manifest:algorithm-name="<a href="https://www.w3.org/TR/xmlschema-2/#string">#string</a>" manifest:initialisation-vector="<a href="https://www.w3.org/TR/xmlschema-2/#base64Binary">#base64Binary</a>" &gt;&nbsp;</td>
5555
</tr>
5656
</table>
5757
<br />
@@ -80,7 +80,7 @@ <h3><a name="element_manifest:encryption-data_1">manifest:encryption-data Elemen
8080
</tr>
8181
<tr>
8282
<td class="left">Child Relations</td>
83-
<td class="right">&lt;manifest:encryption-data manifest:checksum-type="<a href="https://www.w3.org/TR/xmlschema-2/#string">&lt;string&gt;</a>" manifest:checksum="<a href="https://www.w3.org/TR/xmlschema-2/#base64Binary">&lt;base64Binary&gt;</a>" &lt;manifest:algorithm ... &gt;&lt;manifest:key-derivation ... &gt;&gt;&nbsp;</td>
83+
<td class="right">&lt;manifest:encryption-data manifest:checksum-type="<a href="https://www.w3.org/TR/xmlschema-2/#string">#string</a>" manifest:checksum="<a href="https://www.w3.org/TR/xmlschema-2/#base64Binary">#base64Binary</a>" &lt;manifest:algorithm ... &gt;&lt;manifest:key-derivation ... &gt;&gt;&nbsp;</td>
8484
</tr>
8585
</table>
8686
<br />
@@ -109,8 +109,8 @@ <h3><a name="element_manifest:file-entry_1">manifest:file-entry Element</a></h3>
109109
</tr>
110110
<tr>
111111
<td class="left">Child Relations</td>
112-
<td class="right">&lt;manifest:file-entry manifest:full-path="<a href="https://www.w3.org/TR/xmlschema-2/#string">&lt;string&gt;</a>" (manifest:size="<a href="https://www.w3.org/TR/xmlschema-2/#nonNegativeInteger">&lt;nonNegativeInteger&gt;</a>" )?
113-
manifest:media-type="<a href="https://www.w3.org/TR/xmlschema-2/#string">&lt;string&gt;</a>" (&lt;manifest:encryption-data ... &gt;)?
112+
<td class="right">&lt;manifest:file-entry manifest:full-path="<a href="https://www.w3.org/TR/xmlschema-2/#string">#string</a>" (manifest:size="<a href="https://www.w3.org/TR/xmlschema-2/#nonNegativeInteger">#nonNegativeInteger</a>" )?
113+
manifest:media-type="<a href="https://www.w3.org/TR/xmlschema-2/#string">#string</a>" (&lt;manifest:encryption-data ... &gt;)?
114114
&gt;&nbsp;</td>
115115
</tr>
116116
</table>
@@ -139,7 +139,7 @@ <h3><a name="element_manifest:key-derivation_1">manifest:key-derivation Element<
139139
</tr>
140140
<tr>
141141
<td class="left">Child Relations</td>
142-
<td class="right">&lt;manifest:key-derivation manifest:key-derivation-name="<a href="https://www.w3.org/TR/xmlschema-2/#string">&lt;string&gt;</a>" manifest:salt="<a href="https://www.w3.org/TR/xmlschema-2/#base64Binary">&lt;base64Binary&gt;</a>" manifest:iteration-count="<a href="https://www.w3.org/TR/xmlschema-2/#nonNegativeInteger">&lt;nonNegativeInteger&gt;</a>" &gt;&nbsp;</td>
142+
<td class="right">&lt;manifest:key-derivation manifest:key-derivation-name="<a href="https://www.w3.org/TR/xmlschema-2/#string">#string</a>" manifest:salt="<a href="https://www.w3.org/TR/xmlschema-2/#base64Binary">#base64Binary</a>" manifest:iteration-count="<a href="https://www.w3.org/TR/xmlschema-2/#nonNegativeInteger">#nonNegativeInteger</a>" &gt;&nbsp;</td>
143143
</tr>
144144
</table>
145145
<br />
@@ -189,7 +189,7 @@ <h3><a name="attribute_manifest:algorithm-name_1">manifest:algorithm-name Attrib
189189
</tr>
190190
<tr>
191191
<td class="left">RNG Relations</td>
192-
<td class="right">manifest:algorithm-name="<a href="https://www.w3.org/TR/xmlschema-2/#string">&lt;string&gt;</a>" &nbsp;</td>
192+
<td class="right">manifest:algorithm-name="<a href="https://www.w3.org/TR/xmlschema-2/#string">#string</a>" &nbsp;</td>
193193
</tr>
194194
</table>
195195
<br />
@@ -214,7 +214,7 @@ <h3><a name="attribute_manifest:checksum_1">manifest:checksum Attribute</a></h3>
214214
</tr>
215215
<tr>
216216
<td class="left">RNG Relations</td>
217-
<td class="right">manifest:checksum="<a href="https://www.w3.org/TR/xmlschema-2/#base64Binary">&lt;base64Binary&gt;</a>" &nbsp;</td>
217+
<td class="right">manifest:checksum="<a href="https://www.w3.org/TR/xmlschema-2/#base64Binary">#base64Binary</a>" &nbsp;</td>
218218
</tr>
219219
</table>
220220
<br />
@@ -239,7 +239,7 @@ <h3><a name="attribute_manifest:checksum-type_1">manifest:checksum-type Attribut
239239
</tr>
240240
<tr>
241241
<td class="left">RNG Relations</td>
242-
<td class="right">manifest:checksum-type="<a href="https://www.w3.org/TR/xmlschema-2/#string">&lt;string&gt;</a>" &nbsp;</td>
242+
<td class="right">manifest:checksum-type="<a href="https://www.w3.org/TR/xmlschema-2/#string">#string</a>" &nbsp;</td>
243243
</tr>
244244
</table>
245245
<br />
@@ -264,7 +264,7 @@ <h3><a name="attribute_manifest:full-path_1">manifest:full-path Attribute</a></h
264264
</tr>
265265
<tr>
266266
<td class="left">RNG Relations</td>
267-
<td class="right">manifest:full-path="<a href="https://www.w3.org/TR/xmlschema-2/#string">&lt;string&gt;</a>" &nbsp;</td>
267+
<td class="right">manifest:full-path="<a href="https://www.w3.org/TR/xmlschema-2/#string">#string</a>" &nbsp;</td>
268268
</tr>
269269
</table>
270270
<br />
@@ -289,7 +289,7 @@ <h3><a name="attribute_manifest:initialisation-vector_1">manifest:initialisation
289289
</tr>
290290
<tr>
291291
<td class="left">RNG Relations</td>
292-
<td class="right">manifest:initialisation-vector="<a href="https://www.w3.org/TR/xmlschema-2/#base64Binary">&lt;base64Binary&gt;</a>" &nbsp;</td>
292+
<td class="right">manifest:initialisation-vector="<a href="https://www.w3.org/TR/xmlschema-2/#base64Binary">#base64Binary</a>" &nbsp;</td>
293293
</tr>
294294
</table>
295295
<br />
@@ -314,7 +314,7 @@ <h3><a name="attribute_manifest:iteration-count_1">manifest:iteration-count Attr
314314
</tr>
315315
<tr>
316316
<td class="left">RNG Relations</td>
317-
<td class="right">manifest:iteration-count="<a href="https://www.w3.org/TR/xmlschema-2/#nonNegativeInteger">&lt;nonNegativeInteger&gt;</a>" &nbsp;</td>
317+
<td class="right">manifest:iteration-count="<a href="https://www.w3.org/TR/xmlschema-2/#nonNegativeInteger">#nonNegativeInteger</a>" &nbsp;</td>
318318
</tr>
319319
</table>
320320
<br />
@@ -339,7 +339,7 @@ <h3><a name="attribute_manifest:key-derivation-name_1">manifest:key-derivation-n
339339
</tr>
340340
<tr>
341341
<td class="left">RNG Relations</td>
342-
<td class="right">manifest:key-derivation-name="<a href="https://www.w3.org/TR/xmlschema-2/#string">&lt;string&gt;</a>" &nbsp;</td>
342+
<td class="right">manifest:key-derivation-name="<a href="https://www.w3.org/TR/xmlschema-2/#string">#string</a>" &nbsp;</td>
343343
</tr>
344344
</table>
345345
<br />
@@ -364,7 +364,7 @@ <h3><a name="attribute_manifest:media-type_1">manifest:media-type Attribute</a><
364364
</tr>
365365
<tr>
366366
<td class="left">RNG Relations</td>
367-
<td class="right">manifest:media-type="<a href="https://www.w3.org/TR/xmlschema-2/#string">&lt;string&gt;</a>" &nbsp;</td>
367+
<td class="right">manifest:media-type="<a href="https://www.w3.org/TR/xmlschema-2/#string">#string</a>" &nbsp;</td>
368368
</tr>
369369
</table>
370370
<br />
@@ -389,7 +389,7 @@ <h3><a name="attribute_manifest:salt_1">manifest:salt Attribute</a></h3>
389389
</tr>
390390
<tr>
391391
<td class="left">RNG Relations</td>
392-
<td class="right">manifest:salt="<a href="https://www.w3.org/TR/xmlschema-2/#base64Binary">&lt;base64Binary&gt;</a>" &nbsp;</td>
392+
<td class="right">manifest:salt="<a href="https://www.w3.org/TR/xmlschema-2/#base64Binary">#base64Binary</a>" &nbsp;</td>
393393
</tr>
394394
</table>
395395
<br />
@@ -414,7 +414,7 @@ <h3><a name="attribute_manifest:size_1">manifest:size Attribute</a></h3>
414414
</tr>
415415
<tr>
416416
<td class="left">RNG Relations</td>
417-
<td class="right">manifest:size="<a href="https://www.w3.org/TR/xmlschema-2/#nonNegativeInteger">&lt;nonNegativeInteger&gt;</a>" &nbsp;</td>
417+
<td class="right">manifest:size="<a href="https://www.w3.org/TR/xmlschema-2/#nonNegativeInteger">#nonNegativeInteger</a>" &nbsp;</td>
418418
</tr>
419419
</table>
420420
<br />

generator/schema2template/src/test/resources/test-reference/odf/generation/odf-reference/odf-package-manifest-1.1/OdfReference.html

Lines changed: 15 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ <h3><a name="element_manifest:algorithm_1">manifest:algorithm Element</a></h3>
5151
</tr>
5252
<tr>
5353
<td class="left">Child Relations</td>
54-
<td class="right">&lt;manifest:algorithm manifest:algorithm-name="<a href="https://www.w3.org/TR/xmlschema-2/#string">&lt;string&gt;</a>" manifest:initialisation-vector="<a href="https://www.w3.org/TR/xmlschema-2/#base64Binary">&lt;base64Binary&gt;</a>" &gt;&nbsp;</td>
54+
<td class="right">&lt;manifest:algorithm manifest:algorithm-name="<a href="https://www.w3.org/TR/xmlschema-2/#string">#string</a>" manifest:initialisation-vector="<a href="https://www.w3.org/TR/xmlschema-2/#base64Binary">#base64Binary</a>" &gt;&nbsp;</td>
5555
</tr>
5656
</table>
5757
<br />
@@ -80,7 +80,7 @@ <h3><a name="element_manifest:encryption-data_1">manifest:encryption-data Elemen
8080
</tr>
8181
<tr>
8282
<td class="left">Child Relations</td>
83-
<td class="right">&lt;manifest:encryption-data manifest:checksum-type="<a href="https://www.w3.org/TR/xmlschema-2/#string">&lt;string&gt;</a>" manifest:checksum="<a href="https://www.w3.org/TR/xmlschema-2/#base64Binary">&lt;base64Binary&gt;</a>" &lt;manifest:algorithm ... &gt;&lt;manifest:key-derivation ... &gt;&gt;&nbsp;</td>
83+
<td class="right">&lt;manifest:encryption-data manifest:checksum-type="<a href="https://www.w3.org/TR/xmlschema-2/#string">#string</a>" manifest:checksum="<a href="https://www.w3.org/TR/xmlschema-2/#base64Binary">#base64Binary</a>" &lt;manifest:algorithm ... &gt;&lt;manifest:key-derivation ... &gt;&gt;&nbsp;</td>
8484
</tr>
8585
</table>
8686
<br />
@@ -109,8 +109,8 @@ <h3><a name="element_manifest:file-entry_1">manifest:file-entry Element</a></h3>
109109
</tr>
110110
<tr>
111111
<td class="left">Child Relations</td>
112-
<td class="right">&lt;manifest:file-entry manifest:full-path="<a href="https://www.w3.org/TR/xmlschema-2/#string">&lt;string&gt;</a>" (manifest:size="<a href="https://www.w3.org/TR/xmlschema-2/#nonNegativeInteger">&lt;nonNegativeInteger&gt;</a>" )?
113-
manifest:media-type="<a href="https://www.w3.org/TR/xmlschema-2/#string">&lt;string&gt;</a>" (&lt;manifest:encryption-data ... &gt;)?
112+
<td class="right">&lt;manifest:file-entry manifest:full-path="<a href="https://www.w3.org/TR/xmlschema-2/#string">#string</a>" (manifest:size="<a href="https://www.w3.org/TR/xmlschema-2/#nonNegativeInteger">#nonNegativeInteger</a>" )?
113+
manifest:media-type="<a href="https://www.w3.org/TR/xmlschema-2/#string">#string</a>" (&lt;manifest:encryption-data ... &gt;)?
114114
&gt;&nbsp;</td>
115115
</tr>
116116
</table>
@@ -139,7 +139,7 @@ <h3><a name="element_manifest:key-derivation_1">manifest:key-derivation Element<
139139
</tr>
140140
<tr>
141141
<td class="left">Child Relations</td>
142-
<td class="right">&lt;manifest:key-derivation manifest:key-derivation-name="<a href="https://www.w3.org/TR/xmlschema-2/#string">&lt;string&gt;</a>" manifest:salt="<a href="https://www.w3.org/TR/xmlschema-2/#base64Binary">&lt;base64Binary&gt;</a>" manifest:iteration-count="<a href="https://www.w3.org/TR/xmlschema-2/#nonNegativeInteger">&lt;nonNegativeInteger&gt;</a>" &gt;&nbsp;</td>
142+
<td class="right">&lt;manifest:key-derivation manifest:key-derivation-name="<a href="https://www.w3.org/TR/xmlschema-2/#string">#string</a>" manifest:salt="<a href="https://www.w3.org/TR/xmlschema-2/#base64Binary">#base64Binary</a>" manifest:iteration-count="<a href="https://www.w3.org/TR/xmlschema-2/#nonNegativeInteger">#nonNegativeInteger</a>" &gt;&nbsp;</td>
143143
</tr>
144144
</table>
145145
<br />
@@ -189,7 +189,7 @@ <h3><a name="attribute_manifest:algorithm-name_1">manifest:algorithm-name Attrib
189189
</tr>
190190
<tr>
191191
<td class="left">RNG Relations</td>
192-
<td class="right">manifest:algorithm-name="<a href="https://www.w3.org/TR/xmlschema-2/#string">&lt;string&gt;</a>" &nbsp;</td>
192+
<td class="right">manifest:algorithm-name="<a href="https://www.w3.org/TR/xmlschema-2/#string">#string</a>" &nbsp;</td>
193193
</tr>
194194
</table>
195195
<br />
@@ -214,7 +214,7 @@ <h3><a name="attribute_manifest:checksum_1">manifest:checksum Attribute</a></h3>
214214
</tr>
215215
<tr>
216216
<td class="left">RNG Relations</td>
217-
<td class="right">manifest:checksum="<a href="https://www.w3.org/TR/xmlschema-2/#base64Binary">&lt;base64Binary&gt;</a>" &nbsp;</td>
217+
<td class="right">manifest:checksum="<a href="https://www.w3.org/TR/xmlschema-2/#base64Binary">#base64Binary</a>" &nbsp;</td>
218218
</tr>
219219
</table>
220220
<br />
@@ -239,7 +239,7 @@ <h3><a name="attribute_manifest:checksum-type_1">manifest:checksum-type Attribut
239239
</tr>
240240
<tr>
241241
<td class="left">RNG Relations</td>
242-
<td class="right">manifest:checksum-type="<a href="https://www.w3.org/TR/xmlschema-2/#string">&lt;string&gt;</a>" &nbsp;</td>
242+
<td class="right">manifest:checksum-type="<a href="https://www.w3.org/TR/xmlschema-2/#string">#string</a>" &nbsp;</td>
243243
</tr>
244244
</table>
245245
<br />
@@ -264,7 +264,7 @@ <h3><a name="attribute_manifest:full-path_1">manifest:full-path Attribute</a></h
264264
</tr>
265265
<tr>
266266
<td class="left">RNG Relations</td>
267-
<td class="right">manifest:full-path="<a href="https://www.w3.org/TR/xmlschema-2/#string">&lt;string&gt;</a>" &nbsp;</td>
267+
<td class="right">manifest:full-path="<a href="https://www.w3.org/TR/xmlschema-2/#string">#string</a>" &nbsp;</td>
268268
</tr>
269269
</table>
270270
<br />
@@ -289,7 +289,7 @@ <h3><a name="attribute_manifest:initialisation-vector_1">manifest:initialisation
289289
</tr>
290290
<tr>
291291
<td class="left">RNG Relations</td>
292-
<td class="right">manifest:initialisation-vector="<a href="https://www.w3.org/TR/xmlschema-2/#base64Binary">&lt;base64Binary&gt;</a>" &nbsp;</td>
292+
<td class="right">manifest:initialisation-vector="<a href="https://www.w3.org/TR/xmlschema-2/#base64Binary">#base64Binary</a>" &nbsp;</td>
293293
</tr>
294294
</table>
295295
<br />
@@ -314,7 +314,7 @@ <h3><a name="attribute_manifest:iteration-count_1">manifest:iteration-count Attr
314314
</tr>
315315
<tr>
316316
<td class="left">RNG Relations</td>
317-
<td class="right">manifest:iteration-count="<a href="https://www.w3.org/TR/xmlschema-2/#nonNegativeInteger">&lt;nonNegativeInteger&gt;</a>" &nbsp;</td>
317+
<td class="right">manifest:iteration-count="<a href="https://www.w3.org/TR/xmlschema-2/#nonNegativeInteger">#nonNegativeInteger</a>" &nbsp;</td>
318318
</tr>
319319
</table>
320320
<br />
@@ -339,7 +339,7 @@ <h3><a name="attribute_manifest:key-derivation-name_1">manifest:key-derivation-n
339339
</tr>
340340
<tr>
341341
<td class="left">RNG Relations</td>
342-
<td class="right">manifest:key-derivation-name="<a href="https://www.w3.org/TR/xmlschema-2/#string">&lt;string&gt;</a>" &nbsp;</td>
342+
<td class="right">manifest:key-derivation-name="<a href="https://www.w3.org/TR/xmlschema-2/#string">#string</a>" &nbsp;</td>
343343
</tr>
344344
</table>
345345
<br />
@@ -364,7 +364,7 @@ <h3><a name="attribute_manifest:media-type_1">manifest:media-type Attribute</a><
364364
</tr>
365365
<tr>
366366
<td class="left">RNG Relations</td>
367-
<td class="right">manifest:media-type="<a href="https://www.w3.org/TR/xmlschema-2/#string">&lt;string&gt;</a>" &nbsp;</td>
367+
<td class="right">manifest:media-type="<a href="https://www.w3.org/TR/xmlschema-2/#string">#string</a>" &nbsp;</td>
368368
</tr>
369369
</table>
370370
<br />
@@ -389,7 +389,7 @@ <h3><a name="attribute_manifest:salt_1">manifest:salt Attribute</a></h3>
389389
</tr>
390390
<tr>
391391
<td class="left">RNG Relations</td>
392-
<td class="right">manifest:salt="<a href="https://www.w3.org/TR/xmlschema-2/#base64Binary">&lt;base64Binary&gt;</a>" &nbsp;</td>
392+
<td class="right">manifest:salt="<a href="https://www.w3.org/TR/xmlschema-2/#base64Binary">#base64Binary</a>" &nbsp;</td>
393393
</tr>
394394
</table>
395395
<br />
@@ -414,7 +414,7 @@ <h3><a name="attribute_manifest:size_1">manifest:size Attribute</a></h3>
414414
</tr>
415415
<tr>
416416
<td class="left">RNG Relations</td>
417-
<td class="right">manifest:size="<a href="https://www.w3.org/TR/xmlschema-2/#nonNegativeInteger">&lt;nonNegativeInteger&gt;</a>" &nbsp;</td>
417+
<td class="right">manifest:size="<a href="https://www.w3.org/TR/xmlschema-2/#nonNegativeInteger">#nonNegativeInteger</a>" &nbsp;</td>
418418
</tr>
419419
</table>
420420
<br />

0 commit comments

Comments
 (0)