Commit 4623076
committed
Add support for infoset dataType member
- Add new setIncludeDataType and getIncludeDataType functions to the
InfosetOutputter API to configure if InfosetOutputters should include
the dataType member when creating infosets. It is left up to specific
InfosetOutputter implementations if an how to represent this member in
their infosets
- The XMLTextInfosetOutputter and ScalaXMLInfosetOutputter are updated
to include the xsi:type attribute when this is enabled. They also
define the "xsi" namespace prefix if not already defined. Other
InfosetOutputters do not currently implement this.
- Update the TDML Runner to enable this flag for all infoset outputters.
The TDML Runner already supports type-aware comparisons when xsi:type
is provided, so enabling this allows all TDML test to use type aware
logic. This means expected infosets no longer need to include xsi:type
when for type-aware comparisons.
- Add new "infosetIncludeDataType", which calls setIncludeDataType if
set. This allows enabling this feature without needing to modify code
to call the new API function
- Fix TDML tests that used an xsi:type value that did not match
the actual value
- Discovered a bug where xs:decimal elements could be output with
scientific notation. This is not legal in XSD so these elements are
now output using .toPlainString
Deprecation/Compatibility
- Previous versions of Daffodil could sometimes use scientific notation
when outputting elements with an xs:decimal type, which XSD does not
allow. Daffodil now always outputs xs:deicmal types using standard
decimal notation without any exponent part.
DAFFODIL-1821 parent deb3f6d commit 4623076
10 files changed
Lines changed: 105 additions & 34 deletions
File tree
- daffodil-core/src/main
- java/org/apache/daffodil/api/infoset
- scala/org/apache/daffodil
- lib/xml
- runtime1
- infoset
- processors
- daffodil-propgen/src/main/resources/org/apache/daffodil/xsd
- daffodil-tdml-processor/src
- main/scala/org/apache/daffodil/processor/tdml
- test/scala/org/apache/daffodil/processor/tdml
- daffodil-test/src/test/resources/org/apache/daffodil/section05/simple_types
Lines changed: 27 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
47 | 47 | | |
48 | 48 | | |
49 | 49 | | |
| 50 | + | |
50 | 51 | | |
51 | 52 | | |
52 | 53 | | |
53 | 54 | | |
| 55 | + | |
54 | 56 | | |
55 | 57 | | |
56 | 58 | | |
57 | 59 | | |
| 60 | + | |
58 | 61 | | |
59 | 62 | | |
60 | 63 | | |
61 | 64 | | |
62 | 65 | | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
63 | 72 | | |
64 | 73 | | |
65 | 74 | | |
| |||
205 | 214 | | |
206 | 215 | | |
207 | 216 | | |
| 217 | + | |
| 218 | + | |
| 219 | + | |
| 220 | + | |
| 221 | + | |
| 222 | + | |
| 223 | + | |
| 224 | + | |
| 225 | + | |
| 226 | + | |
| 227 | + | |
| 228 | + | |
| 229 | + | |
| 230 | + | |
| 231 | + | |
| 232 | + | |
| 233 | + | |
| 234 | + | |
208 | 235 | | |
Lines changed: 10 additions & 10 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
939 | 939 | | |
940 | 940 | | |
941 | 941 | | |
942 | | - | |
943 | | - | |
| 942 | + | |
| 943 | + | |
| 944 | + | |
| 945 | + | |
| 946 | + | |
| 947 | + | |
| 948 | + | |
| 949 | + | |
944 | 950 | | |
945 | 951 | | |
946 | 952 | | |
| |||
965 | 971 | | |
966 | 972 | | |
967 | 973 | | |
968 | | - | |
| 974 | + | |
969 | 975 | | |
970 | | - | |
971 | | - | |
972 | | - | |
973 | | - | |
974 | | - | |
975 | | - | |
976 | | - | |
| 976 | + | |
977 | 977 | | |
978 | 978 | | |
979 | 979 | | |
| |||
Lines changed: 4 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1543 | 1543 | | |
1544 | 1544 | | |
1545 | 1545 | | |
| 1546 | + | |
| 1547 | + | |
| 1548 | + | |
| 1549 | + | |
1546 | 1550 | | |
1547 | 1551 | | |
1548 | 1552 | | |
| |||
Lines changed: 22 additions & 3 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
19 | 19 | | |
20 | 20 | | |
21 | 21 | | |
| 22 | + | |
22 | 23 | | |
| 24 | + | |
23 | 25 | | |
24 | 26 | | |
25 | 27 | | |
| |||
54 | 56 | | |
55 | 57 | | |
56 | 58 | | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
57 | 69 | | |
58 | 70 | | |
59 | 71 | | |
| |||
80 | 92 | | |
81 | 93 | | |
82 | 94 | | |
83 | | - | |
| 95 | + | |
| 96 | + | |
| 97 | + | |
| 98 | + | |
| 99 | + | |
| 100 | + | |
| 101 | + | |
| 102 | + | |
84 | 103 | | |
85 | 104 | | |
86 | 105 | | |
| |||
105 | 124 | | |
106 | 125 | | |
107 | 126 | | |
108 | | - | |
| 127 | + | |
109 | 128 | | |
110 | 129 | | |
111 | 130 | | |
| |||
130 | 149 | | |
131 | 150 | | |
132 | 151 | | |
133 | | - | |
| 152 | + | |
134 | 153 | | |
135 | 154 | | |
136 | 155 | | |
| |||
Lines changed: 15 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
82 | 82 | | |
83 | 83 | | |
84 | 84 | | |
| 85 | + | |
| 86 | + | |
85 | 87 | | |
86 | 88 | | |
87 | 89 | | |
| 90 | + | |
88 | 91 | | |
89 | 92 | | |
90 | 93 | | |
| |||
109 | 112 | | |
110 | 113 | | |
111 | 114 | | |
| 115 | + | |
| 116 | + | |
| 117 | + | |
| 118 | + | |
| 119 | + | |
| 120 | + | |
| 121 | + | |
| 122 | + | |
| 123 | + | |
| 124 | + | |
112 | 125 | | |
113 | 126 | | |
114 | 127 | | |
| |||
223 | 236 | | |
224 | 237 | | |
225 | 238 | | |
| 239 | + | |
226 | 240 | | |
227 | 241 | | |
228 | 242 | | |
| |||
238 | 252 | | |
239 | 253 | | |
240 | 254 | | |
| 255 | + | |
241 | 256 | | |
242 | 257 | | |
243 | 258 | | |
| |||
Lines changed: 5 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
287 | 287 | | |
288 | 288 | | |
289 | 289 | | |
| 290 | + | |
| 291 | + | |
| 292 | + | |
| 293 | + | |
| 294 | + | |
290 | 295 | | |
291 | 296 | | |
292 | 297 | | |
| |||
Lines changed: 8 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
273 | 273 | | |
274 | 274 | | |
275 | 275 | | |
| 276 | + | |
| 277 | + | |
| 278 | + | |
| 279 | + | |
| 280 | + | |
| 281 | + | |
| 282 | + | |
| 283 | + | |
276 | 284 | | |
277 | 285 | | |
278 | 286 | | |
| |||
Lines changed: 5 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
57 | 57 | | |
58 | 58 | | |
59 | 59 | | |
| 60 | + | |
60 | 61 | | |
61 | 62 | | |
62 | 63 | | |
| |||
99 | 100 | | |
100 | 101 | | |
101 | 102 | | |
| 103 | + | |
| 104 | + | |
| 105 | + | |
| 106 | + | |
102 | 107 | | |
103 | 108 | | |
104 | 109 | | |
| |||
Lines changed: 6 additions & 18 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
690 | 690 | | |
691 | 691 | | |
692 | 692 | | |
693 | | - | |
| 693 | + | |
694 | 694 | | |
695 | 695 | | |
696 | 696 | | |
| |||
699 | 699 | | |
700 | 700 | | |
701 | 701 | | |
702 | | - | |
| 702 | + | |
703 | 703 | | |
704 | 704 | | |
705 | 705 | | |
| |||
712 | 712 | | |
713 | 713 | | |
714 | 714 | | |
715 | | - | |
716 | | - | |
717 | | - | |
718 | | - | |
719 | | - | |
720 | | - | |
721 | | - | |
| 715 | + | |
722 | 716 | | |
723 | 717 | | |
724 | 718 | | |
| |||
825 | 819 | | |
826 | 820 | | |
827 | 821 | | |
828 | | - | |
| 822 | + | |
829 | 823 | | |
830 | 824 | | |
831 | 825 | | |
| |||
836 | 830 | | |
837 | 831 | | |
838 | 832 | | |
839 | | - | |
| 833 | + | |
840 | 834 | | |
841 | 835 | | |
842 | 836 | | |
| |||
847 | 841 | | |
848 | 842 | | |
849 | 843 | | |
850 | | - | |
851 | | - | |
852 | | - | |
853 | | - | |
854 | | - | |
855 | | - | |
856 | | - | |
| 844 | + | |
857 | 845 | | |
858 | 846 | | |
859 | 847 | | |
| |||
Lines changed: 3 additions & 3 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
3345 | 3345 | | |
3346 | 3346 | | |
3347 | 3347 | | |
3348 | | - | |
| 3348 | + | |
3349 | 3349 | | |
3350 | 3350 | | |
3351 | 3351 | | |
| |||
3357 | 3357 | | |
3358 | 3358 | | |
3359 | 3359 | | |
3360 | | - | |
| 3360 | + | |
3361 | 3361 | | |
3362 | 3362 | | |
3363 | 3363 | | |
| |||
3369 | 3369 | | |
3370 | 3370 | | |
3371 | 3371 | | |
3372 | | - | |
| 3372 | + | |
3373 | 3373 | | |
3374 | 3374 | | |
3375 | 3375 | | |
| |||
0 commit comments