cqm-validators 3.1.3 → 4.0.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.github/workflows/ci.yml +2 -3
- data/cqm_validators.gemspec +1 -1
- data/lib/cqm_validators/version.rb +1 -1
- data/lib/schematron/qrda/cat_1_r5_3/HL7 QRDA Category I STU 5.3.sch +3836 -0
- data/lib/schematron/qrda/cat_1_r5_3/voc.xml +1191 -0
- data/lib/schematron/qrda/cat_3_r1/HL7 QRDA Category III Release 1.sch +879 -0
- data/lib/schematron/qrda/cat_3_r1/voc.xml +704 -0
- data/lib/validators.rb +19 -0
- metadata +9 -5
@@ -0,0 +1,879 @@
|
|
1
|
+
<?xml version="1.0" encoding="UTF-8"?>
|
2
|
+
<!--
|
3
|
+
HL7 QRDA III Release 1
|
4
|
+
Version 1.0
|
5
|
+
|
6
|
+
THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESSED OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
|
7
|
+
THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
|
8
|
+
IN NO EVENT SHALL ESAC INC., OR ANY OF THEIR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
9
|
+
SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE
|
10
|
+
GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
|
11
|
+
THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
|
12
|
+
ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
13
|
+
|
14
|
+
IMPLEMENTATION GUIDE CONFORMANCE STATEMENTS and SCHEMATRON ASSERTIONS:
|
15
|
+
|
16
|
+
In general, conformance statements are of three main types:
|
17
|
+
|
18
|
+
- SHALL statements imply the conformance adherence is required.
|
19
|
+
SHALL Schematron assertions, when triggered, are considered 'errors'.
|
20
|
+
|
21
|
+
- SHOULD statements imply the conformance adherence is recommended, but not required.
|
22
|
+
SHOULD Schematron assertions, when triggered, are considered 'warnings'.
|
23
|
+
Note about SHOULD Schematron assertions:
|
24
|
+
When a SHOULD conformance statement has cardinality of "zero or one [0..1]", then the corresponding Schematron assertion will only test for
|
25
|
+
the presence of the item (i.e. "count(item) = 1"). If it tested for 0 as well, then the assertion would never trigger because the item is either present
|
26
|
+
(count=1) or it is not (count=0), both of which would be acceptable. By only checking for the item's presence (count=1), Schematron can issue a
|
27
|
+
warning if the item is absent. Similar logic applies for SHOULD conformance statements with cardinality of "zero or more [0..*]" and the Schematron
|
28
|
+
assertion checks for at least one of the item (i.e. "count(item) > 0").
|
29
|
+
|
30
|
+
- MAY statements imply the conformance adherence is truly optional.
|
31
|
+
MAY conformance statements are not enforced in the Schematron.
|
32
|
+
|
33
|
+
Each type of conformance statement has three possible flavors:
|
34
|
+
|
35
|
+
- Simple statements are simply the conformance statement with no further qualifications.
|
36
|
+
For example: "SHALL contain exactly one [1..1] id."
|
37
|
+
|
38
|
+
- Compound statements have additional requirements, represented by one or more "such that" conformance sub-clauses presented beneath the main conformance statement.
|
39
|
+
These are also referred to as "such that" statements.
|
40
|
+
For example: "SHALL contain exactly one[1..] id such that
|
41
|
+
1) SHALL contain exactly one [1..1] root,
|
42
|
+
2) SHALL contain exactly one [1..1] extension."
|
43
|
+
|
44
|
+
Compound statements are implemented in a single Schematron assertion that includes testing for the main conformance and any "such that" sub-clauses.
|
45
|
+
In rare instances, a compound conformance statement sub-clause may itself contain "such that" sub-clauses. In that event, the corresponding single
|
46
|
+
Schematron assertion also includes testing for the "sub-sub-clauses".
|
47
|
+
In the cases where one or more of a compound conformance sub-clauses have simple conformance statements under them, those are enforced as separate Schematron assertions.
|
48
|
+
|
49
|
+
- Guidance conformance statements are those that represent conformance requirements that cannot or need not be implemented in Schematron assertions.
|
50
|
+
For example: "If patient name was not provided at time of admission, then a value of UNK SHALL be used."
|
51
|
+
Guidance conformance statements of any type (SHALL, SHOULD, MAY) are not enforced in the Schematron.
|
52
|
+
|
53
|
+
Examples:
|
54
|
+
|
55
|
+
A) SHALL contain exactly one [1..1] id
|
56
|
+
1) This id SHALL contain exactly one [1..1] @root
|
57
|
+
2) This id SHALL contain exactly one [1..1] @extension
|
58
|
+
i) This id SHALL contain exactly one [1..1] source such that
|
59
|
+
a) SHALL contain exactly one [1..1] @value
|
60
|
+
|
61
|
+
For the above example, the Schematron will have 4 assertions: One for A and one each for A.1, A.2 and A.2.i
|
62
|
+
(where A.2.i is a compound conformance that includes the "such that" A.2.i.a sub-clause in its test.)
|
63
|
+
|
64
|
+
|
65
|
+
B) SHALL contain exactly one [1..1] id such that
|
66
|
+
1) SHALL contain exactly one [1..1] @root
|
67
|
+
2) SHALL contain exactly one [1..1] @extension
|
68
|
+
3) SHALL contain exactly one [1..1] source
|
69
|
+
i) SHALL contain exactly one [1..1] @value
|
70
|
+
|
71
|
+
For the above example, the Schematron will have 2 assertions: One for B (where B is a compound conformance that includes "such that" sub-clauses B.1, B.2, and B.3),
|
72
|
+
and one for B.3.i since it is NOT a such-that clause for B.3.
|
73
|
+
|
74
|
+
C) MAY contain exactly one [1..1] id such that
|
75
|
+
1) SHALL contain exactly one [1..1] @root
|
76
|
+
2) SHALL contain exactly one [1..1] @extension
|
77
|
+
3) SHALL contain exactly one [1..1] source
|
78
|
+
i) If present, source SHALL contain exactly one [1..1] @value
|
79
|
+
|
80
|
+
For the above example, the Schematron will have 1 assertion for C.3.i. C is a MAY "such that" compound conformance statement and the Schematron does not implement any MAY conformances.
|
81
|
+
However, C.3.i is not a "such that" sub-clause. It merits its own Schematron assertion because if an id/source exists (along with
|
82
|
+
id/@root and id/@extension), then it SHALL contain a @value.
|
83
|
+
|
84
|
+
This schematron supports the HL7 QRDA III Release 1 (Normative) IG
|
85
|
+
|
86
|
+
Wed Dec 09 15:04:15 MST 2020
|
87
|
+
-->
|
88
|
+
<sch:schema xmlns:sch="http://purl.oclc.org/dsdl/schematron" xmlns="urn:hl7-org:v3" xmlns:cda="urn:hl7-org:v3" xmlns:sdtc="urn:hl7-org:sdtc" xmlns:svs="urn:ihe:iti:svs:2008" xmlns:voc="http://www.lantanagroup.com/voc" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
|
89
|
+
<sch:ns prefix="voc" uri="http://www.lantanagroup.com/voc" />
|
90
|
+
<sch:ns prefix="svs" uri="urn:ihe:iti:svs:2008" />
|
91
|
+
<sch:ns prefix="xsi" uri="http://www.w3.org/2001/XMLSchema-instance" />
|
92
|
+
<sch:ns prefix="sdtc" uri="urn:hl7-org:sdtc" />
|
93
|
+
<sch:ns prefix="cda" uri="urn:hl7-org:v3" />
|
94
|
+
<sch:phase id="errors">
|
95
|
+
<sch:active pattern="Aggregate_count-pattern-errors" />
|
96
|
+
<sch:active pattern="Continuous_variable_measure_value-pattern-errors" />
|
97
|
+
<sch:active pattern="Ethnicity_supp_data_element-pattern-extension-check" />
|
98
|
+
<sch:active pattern="Ethnicity_supp_data_element-pattern-errors" />
|
99
|
+
<sch:active pattern="Improvement_Activity_Performed_Reference_and_Result-pattern-errors" />
|
100
|
+
<sch:active pattern="Improvement_Activity-pattern-extension-check" />
|
101
|
+
<sch:active pattern="Improvement_Activity-pattern-errors" />
|
102
|
+
<sch:active pattern="Measure_data-pattern-extension-check" />
|
103
|
+
<sch:active pattern="Measure_data-pattern-errors" />
|
104
|
+
<sch:active pattern="Measure_Performed-pattern-errors" />
|
105
|
+
<sch:active pattern="Measure_Reference-pattern-errors" />
|
106
|
+
<sch:active pattern="Measure_Reference_and_Results-pattern-extension-check" />
|
107
|
+
<sch:active pattern="Measure_Reference_and_Results-pattern-errors" />
|
108
|
+
<sch:active pattern="Payer_Supplemental_Data_Element-pattern-extension-check" />
|
109
|
+
<sch:active pattern="Payer_Supplemental_Data_Element-pattern-errors" />
|
110
|
+
<sch:active pattern="Performance_Rate-pattern-extension-check" />
|
111
|
+
<sch:active pattern="Performance_Rate-pattern-errors" />
|
112
|
+
<sch:active pattern="Performance_Rate_for_Proportion_Measure-pattern-extension-check" />
|
113
|
+
<sch:active pattern="Performance_Rate_for_Proportion_Measure-pattern-errors" />
|
114
|
+
<sch:active pattern="Postal_Code_Supplemental_Data_Element_V2-pattern-extension-check" />
|
115
|
+
<sch:active pattern="Postal_Code_Supplemental_Data_Element_V2-pattern-errors" />
|
116
|
+
<sch:active pattern="Promoting_Interoperability_Measure_Performed_Reference_and_Result-pattern-errors" />
|
117
|
+
<sch:active pattern="Promoting_Interoperability_Numerator_Denominator_Type_Measure_Denominator-pattern-errors" />
|
118
|
+
<sch:active pattern="Promoting_Interoperability_Numerator_Denominator_Type_Measure_Numerator-pattern-errors" />
|
119
|
+
<sch:active pattern="Promoting_Interoperability_Numerator_Denominator_Measure_Reference_and_Results-pattern-errors" />
|
120
|
+
<sch:active pattern="Promoting_Interoperability-pattern-extension-check" />
|
121
|
+
<sch:active pattern="Promoting_Interoperability-pattern-errors" />
|
122
|
+
<sch:active pattern="QRDA_Category_III_Measure-pattern-extension-check" />
|
123
|
+
<sch:active pattern="QRDA_Category_III_Measure-pattern-errors" />
|
124
|
+
<sch:active pattern="QRDA_Category_III_Report-pattern-extension-check" />
|
125
|
+
<sch:active pattern="QRDA_Category_III_Report-pattern-errors" />
|
126
|
+
<sch:active pattern="Race_Supplemental_Data_Element-pattern-extension-check" />
|
127
|
+
<sch:active pattern="Race_Supplemental_Data_Element-pattern-errors" />
|
128
|
+
<sch:active pattern="Reporting_Rate_for_Proportion_Measure-pattern-errors" />
|
129
|
+
<sch:active pattern="Reporting_Stratum-pattern-errors" />
|
130
|
+
<sch:active pattern="Sex_Supplemental_Data_Element-pattern-extension-check" />
|
131
|
+
<sch:active pattern="Sex_Supplemental_Data_Element-pattern-errors" />
|
132
|
+
<sch:active pattern="Measure-section-pattern-errors" />
|
133
|
+
<sch:active pattern="Reporting-Parameters-Act-pattern-extension-check" />
|
134
|
+
<sch:active pattern="Reporting-Parameters-Act-pattern-errors" />
|
135
|
+
</sch:phase>
|
136
|
+
<sch:phase id="warnings">
|
137
|
+
<sch:active pattern="Improvement_Activity_Performed_Reference_and_Result-pattern-warnings" />
|
138
|
+
<sch:active pattern="Measure_Reference-pattern-warnings" />
|
139
|
+
<sch:active pattern="Measure_Reference_and_Results-pattern-warnings" />
|
140
|
+
<sch:active pattern="Promoting_Interoperability_Measure_Performed_Reference_and_Result-pattern-warnings" />
|
141
|
+
<sch:active pattern="Promoting_Interoperability_Numerator_Denominator_Measure_Reference_and_Results-pattern-warnings" />
|
142
|
+
<sch:active pattern="QRDA_Category_III_Report-pattern-warnings" />
|
143
|
+
<sch:active pattern="Reporting_Stratum-pattern-warnings" />
|
144
|
+
</sch:phase>
|
145
|
+
<!--
|
146
|
+
ERROR Patterns and Assertions
|
147
|
+
-->
|
148
|
+
<sch:pattern id="Aggregate_count-pattern-errors">
|
149
|
+
<sch:rule id="Aggregate_count-errors" context="cda:observation[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.3']]">
|
150
|
+
<sch:assert id="a-77-17563-error" test="@classCode='OBS'">SHALL contain exactly one [1..1] @classCode="OBS" Observation (CodeSystem: HL7ActClass urn:oid:2.16.840.1.113883.5.6 STATIC) (CONF:77-17563).</sch:assert>
|
151
|
+
<sch:assert id="a-77-17564-error" test="@moodCode='EVN'">SHALL contain exactly one [1..1] @moodCode="EVN" Event (CodeSystem: ActMood urn:oid:2.16.840.1.113883.5.1001 STATIC) (CONF:77-17564).</sch:assert>
|
152
|
+
<sch:assert id="a-77-17565-error" test="count(cda:templateId[@root='2.16.840.1.113883.10.20.27.3.3'][not(@extension)])=1">SHALL contain exactly one [1..1] templateId (CONF:77-17565) such that it SHALL contain exactly one [1..1] @root="2.16.840.1.113883.10.20.27.3.3" (CONF:77-18095).</sch:assert>
|
153
|
+
<sch:assert id="a-77-17566-error" test="count(cda:code)=1">SHALL contain exactly one [1..1] code (CONF:77-17566).</sch:assert>
|
154
|
+
<sch:assert id="a-77-17567-error" test="count(cda:value[@xsi:type='INT'])=1">SHALL contain exactly one [1..1] value with @xsi:type="INT" (CONF:77-17567).</sch:assert>
|
155
|
+
<sch:assert id="a-77-19509-error" test="count(cda:methodCode)=1">SHALL contain exactly one [1..1] methodCode (CONF:77-19509).</sch:assert>
|
156
|
+
</sch:rule>
|
157
|
+
<sch:rule id="Aggregate_count-code-errors" context="cda:observation[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.3']]/cda:code">
|
158
|
+
<sch:assert id="a-77-19508-error" test="@code='MSRAGG'">This code SHALL contain exactly one [1..1] @code="MSRAGG" rate aggregation (CONF:77-19508).</sch:assert>
|
159
|
+
<sch:assert id="a-77-21160-error" test="@codeSystem='2.16.840.1.113883.5.4'">This code SHALL contain exactly one [1..1] @codeSystem="2.16.840.1.113883.5.4" (CodeSystem: ActCode urn:oid:2.16.840.1.113883.5.4) (CONF:77-21160).</sch:assert>
|
160
|
+
</sch:rule>
|
161
|
+
<sch:rule id="Aggregate_count-value-errors" context="cda:observation[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.3']]/cda:value[@xsi:type='INT']">
|
162
|
+
<sch:assert id="a-77-17568-error" test="@value">This value SHALL contain exactly one [1..1] @value (CONF:77-17568).</sch:assert>
|
163
|
+
</sch:rule>
|
164
|
+
<sch:rule id="Aggregate_count-methodCode-errors" context="cda:observation[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.3']]/cda:methodCode">
|
165
|
+
<sch:assert id="a-77-19510-error" test="@code='COUNT'">This methodCode SHALL contain exactly one [1..1] @code="COUNT" Count (CONF:77-19510).</sch:assert>
|
166
|
+
<sch:assert id="a-77-21161-error" test="@codeSystem='2.16.840.1.113883.5.84'">This methodCode SHALL contain exactly one [1..1] @codeSystem="2.16.840.1.113883.5.84" (CodeSystem: ObservationMethod urn:oid:2.16.840.1.113883.5.84) (CONF:77-21161).</sch:assert>
|
167
|
+
</sch:rule>
|
168
|
+
<sch:rule id="Aggregate_count-referenceRange-errors" context="cda:observation[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.3']]/cda:referenceRange">
|
169
|
+
<sch:assert id="a-77-18393-error" test="count(cda:observationRange)=1">The referenceRange, if present, SHALL contain exactly one [1..1] observationRange (CONF:77-18393).</sch:assert>
|
170
|
+
</sch:rule>
|
171
|
+
<sch:rule id="Aggregate_count-referenceRange-observationRange-errors" context="cda:observation[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.3']]/cda:referenceRange/cda:observationRange">
|
172
|
+
<sch:assert id="a-77-18394-error" test="count(cda:value[@xsi:type='INT'])=1">This observationRange SHALL contain exactly one [1..1] value with @xsi:type="INT" (CONF:77-18394).</sch:assert>
|
173
|
+
</sch:rule>
|
174
|
+
</sch:pattern>
|
175
|
+
<sch:pattern id="Continuous_variable_measure_value-pattern-errors">
|
176
|
+
<sch:rule id="Continuous_variable_measure_value-errors" context="cda:observation[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.2']]">
|
177
|
+
<sch:assert id="a-77-17569-error" test="@classCode='OBS'">SHALL contain exactly one [1..1] @classCode="OBS" Observation (CodeSystem: HL7ActClass urn:oid:2.16.840.1.113883.5.6 STATIC) (CONF:77-17569).</sch:assert>
|
178
|
+
<sch:assert id="a-77-17570-error" test="@moodCode='EVN'">SHALL contain exactly one [1..1] @moodCode="EVN" Event (CodeSystem: ActMood urn:oid:2.16.840.1.113883.5.1001 STATIC) (CONF:77-17570).</sch:assert>
|
179
|
+
<sch:assert id="a-77-18096-error" test="count(cda:templateId[@root='2.16.840.1.113883.10.20.27.3.2'][not(@extension)])=1">SHALL contain exactly one [1..1] templateId (CONF:77-18096) such that it SHALL contain exactly one [1..1] @root="2.16.840.1.113883.10.20.27.3.2" (CONF:77-18097).</sch:assert>
|
180
|
+
<sch:assert id="a-77-17571-error" test="count(cda:code)=1">SHALL contain exactly one [1..1] code (CONF:77-17571).</sch:assert>
|
181
|
+
<sch:assert id="a-77-17572-error" test="count(cda:value)=1">SHALL contain exactly one [1..1] value (CONF:77-17572).</sch:assert>
|
182
|
+
<sch:assert id="a-77-18242-error" test="count(cda:methodCode)=1">SHALL contain exactly one [1..1] methodCode, which SHALL be selected from ValueSet ObservationMethodAggregate urn:oid:2.16.840.1.113883.1.11.20450 DYNAMIC (CONF:77-18242).</sch:assert>
|
183
|
+
<sch:assert id="a-77-18243-error" test="count(cda:reference)=1">SHALL contain exactly one [1..1] reference (CONF:77-18243).</sch:assert>
|
184
|
+
</sch:rule>
|
185
|
+
<sch:rule id="Continuous_variable_measure_value-reference-errors" context="cda:observation[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.2']]/cda:reference">
|
186
|
+
<sch:assert id="a-77-18244-error" test="count(cda:externalObservation)=1">This reference SHALL contain exactly one [1..1] externalObservation (CONF:77-18244).</sch:assert>
|
187
|
+
</sch:rule>
|
188
|
+
<sch:rule id="Continuous_variable_measure_value-reference-externalObservation-errors" context="cda:observation[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.2']]/cda:reference/cda:externalObservation">
|
189
|
+
<sch:assert id="a-77-18245-error" test="count(cda:id)=1">This externalObservation SHALL contain exactly one [1..1] id (CONF:77-18245).</sch:assert>
|
190
|
+
</sch:rule>
|
191
|
+
<sch:rule id="Continuous_variable_measure_value-referenceRange-errors" context="cda:observation[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.2']]/cda:referenceRange">
|
192
|
+
<sch:assert id="a-77-18390-error" test="count(cda:observationRange)=1">The referenceRange, if present, SHALL contain exactly one [1..1] observationRange (CONF:77-18390).</sch:assert>
|
193
|
+
</sch:rule>
|
194
|
+
<sch:rule id="Continuous_variable_measure_value-referenceRange-observationRange-errors" context="cda:observation[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.2']]/cda:referenceRange/cda:observationRange">
|
195
|
+
<sch:assert id="a-77-18391-error" test="count(cda:value)=1">This observationRange SHALL contain exactly one [1..1] value (CONF:77-18391).</sch:assert>
|
196
|
+
</sch:rule>
|
197
|
+
</sch:pattern>
|
198
|
+
<sch:pattern id="Ethnicity_supp_data_element-pattern-extension-check">
|
199
|
+
<sch:rule id="Ethnicity_supp_data_element-extension-check" context="cda:observation/cda:templateId[@root='2.16.840.1.113883.10.20.27.3.7']">
|
200
|
+
<sch:assert id="a-3259-18218-extension-error" test="@extension='2016-09-01'">SHALL contain exactly one [1..1] templateId (CONF:3259-18218) such that it SHALL contain exactly one [1..1] @root="2.16.840.1.113883.10.20.27.3.7" (CONF:3259-18219). SHALL contain exactly one [1..1] @extension="2016-09-01" (CONF:3259-21176).</sch:assert>
|
201
|
+
</sch:rule>
|
202
|
+
</sch:pattern>
|
203
|
+
<sch:pattern id="Ethnicity_supp_data_element-pattern-errors">
|
204
|
+
<sch:rule id="Ethnicity_supp_data_element-errors" context="cda:observation[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.7'][@extension='2016-09-01']]">
|
205
|
+
<sch:assert id="a-3259-18216-error" test="@classCode='OBS'">SHALL contain exactly one [1..1] @classCode="OBS" Observation (CodeSystem: HL7ActClass urn:oid:2.16.840.1.113883.5.6 STATIC) (CONF:3259-18216).</sch:assert>
|
206
|
+
<sch:assert id="a-3259-18217-error" test="@moodCode='EVN'">SHALL contain exactly one [1..1] @moodCode="EVN" Event (CodeSystem: ActMood urn:oid:2.16.840.1.113883.5.1001 STATIC) (CONF:3259-18217).</sch:assert>
|
207
|
+
<sch:assert id="a-3259-18218-error" test="count(cda:templateId[@root='2.16.840.1.113883.10.20.27.3.7'][@extension='2016-09-01'])=1">SHALL contain exactly one [1..1] templateId (CONF:3259-18218) such that it SHALL contain exactly one [1..1] @root="2.16.840.1.113883.10.20.27.3.7" (CONF:3259-18219). SHALL contain exactly one [1..1] @extension="2016-09-01" (CONF:3259-21176).</sch:assert>
|
208
|
+
<sch:assert id="a-3259-18220-error" test="count(cda:code)=1">SHALL contain exactly one [1..1] code (CONF:3259-18220).</sch:assert>
|
209
|
+
<sch:assert id="a-3259-18118-error" test="count(cda:statusCode)=1">SHALL contain exactly one [1..1] statusCode (CONF:3259-18118).</sch:assert>
|
210
|
+
<sch:assert id="a-3259-18222-error" test="count(cda:value[@xsi:type='CD'])=1">SHALL contain exactly one [1..1] value with @xsi:type="CD", where the code SHALL be selected from ValueSet Ethnicity urn:oid:2.16.840.1.114222.4.11.837 DYNAMIC (CONF:3259-18222).</sch:assert>
|
211
|
+
<sch:assert id="a-3259-18120-error" test="count(cda:entryRelationship[@typeCode='SUBJ'][@inversionInd='true'][count(cda:observation[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.3']])=1])=1">SHALL contain exactly one [1..1] entryRelationship (CONF:3259-18120) such that it SHALL contain exactly one [1..1] @typeCode="SUBJ" Has Subject (CodeSystem: HL7ActRelationshipType urn:oid:2.16.840.1.113883.5.1002 STATIC) (CONF:3259-18121). SHALL contain exactly one [1..1] @inversionInd="true" (CONF:3259-18122). SHALL contain exactly one [1..1] Aggregate Count (identifier: urn:oid:2.16.840.1.113883.10.20.27.3.3) (CONF:3259-18123).</sch:assert>
|
212
|
+
</sch:rule>
|
213
|
+
<sch:rule id="Ethnicity_supp_data_element-code-errors" context="cda:observation[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.7'][@extension='2016-09-01']]/cda:code">
|
214
|
+
<sch:assert id="a-3259-18221-error" test="@code='69490-1'">This code SHALL contain exactly one [1..1] @code="69490-1" Ethnic (CONF:3259-18221).</sch:assert>
|
215
|
+
<sch:assert id="a-3259-21443-error" test="@codeSystem='2.16.840.1.113883.6.1'">This code SHALL contain exactly one [1..1] @codeSystem="2.16.840.1.113883.6.1" (CodeSystem: LOINC urn:oid:2.16.840.1.113883.6.1) (CONF:3259-21443).</sch:assert>
|
216
|
+
</sch:rule>
|
217
|
+
<sch:rule id="Ethnicity_supp_data_element-statusCode-errors" context="cda:observation[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.7'][@extension='2016-09-01']]/cda:statusCode">
|
218
|
+
<sch:assert id="a-3259-18119-error" test="@code='completed'">This statusCode SHALL contain exactly one [1..1] @code="completed" Completed (CodeSystem: ActStatus urn:oid:2.16.840.1.113883.5.14 STATIC) (CONF:3259-18119).</sch:assert>
|
219
|
+
</sch:rule>
|
220
|
+
</sch:pattern>
|
221
|
+
<sch:pattern id="Improvement_Activity_Performed_Reference_and_Result-pattern-errors">
|
222
|
+
<sch:rule id="Improvement_Activity_Performed_Reference_and_Result-errors" context="cda:organizer[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.33'][@extension='2016-09-01']]">
|
223
|
+
<sch:assert id="a-3259-21434-error" test="@classCode='CLUSTER'">SHALL contain exactly one [1..1] @classCode="CLUSTER" (CodeSystem: HL7ActClass urn:oid:2.16.840.1.113883.5.6 STATIC) (CONF:3259-21434).</sch:assert>
|
224
|
+
<sch:assert id="a-3259-21435-error" test="@moodCode='EVN'">SHALL contain exactly one [1..1] @moodCode="EVN" (CodeSystem: ActMood urn:oid:2.16.840.1.113883.5.1001 STATIC) (CONF:3259-21435).</sch:assert>
|
225
|
+
<sch:assert id="a-3259-21425-error" test="count(cda:templateId[@root='2.16.840.1.113883.10.20.27.3.33'][@extension='2016-09-01'])=1">SHALL contain exactly one [1..1] templateId (CONF:3259-21425) such that it SHALL contain exactly one [1..1] @root="2.16.840.1.113883.10.20.27.3.33" (CONF:3259-21432). SHALL contain exactly one [1..1] @extension="2016-09-01" (CONF:3259-21433).</sch:assert>
|
226
|
+
<sch:assert id="a-3259-21422-error" test="count(cda:reference[@typeCode='REFR'][count(cda:externalDocument[@classCode='DOC'][count(cda:id[@root='2.16.840.1.113883.3.7034'][@extension])=1])=1])=1">SHALL contain exactly one [1..1] reference (CONF:3259-21422) such that it SHALL contain exactly one [1..1] @typeCode="REFR" (CONF:3259-21431). SHALL contain exactly one [1..1] externalDocument (CodeSystem: HL7ActClass urn:oid:2.16.840.1.113883.5.6 STATIC) (CONF:3259-21423). This externalDocument SHALL contain exactly one [1..1] @classCode="DOC" Document (CodeSystem: HL7ActClass urn:oid:2.16.840.1.113883.5.6) (CONF:3259-21430). This externalDocument SHALL contain exactly one [1..1] id (CONF:3259-21424) such that it SHALL contain exactly one [1..1] @root="2.16.840.1.113883.3.7034" (CONF:3259-21427). SHALL contain exactly one [1..1] @extension (CONF:3259-21428).</sch:assert>
|
227
|
+
<sch:assert id="a-3259-21421-error" test="count(cda:component[count(cda:observation[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.27'][@extension='2016-09-01']])=1])=1">SHALL contain exactly one [1..1] component (CONF:3259-21421) such that it SHALL contain exactly one [1..1] Measure Performed (identifier: urn:hl7ii:2.16.840.1.113883.10.20.27.3.27:2016-09-01) (CONF:3259-21426).</sch:assert>
|
228
|
+
</sch:rule>
|
229
|
+
</sch:pattern>
|
230
|
+
<sch:pattern id="Improvement_Activity-pattern-extension-check">
|
231
|
+
<sch:rule id="Improvement_Activity-extension-check" context="cda:section/cda:templateId[@root='2.16.840.1.113883.10.20.27.2.4']">
|
232
|
+
<sch:assert id="a-4484-21175-extension-error" test="@extension='2020-12-01'">SHALL contain exactly one [1..1] templateId (CONF:4484-21175) such that it SHALL contain exactly one [1..1] @root="2.16.840.1.113883.10.20.27.2.4" (CONF:4484-21177). SHALL contain exactly one [1..1] @extension="2020-12-01" (CONF:4484-21398).</sch:assert>
|
233
|
+
</sch:rule>
|
234
|
+
</sch:pattern>
|
235
|
+
<sch:pattern id="Improvement_Activity-pattern-errors">
|
236
|
+
<sch:rule id="Improvement_Activity-errors" context="cda:section[cda:templateId[@root='2.16.840.1.113883.10.20.27.2.4'][@extension='2020-12-01']]">
|
237
|
+
<sch:assert id="a-4484-21175-error" test="count(cda:templateId[@root='2.16.840.1.113883.10.20.27.2.4'][@extension='2020-12-01'])=1">SHALL contain exactly one [1..1] templateId (CONF:4484-21175) such that it SHALL contain exactly one [1..1] @root="2.16.840.1.113883.10.20.27.2.4" (CONF:4484-21177). SHALL contain exactly one [1..1] @extension="2020-12-01" (CONF:4484-21398).</sch:assert>
|
238
|
+
<sch:assert id="a-4484-21181-error" test="count(cda:entry[count(cda:organizer[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.33'][@extension='2016-09-01']])=1]) > 0">SHALL contain at least one [1..*] entry (CONF:4484-21181) such that it SHALL contain exactly one [1..1] Improvement Activity Performed Measure Reference and Results (identifier: urn:hl7ii:2.16.840.1.113883.10.20.27.3.33:2016-09-01) (CONF:4484-21436).</sch:assert>
|
239
|
+
<!-- 11-25-2020 Updated templateID extension -->
|
240
|
+
<sch:assert id="a-4484-26558-error" test="count(cda:entry[cda:act[cda:templateId[@root='2.16.840.1.113883.10.20.17.3.8'][@extension='2020-12-01']]])=1">SHALL contain exactly one [1..1] entry (CONF:4484-26558) such that it SHALL contain exactly one [1..1] Reporting Parameters Act (V2) (identifier: urn:oid:2.16.840.1.113883.10.20.17.3.8:2020-12-01) (CONF:4484-26559).</sch:assert>
|
241
|
+
</sch:rule>
|
242
|
+
</sch:pattern>
|
243
|
+
<sch:pattern id="Measure_data-pattern-extension-check">
|
244
|
+
<sch:rule id="Measure_data-extension-check" context="cda:observation/cda:templateId[@root='2.16.840.1.113883.10.20.27.3.5']">
|
245
|
+
<sch:assert id="a-3259-17912-extension-error" test="@extension='2016-09-01'">SHALL contain exactly one [1..1] templateId (CONF:3259-17912) such that it SHALL contain exactly one [1..1] @root="2.16.840.1.113883.10.20.27.3.5" (CONF:3259-17913). SHALL contain exactly one [1..1] @extension="2016-09-01" (CONF:3259-21161).</sch:assert>
|
246
|
+
</sch:rule>
|
247
|
+
</sch:pattern>
|
248
|
+
<sch:pattern id="Measure_data-pattern-errors">
|
249
|
+
<sch:rule id="Measure_data-errors" context="cda:observation[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.5'][@extension='2016-09-01']]">
|
250
|
+
<sch:assert id="a-3259-17615-error" test="@classCode='OBS'">SHALL contain exactly one [1..1] @classCode="OBS" Observation (CodeSystem: HL7ActClass urn:oid:2.16.840.1.113883.5.6 STATIC) (CONF:3259-17615).</sch:assert>
|
251
|
+
<sch:assert id="a-3259-17616-error" test="@moodCode='EVN'">SHALL contain exactly one [1..1] @moodCode="EVN" Event (CodeSystem: ActMood urn:oid:2.16.840.1.113883.5.1001 STATIC) (CONF:3259-17616).</sch:assert>
|
252
|
+
<sch:assert id="a-3259-17912-error" test="count(cda:templateId[@root='2.16.840.1.113883.10.20.27.3.5'][@extension='2016-09-01'])=1">SHALL contain exactly one [1..1] templateId (CONF:3259-17912) such that it SHALL contain exactly one [1..1] @root="2.16.840.1.113883.10.20.27.3.5" (CONF:3259-17913). SHALL contain exactly one [1..1] @extension="2016-09-01" (CONF:3259-21161).</sch:assert>
|
253
|
+
<sch:assert id="a-3259-17617-error" test="count(cda:code)=1">SHALL contain exactly one [1..1] code (CONF:3259-17617).</sch:assert>
|
254
|
+
<sch:assert id="a-3259-18199-error" test="count(cda:statusCode)=1">SHALL contain exactly one [1..1] statusCode (CodeSystem: ActStatus urn:oid:2.16.840.1.113883.5.14 STATIC) (CONF:3259-18199).</sch:assert>
|
255
|
+
<sch:assert id="a-3259-17618-error" test="count(cda:value[@xsi:type='CD'])=1">SHALL contain exactly one [1..1] value with @xsi:type="CD" (CONF:3259-17618).</sch:assert>
|
256
|
+
<sch:assert id="a-3259-17619-error" test="count(cda:entryRelationship[@typeCode='SUBJ'][@inversionInd='true'][count(cda:observation[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.3']])=1])=1">SHALL contain exactly one [1..1] entryRelationship (CONF:3259-17619) such that it SHALL contain exactly one [1..1] @typeCode="SUBJ" (CONF:3259-17910). SHALL contain exactly one [1..1] @inversionInd="true" (CONF:3259-17911). SHALL contain exactly one [1..1] Aggregate Count (identifier: urn:oid:2.16.840.1.113883.10.20.27.3.3) (CONF:3259-17620).</sch:assert>
|
257
|
+
<sch:assert id="a-3259-18239-error" test="count(cda:reference[count(cda:externalObservation[count(cda:id)=1])=1])=1">SHALL contain exactly one [1..1] reference (CONF:3259-18239) such that it SHALL contain exactly one [1..1] externalObservation (CONF:3259-18240). This externalObservation SHALL contain exactly one [1..1] id (CONF:3259-18241).</sch:assert>
|
258
|
+
</sch:rule>
|
259
|
+
<sch:rule id="Measure_data-code-errors" context="cda:observation[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.5'][@extension='2016-09-01']]/cda:code">
|
260
|
+
<sch:assert id="a-3259-18198-error" test="@code='ASSERTION'">This code SHALL contain exactly one [1..1] @code="ASSERTION" Assertion (CONF:3259-18198).</sch:assert>
|
261
|
+
<sch:assert id="a-3259-21164-error" test="@codeSystem='2.16.840.1.113883.5.4'">This code SHALL contain exactly one [1..1] @codeSystem="2.16.840.1.113883.5.4" (CodeSystem: ActCode urn:oid:2.16.840.1.113883.5.4) (CONF:3259-21164).</sch:assert>
|
262
|
+
</sch:rule>
|
263
|
+
<sch:rule id="Measure_data-statusCode-errors" context="cda:observation[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.5'][@extension='2016-09-01']]/cda:statusCode">
|
264
|
+
<sch:assert id="a-3259-19555-error" test="@code='completed'">This statusCode SHALL contain exactly one [1..1] @code="completed" Completed (CodeSystem: ActStatus urn:oid:2.16.840.1.113883.5.14) (CONF:3259-19555).</sch:assert>
|
265
|
+
</sch:rule>
|
266
|
+
<sch:rule id="Measure_data-value-errors" context="cda:observation[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.5'][@extension='2016-09-01']]/cda:value[@xsi:type='CD']">
|
267
|
+
<sch:assert id="a-3259-21162-error" test="@code">This value SHALL contain exactly one [1..1] @code, which SHOULD be selected from ValueSet PopulationInclusionObservationType urn:oid:2.16.840.1.113883.1.11.20476 DYNAMIC (CONF:3259-21162).</sch:assert>
|
268
|
+
</sch:rule>
|
269
|
+
</sch:pattern>
|
270
|
+
<sch:pattern id="Measure_Performed-pattern-errors">
|
271
|
+
<sch:rule id="Measure_Performed-errors" context="cda:observation[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.27'][@extension='2016-09-01']]">
|
272
|
+
<sch:assert id="a-3259-21221-error" test="@classCode='OBS'">SHALL contain exactly one [1..1] @classCode="OBS" (CodeSystem: HL7ActClass urn:oid:2.16.840.1.113883.5.6 STATIC) (CONF:3259-21221).</sch:assert>
|
273
|
+
<sch:assert id="a-3259-21222-error" test="@moodCode='EVN'">SHALL contain exactly one [1..1] @moodCode="EVN" (CodeSystem: ActMood urn:oid:2.16.840.1.113883.5.1001 STATIC) (CONF:3259-21222).</sch:assert>
|
274
|
+
<sch:assert id="a-3259-21185-error" test="count(cda:templateId[@root='2.16.840.1.113883.10.20.27.3.27'][@extension='2016-09-01'])=1">SHALL contain exactly one [1..1] templateId (CONF:3259-21185) such that it SHALL contain exactly one [1..1] @root="2.16.840.1.113883.10.20.27.3.27" (CONF:3259-21203). SHALL contain exactly one [1..1] @extension="2016-09-01" (CONF:3259-21399).</sch:assert>
|
275
|
+
<sch:assert id="a-3259-21382-error" test="count(cda:code)=1">SHALL contain exactly one [1..1] code (CONF:3259-21382).</sch:assert>
|
276
|
+
<sch:assert id="a-3259-21440-error" test="count(cda:statusCode)=1">SHALL contain exactly one [1..1] statusCode (CodeSystem: ActStatus urn:oid:2.16.840.1.113883.5.14) (CONF:3259-21440).</sch:assert>
|
277
|
+
<sch:assert id="a-3259-21391-error" test="count(cda:value[@xsi:type='CD'])=1">SHALL contain exactly one [1..1] value with @xsi:type="CD", where the code SHALL be selected from ValueSet Yes No Indicator (HL7) urn:oid:2.16.840.1.114222.4.11.819 DYNAMIC (CONF:3259-21391).</sch:assert>
|
278
|
+
</sch:rule>
|
279
|
+
<sch:rule id="Measure_Performed-code-errors" context="cda:observation[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.27'][@extension='2016-09-01']]/cda:code">
|
280
|
+
<sch:assert id="a-3259-21392-error" test="@code='ASSERTION'">This code SHALL contain exactly one [1..1] @code="ASSERTION" Assertion (CONF:3259-21392).</sch:assert>
|
281
|
+
<sch:assert id="a-3259-21393-error" test="@codeSystem='2.16.840.1.113883.5.4'">This code SHALL contain exactly one [1..1] @codeSystem="2.16.840.1.113883.5.4" (CodeSystem: ActCode urn:oid:2.16.840.1.113883.5.4) (CONF:3259-21393).</sch:assert>
|
282
|
+
</sch:rule>
|
283
|
+
<sch:rule id="Measure_Performed-statusCode-errors" context="cda:observation[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.27'][@extension='2016-09-01']]/cda:statusCode">
|
284
|
+
<sch:assert id="a-3259-21442-error" test="@code='completed'">This statusCode SHALL contain exactly one [1..1] @code="completed" Completed (CONF:3259-21442).</sch:assert>
|
285
|
+
</sch:rule>
|
286
|
+
</sch:pattern>
|
287
|
+
<sch:pattern id="Measure_Reference-pattern-errors">
|
288
|
+
<sch:rule id="Measure_Reference-errors" context="cda:organizer[cda:templateId[@root='2.16.840.1.113883.10.20.24.3.98']]">
|
289
|
+
<sch:assert id="a-67-12979-error" test="@classCode='CLUSTER'">SHALL contain exactly one [1..1] @classCode="CLUSTER" cluster (CodeSystem: HL7ActClass urn:oid:2.16.840.1.113883.5.6 STATIC) (CONF:67-12979).</sch:assert>
|
290
|
+
<sch:assert id="a-67-12980-error" test="@moodCode='EVN'">SHALL contain exactly one [1..1] @moodCode="EVN" event (CodeSystem: ActMood urn:oid:2.16.840.1.113883.5.1001 STATIC) (CONF:67-12980).</sch:assert>
|
291
|
+
<sch:assert id="a-67-19532-error" test="count(cda:templateId[@root='2.16.840.1.113883.10.20.24.3.98'][not(@extension)])=1">SHALL contain exactly one [1..1] templateId (CONF:67-19532) such that it SHALL contain exactly one [1..1] @root="2.16.840.1.113883.10.20.24.3.98" (CONF:67-19533).</sch:assert>
|
292
|
+
<sch:assert id="a-67-26992-error" test="count(cda:id)>=1">SHALL contain at least one [1..*] id (CONF:67-26992).</sch:assert>
|
293
|
+
<sch:assert id="a-67-12981-error" test="count(cda:statusCode)=1">SHALL contain exactly one [1..1] statusCode (CodeSystem: HL7ActStatus urn:oid:2.16.840.1.113883.5.14) (CONF:67-12981).</sch:assert>
|
294
|
+
<sch:assert id="a-67-12982-error" test="count(cda:reference[@typeCode='REFR'][count(cda:externalDocument[@classCode='DOC'] [count(cda:id[@root])>=1])=1])=1">SHALL contain exactly one [1..1] reference (CONF:67-12982) such that it SHALL contain exactly one [1..1] @typeCode="REFR" refers to (CodeSystem: HL7ActRelationshipType urn:oid:2.16.840.1.113883.5.1002 STATIC) (CONF:67-12983). SHALL contain exactly one [1..1] externalDocument (CONF:67-12984). This externalDocument SHALL contain exactly one [1..1] @classCode="DOC" Document (CodeSystem: HL7ActClass urn:oid:2.16.840.1.113883.5.6) (CONF:67-19534). This externalDocument SHALL contain at least one [1..*] id (CONF:67-12985) such that it SHALL contain exactly one [1..1] @root (CONF:67-12986)</sch:assert>
|
295
|
+
</sch:rule>
|
296
|
+
<sch:rule id="Measure_Reference-statusCode-errors" context="cda:organizer[cda:templateId[@root='2.16.840.1.113883.10.20.24.3.98']]/cda:statusCode">
|
297
|
+
<sch:assert id="a-67-27020-error" test="@code='completed'">This statusCode SHALL contain exactly one [1..1] @code="completed" (CodeSystem: HL7ActStatus urn:oid:2.16.840.1.113883.5.14) (CONF:67-27020).</sch:assert>
|
298
|
+
</sch:rule>
|
299
|
+
</sch:pattern>
|
300
|
+
<sch:pattern id="Measure_Reference_and_Results-pattern-extension-check">
|
301
|
+
<sch:rule id="Measure_Reference_and_Results-extension-check" context="cda:organizer/cda:templateId[@root='2.16.840.1.113883.10.20.27.3.1']">
|
302
|
+
<sch:assert id="a-4484-17908-extension-error" test="@extension='2020-12-01'">SHALL contain exactly one [1..1] templateId (CONF:4484-17908) such that it SHALL contain exactly one [1..1] @root="2.16.840.1.113883.10.20.27.3.1" (CONF:4484-17909). SHALL contain exactly one [1..1] @extension="2020-12-01" (CONF:4484-21170).</sch:assert>
|
303
|
+
</sch:rule>
|
304
|
+
</sch:pattern>
|
305
|
+
<sch:pattern id="Measure_Reference_and_Results-pattern-errors">
|
306
|
+
<sch:rule id="Measure_Reference_and_Results-errors" context="cda:organizer[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.1'][@extension='2020-12-01']]">
|
307
|
+
<sch:assert id="a-4484-17887-error" test="@classCode='CLUSTER'">SHALL contain exactly one [1..1] @classCode="CLUSTER" (CodeSystem: HL7ActClass urn:oid:2.16.840.1.113883.5.6 STATIC) (CONF:4484-17887).</sch:assert>
|
308
|
+
<sch:assert id="a-4484-17888-error" test="@moodCode='EVN'">SHALL contain exactly one [1..1] @moodCode="EVN" (CodeSystem: ActMood urn:oid:2.16.840.1.113883.5.1001 STATIC) (CONF:4484-17888).</sch:assert>
|
309
|
+
<sch:assert id="a-4484-17908-error" test="count(cda:templateId[@root='2.16.840.1.113883.10.20.27.3.1'][@extension='2020-12-01'])=1">SHALL contain exactly one [1..1] templateId (CONF:4484-17908) such that it SHALL contain exactly one [1..1] @root="2.16.840.1.113883.10.20.27.3.1" (CONF:4484-17909). SHALL contain exactly one [1..1] @extension="2020-12-01" (CONF:4484-21170).</sch:assert>
|
310
|
+
<sch:assert id="a-4484-17890-error" test="count(cda:reference[@typeCode='REFR'][count(cda:externalDocument)=1])=1">SHALL contain exactly one [1..1] reference (CONF:4484-17890) such that it SHALL contain exactly one [1..1] @typeCode="REFR" (CONF:4484-17891). SHALL contain exactly one [1..1] externalDocument (CodeSystem: HL7ActClass urn:oid:2.16.840.1.113883.5.6 STATIC) (CONF:4484-17892).</sch:assert>
|
311
|
+
<sch:assert id="a-4484-18425-error" test="count(cda:component[count(cda:observation[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.5'][@extension='2016-09-01']])=1]) > 0">SHALL contain at least one [1..*] component (CONF:4484-18425) such that it SHALL contain exactly one [1..1] Measure Data (V3) (identifier: urn:hl7ii:2.16.840.1.113883.10.20.27.3.5:2016-09-01) (CONF:4484-18426).</sch:assert>
|
312
|
+
</sch:rule>
|
313
|
+
<sch:rule id="Measure_Reference_and_Results-reference-externalDocument-errors" context="cda:organizer[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.1'][@extension='2020-12-01']]/cda:reference[@typeCode='REFR']/cda:externalDocument">
|
314
|
+
<sch:assert id="a-4484-19548-error" test="@classCode='DOC'">This externalDocument SHALL contain exactly one [1..1] @classCode="DOC" Document (CodeSystem: HL7ActClass urn:oid:2.16.840.1.113883.5.6) (CONF:4484-19548).</sch:assert>
|
315
|
+
<sch:assert id="a-4484-18192-error" test="count(cda:id[@root='2.16.840.1.113883.4.738'][@extension])=1">This externalDocument SHALL contain exactly one [1..1] id (CONF:4484-18192) such that it SHALL contain exactly one [1..1] @root="2.16.840.1.113883.4.738" (CONF:4484-18193). SHALL contain exactly one [1..1] @extension (CONF:4484-21169).</sch:assert>
|
316
|
+
</sch:rule>
|
317
|
+
<sch:rule id="Measure_Reference_and_Results-reference-externalDocument-code-errors" context="cda:organizer[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.1'][@extension='2020-12-01']]/cda:reference/cda:externalDocument/cda:code">
|
318
|
+
<sch:assert id="a-4484-19553-error" test="@code='57024-2'">The code, if present, SHALL contain exactly one [1..1] @code="57024-2" Health Quality Measure Document (CodeSystem: LOINC urn:oid:2.16.840.1.113883.6.1) (CONF:4484-19553).</sch:assert>
|
319
|
+
</sch:rule>
|
320
|
+
<sch:rule id="Measure_Reference_and_Results-reference-externalObservation-errors" context="cda:organizer[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.1'][@extension='2020-12-01']]/cda:reference/cda:externalObservation">
|
321
|
+
<sch:assert id="a-4484-18355-error" test="count(cda:id) > 0">This externalObservation SHALL contain at least one [1..*] id (CONF:4484-18355).</sch:assert>
|
322
|
+
<sch:assert id="a-4484-18357-error" test="count(cda:code)=1">This externalObservation SHALL contain exactly one [1..1] code (CodeSystem: LOINC urn:oid:2.16.840.1.113883.6.1 STATIC) (CONF:4484-18357).</sch:assert>
|
323
|
+
<sch:assert id="a-4484-18358-error" test="count(cda:text)=1">This externalObservation SHALL contain exactly one [1..1] text (CONF:4484-18358).</sch:assert>
|
324
|
+
</sch:rule>
|
325
|
+
<sch:rule id="Measure_Reference_and_Results-reference-externalObservation-code-errors" context="cda:organizer[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.1'][@extension='2020-12-01']]/cda:reference/cda:externalObservation/cda:code">
|
326
|
+
<sch:assert id="a-4484-19554-error" test="@code='55185-3'">This code SHALL contain exactly one [1..1] @code="55185-3" measure set (CodeSystem: LOINC urn:oid:2.16.840.1.113883.6.1) (CONF:4484-19554).</sch:assert>
|
327
|
+
</sch:rule>
|
328
|
+
</sch:pattern>
|
329
|
+
<sch:pattern id="Payer_Supplemental_Data_Element-pattern-extension-check">
|
330
|
+
<sch:rule id="Payer_Supplemental_Data_Element-extension-check" context="cda:observation/cda:templateId[@root='2.16.840.1.113883.10.20.27.3.9']">
|
331
|
+
<sch:assert id="a-2226-18237-extension-error" test="@extension='2016-02-01'">SHALL contain exactly one [1..1] templateId (CONF:2226-18237) such that it SHALL contain exactly one [1..1] @root="2.16.840.1.113883.10.20.27.3.9" (CONF:2226-18238). SHALL contain exactly one [1..1] @extension="2016-02-01" (CONF:2226-21157).</sch:assert>
|
332
|
+
</sch:rule>
|
333
|
+
</sch:pattern>
|
334
|
+
<sch:pattern id="Payer_Supplemental_Data_Element-pattern-errors">
|
335
|
+
<sch:rule id="Payer_Supplemental_Data_Element-errors" context="cda:observation[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.9'][@extension='2016-02-01']]">
|
336
|
+
<sch:assert id="a-2226-21155-error" test="@classCode='OBS'">SHALL contain exactly one [1..1] @classCode="OBS" (CodeSystem: HL7ActClass urn:oid:2.16.840.1.113883.5.6 STATIC) (CONF:2226-21155).</sch:assert>
|
337
|
+
<sch:assert id="a-2226-21156-error" test="@moodCode='EVN'">SHALL contain exactly one [1..1] @moodCode="EVN" (CodeSystem: ActMood urn:oid:2.16.840.1.113883.5.1001 STATIC) (CONF:2226-21156).</sch:assert>
|
338
|
+
<sch:assert id="a-2226-18237-error" test="count(cda:templateId[@root='2.16.840.1.113883.10.20.27.3.9'][@extension='2016-02-01'])=1">SHALL contain exactly one [1..1] templateId (CONF:2226-18237) such that it SHALL contain exactly one [1..1] @root="2.16.840.1.113883.10.20.27.3.9" (CONF:2226-18238). SHALL contain exactly one [1..1] @extension="2016-02-01" (CONF:2226-21157).</sch:assert>
|
339
|
+
<sch:assert id="a-2226-21158-error" test="count(cda:code)=1">SHALL contain exactly one [1..1] code (CONF:2226-21158).</sch:assert>
|
340
|
+
<sch:assert id="a-2226-18106-error" test="count(cda:statusCode)=1">SHALL contain exactly one [1..1] statusCode (CONF:2226-18106).</sch:assert>
|
341
|
+
<sch:assert id="a-2226-18250-error" test="count(cda:value[@xsi:type='CD'])=1">SHALL contain exactly one [1..1] value with @xsi:type="CD", where the code SHOULD be selected from ValueSet Payer urn:oid:2.16.840.1.114222.4.11.3591 DYNAMIC (CONF:2226-18250).</sch:assert>
|
342
|
+
<sch:assert id="a-2226-18108-error" test="count(cda:entryRelationship[@typeCode='SUBJ'][@inversionInd='true'][count(cda:observation[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.3']])=1])=1">SHALL contain exactly one [1..1] entryRelationship (CONF:2226-18108) such that it SHALL contain exactly one [1..1] Aggregate Count (identifier: urn:oid:2.16.840.1.113883.10.20.27.3.3) (CONF:2226-18111). SHALL contain exactly one [1..1] @typeCode="SUBJ" Has Subject (CodeSystem: HL7ActRelationshipType urn:oid:2.16.840.1.113883.5.1002 STATIC) (CONF:2226-18109). SHALL contain exactly one [1..1] @inversionInd="true" (CONF:2226-18110).</sch:assert>
|
343
|
+
</sch:rule>
|
344
|
+
<sch:rule id="Payer_Supplemental_Data_Element-code-errors" context="cda:observation[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.9'][@extension='2016-02-01']]/cda:code">
|
345
|
+
<sch:assert id="a-2226-21159-error" test="@code='48768-6'">This code SHALL contain exactly one [1..1] @code="48768-6" Payment source (CONF:2226-21159).</sch:assert>
|
346
|
+
<sch:assert id="a-2226-21165-error" test="@codeSystem='2.16.840.1.113883.6.1'">This code SHALL contain exactly one [1..1] @codeSystem="2.16.840.1.113883.6.1" (CodeSystem: LOINC urn:oid:2.16.840.1.113883.6.1) (CONF:2226-21165).</sch:assert>
|
347
|
+
</sch:rule>
|
348
|
+
<sch:rule id="Payer_Supplemental_Data_Element-statusCode-errors" context="cda:observation[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.9'][@extension='2016-02-01']]/cda:statusCode">
|
349
|
+
<sch:assert id="a-2226-18107-error" test="@code='completed'">This statusCode SHALL contain exactly one [1..1] @code="completed" Completed (CodeSystem: ActStatus urn:oid:2.16.840.1.113883.5.14 STATIC) (CONF:2226-18107).</sch:assert>
|
350
|
+
</sch:rule>
|
351
|
+
</sch:pattern>
|
352
|
+
<sch:pattern id="Performance_Rate-pattern-extension-check">
|
353
|
+
<sch:rule id="Performance_Rate-extension-check" context="cda:observation/cda:templateId[@root='2.16.840.1.113883.10.20.27.3.30']">
|
354
|
+
<sch:assert id="a-3259-21298-extension-error" test="@extension='2016-09-01'">SHALL contain exactly one [1..1] templateId (CONF:3259-21298) such that it SHALL contain exactly one [1..1] @root="2.16.840.1.113883.10.20.27.3.30" (CONF:3259-21310). SHALL contain exactly one [1..1] @extension="2016-09-01" (CONF:3259-21441).</sch:assert>
|
355
|
+
</sch:rule>
|
356
|
+
</sch:pattern>
|
357
|
+
<sch:pattern id="Performance_Rate-pattern-errors">
|
358
|
+
<sch:rule id="Performance_Rate-errors" context="cda:observation[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.30'][@extension='2016-09-01']]">
|
359
|
+
<sch:assert id="a-3259-21303-error" test="@classCode='OBS'">SHALL contain exactly one [1..1] @classCode="OBS" Observation (CodeSystem: HL7ActClass urn:oid:2.16.840.1.113883.5.6 STATIC) (CONF:3259-21303).</sch:assert>
|
360
|
+
<sch:assert id="a-3259-21304-error" test="@moodCode='EVN'">SHALL contain exactly one [1..1] @moodCode="EVN" Event (CodeSystem: ActMood urn:oid:2.16.840.1.113883.5.1001 STATIC) (CONF:3259-21304).</sch:assert>
|
361
|
+
<sch:assert id="a-3259-21298-error" test="count(cda:templateId[@root='2.16.840.1.113883.10.20.27.3.30'][@extension='2016-09-01'])=1">SHALL contain exactly one [1..1] templateId (CONF:3259-21298) such that it SHALL contain exactly one [1..1] @root="2.16.840.1.113883.10.20.27.3.30" (CONF:3259-21310). SHALL contain exactly one [1..1] @extension="2016-09-01" (CONF:3259-21441).</sch:assert>
|
362
|
+
<sch:assert id="a-3259-21294-error" test="count(cda:code)=1">SHALL contain exactly one [1..1] code (CONF:3259-21294).</sch:assert>
|
363
|
+
<sch:assert id="a-3259-21297-error" test="count(cda:statusCode)=1">SHALL contain exactly one [1..1] statusCode (CONF:3259-21297).</sch:assert>
|
364
|
+
<sch:assert id="a-3259-21307-error" test="count(cda:value[@xsi:type='REAL'])=1">SHALL contain exactly one [1..1] value with @xsi:type="REAL" (CONF:3259-21307).</sch:assert>
|
365
|
+
</sch:rule>
|
366
|
+
<sch:rule id="Performance_Rate-code-errors" context="cda:observation[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.30'][@extension='2016-09-01']]/cda:code">
|
367
|
+
<sch:assert id="a-3259-21305-error" test="@code='72510-1'">This code SHALL contain exactly one [1..1] @code="72510-1" Performance Rate (CONF:3259-21305).</sch:assert>
|
368
|
+
<sch:assert id="a-3259-21306-error" test="@codeSystem='2.16.840.1.113883.6.1'">This code SHALL contain exactly one [1..1] @codeSystem="2.16.840.1.113883.6.1" (CodeSystem: LOINC urn:oid:2.16.840.1.113883.6.1) (CONF:3259-21306).</sch:assert>
|
369
|
+
</sch:rule>
|
370
|
+
<sch:rule id="Performance_Rate-statusCode-errors" context="cda:observation[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.30'][@extension='2016-09-01']]/cda:statusCode">
|
371
|
+
<sch:assert id="a-3259-21309-error" test="@code='completed'">This statusCode SHALL contain exactly one [1..1] @code="completed" completed (CodeSystem: ActStatus urn:oid:2.16.840.1.113883.5.14 STATIC) (CONF:3259-21309).</sch:assert>
|
372
|
+
</sch:rule>
|
373
|
+
</sch:pattern>
|
374
|
+
<sch:pattern id="Performance_Rate_for_Proportion_Measure-pattern-extension-check">
|
375
|
+
<sch:rule id="Performance_Rate_for_Proportion_Measure-extension-check" context="cda:observation/cda:templateId[@root='2.16.840.1.113883.10.20.27.3.14']">
|
376
|
+
<sch:assert id="a-4484-19649-extension-error" test="@extension='2020-12-01'">SHALL contain exactly one [1..1] templateId (CONF:4484-19649) such that it SHALL contain exactly one [1..1] @root="2.16.840.1.113883.10.20.27.3.14" (CONF:4484-19650). SHALL contain exactly one [1..1] @extension="2020-12-01" (CONF:4484-21444).</sch:assert>
|
377
|
+
</sch:rule>
|
378
|
+
</sch:pattern>
|
379
|
+
<sch:pattern id="Performance_Rate_for_Proportion_Measure-pattern-errors">
|
380
|
+
<sch:rule id="Performance_Rate_for_Proportion_Measure-errors" context="cda:observation[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.14'][@extension='2020-12-01']]">
|
381
|
+
<sch:assert id="a-4484-18395-error" test="@classCode='OBS'">SHALL contain exactly one [1..1] @classCode="OBS" Observation (CodeSystem: HL7ActClass urn:oid:2.16.840.1.113883.5.6 STATIC) (CONF:4484-18395).</sch:assert>
|
382
|
+
<sch:assert id="a-4484-18396-error" test="@moodCode='EVN'">SHALL contain exactly one [1..1] @moodCode="EVN" Event (CodeSystem: ActMood urn:oid:2.16.840.1.113883.5.1001 STATIC) (CONF:4484-18396).</sch:assert>
|
383
|
+
<sch:assert id="a-4484-19649-error" test="count(cda:templateId[@root='2.16.840.1.113883.10.20.27.3.14'][@extension='2020-12-01'])=1">SHALL contain exactly one [1..1] templateId (CONF:4484-19649) such that it SHALL contain exactly one [1..1] @root="2.16.840.1.113883.10.20.27.3.14" (CONF:4484-19650). SHALL contain exactly one [1..1] @extension="2020-12-01" (CONF:4484-21444).</sch:assert>
|
384
|
+
<!-- 12-01-2020 Added type requirement -->
|
385
|
+
<sch:assert id="a-4484-21445-error" test="count(cda:value[@xsi:type='REAL'])=1">SHALL contain exactly one [1..1] value with @xsi:type="REAL" (CONF:4484-21445).</sch:assert>
|
386
|
+
<!-- 12-01-2020 Made reference a requirement -->
|
387
|
+
<sch:assert id="a-4484-19651-error" test="count(cda:reference)=1">SHALL contain exactly one [1..1] reference (CONF:4484-19651).</sch:assert>
|
388
|
+
</sch:rule>
|
389
|
+
<sch:rule id="Performance_Rate_for_Proportion_Measure-reference-errors" context="cda:observation[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.14'][@extension='2020-12-01']]/cda:reference">
|
390
|
+
<sch:assert id="a-4484-19652-error" test="@typeCode='REFR'">The reference, if present, SHALL contain exactly one [1..1] @typeCode="REFR" refers to (CodeSystem: HL7ActRelationshipType urn:oid:2.16.840.1.113883.5.1002) (CONF:4484-19652).</sch:assert>
|
391
|
+
<sch:assert id="a-4484-19653-error" test="count(cda:externalObservation)=1">The reference, if present, SHALL contain exactly one [1..1] externalObservation (CONF:4484-19653).</sch:assert>
|
392
|
+
</sch:rule>
|
393
|
+
<!-- 12-01-2020 Added rules to check format of value attribute in xsi:type REAL value element -->
|
394
|
+
<sch:rule id="Performance_Rate_for_Proportion_Measure-value-errors" context="cda:observation[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.14'][@extension='2020-12-01']]/cda:value[@xsi:type='REAL']">
|
395
|
+
<sch:assert id="a-4484-21446-error" test="not(@value) or (@value >= 0.0 and @value <=1.0)">The value, if present, SHALL be greater than or equal to 0 and less than or equal to 1 (CONF:4484-21446).</sch:assert>
|
396
|
+
<sch:assert id="a-4484-21447-error" test="not(@value) or (string-length(normalize-space(substring-after(@value, '.'))) <= 6)">The value, if present, SHALL contain no more than 6 digits to the right of the decimal (CONF:4484-21447).</sch:assert>
|
397
|
+
</sch:rule>
|
398
|
+
<sch:rule id="Performance_Rate_for_Proportion_Measure-reference-externalObservation-errors" context="cda:observation[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.14'][@extension='2020-12-01']]/cda:reference/cda:externalObservation">
|
399
|
+
<sch:assert id="a-4484-19654-error" test="@classCode">This externalObservation SHALL contain exactly one [1..1] @classCode (CodeSystem: HL7ActClass urn:oid:2.16.840.1.113883.5.6) (CONF:4484-19654).</sch:assert>
|
400
|
+
<sch:assert id="a-4484-19657-error" test="count(cda:code)=1">This externalObservation SHALL contain exactly one [1..1] code (CONF:4484-19657).</sch:assert>
|
401
|
+
<sch:assert id="a-4484-19655-error" test="count(cda:id)=1">This externalObservation SHALL contain exactly one [1..1] id (CONF:4484-19655).</sch:assert>
|
402
|
+
</sch:rule>
|
403
|
+
<sch:rule id="Performance_Rate_for_Proportion_Measure-reference-externalObservation-id-errors" context="cda:observation[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.14'][@extension='2020-12-01']]/cda:reference/cda:externalObservation/cda:id">
|
404
|
+
<sch:assert id="a-4484-19656-error" test="@root">This id SHALL contain exactly one [1..1] @root (CONF:4484-19656).</sch:assert>
|
405
|
+
</sch:rule>
|
406
|
+
<sch:rule id="Performance_Rate_for_Proportion_Measure-reference-externalObservation-code-errors" context="cda:observation[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.14'][@extension='2020-12-01']]/cda:reference/cda:externalObservation/cda:code">
|
407
|
+
<sch:assert id="a-4484-19658-error" test="@code='NUMER'">This code SHALL contain exactly one [1..1] @code="NUMER" Numerator (CONF:4484-19658).</sch:assert>
|
408
|
+
<sch:assert id="a-4484-21180-error" test="@codeSystem='2.16.840.1.113883.5.4'">This code SHALL contain exactly one [1..1] @codeSystem="2.16.840.1.113883.5.4" (CodeSystem: ActCode urn:oid:2.16.840.1.113883.5.4) (CONF:4484-21180).</sch:assert>
|
409
|
+
</sch:rule>
|
410
|
+
<sch:rule id="Performance_Rate_for_Proportion_Measure-referenceRange-errors" context="cda:observation[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.14'][@extension='2020-12-01']]/cda:referenceRange">
|
411
|
+
<sch:assert id="a-4484-18401-error" test="count(cda:observationRange)=1">The referenceRange, if present, SHALL contain exactly one [1..1] observationRange (CONF:4484-18401).</sch:assert>
|
412
|
+
</sch:rule>
|
413
|
+
<sch:rule id="Performance_Rate_for_Proportion_Measure-referenceRange-observationRange-errors" context="cda:observation[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.14'][@extension='2020-12-01']]/cda:referenceRange/cda:observationRange">
|
414
|
+
<sch:assert id="a-4484-18402-error" test="count(cda:value[@xsi:type='REAL'])=1">This observationRange SHALL contain exactly one [1..1] value with @xsi:type="REAL" (CONF:4484-18402).</sch:assert>
|
415
|
+
</sch:rule>
|
416
|
+
</sch:pattern>
|
417
|
+
<sch:pattern id="Postal_Code_Supplemental_Data_Element_V2-pattern-extension-check">
|
418
|
+
<sch:rule id="Postal_Code_Supplemental_Data_Element_V2-extension-check" context="cda:observation/cda:templateId[@root='2.16.840.1.113883.10.20.27.3.10']">
|
419
|
+
<sch:assert id="a-3259-18211-extension-error" test="@extension='2016-09-01'">SHALL contain exactly one [1..1] templateId (CONF:3259-18211) such that it SHALL contain exactly one [1..1] @root="2.16.840.1.113883.10.20.27.3.10" (CONF:3259-18212). SHALL contain exactly one [1..1] @extension="2016-09-01" (CONF:3259-21446).</sch:assert>
|
420
|
+
</sch:rule>
|
421
|
+
</sch:pattern>
|
422
|
+
<sch:pattern id="Postal_Code_Supplemental_Data_Element_V2-pattern-errors">
|
423
|
+
<sch:rule id="Postal_Code_Supplemental_Data_Element_V2-errors" context="cda:observation[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.10'][@extension='2016-09-01']]">
|
424
|
+
<sch:assert id="a-3259-18209-error" test="@classCode='OBS'">SHALL contain exactly one [1..1] @classCode="OBS" (CodeSystem: HL7ActClass urn:oid:2.16.840.1.113883.5.6 STATIC) (CONF:3259-18209).</sch:assert>
|
425
|
+
<sch:assert id="a-3259-18210-error" test="@moodCode='EVN'">SHALL contain exactly one [1..1] @moodCode="EVN" (CodeSystem: ActMood urn:oid:2.16.840.1.113883.5.1001 STATIC) (CONF:3259-18210).</sch:assert>
|
426
|
+
<sch:assert id="a-3259-18211-error" test="count(cda:templateId[@root='2.16.840.1.113883.10.20.27.3.10'][@extension='2016-09-01'])=1">SHALL contain exactly one [1..1] templateId (CONF:3259-18211) such that it SHALL contain exactly one [1..1] @root="2.16.840.1.113883.10.20.27.3.10" (CONF:3259-18212). SHALL contain exactly one [1..1] @extension="2016-09-01" (CONF:3259-21446).</sch:assert>
|
427
|
+
<sch:assert id="a-3259-18213-error" test="count(cda:code)=1">SHALL contain exactly one [1..1] code (CONF:3259-18213).</sch:assert>
|
428
|
+
<sch:assert id="a-3259-18100-error" test="count(cda:statusCode)=1">SHALL contain exactly one [1..1] statusCode (CONF:3259-18100).</sch:assert>
|
429
|
+
<sch:assert id="a-3259-18215-error" test="count(cda:value[@xsi:type='ST'])=1">SHALL contain exactly one [1..1] value with @xsi:type="ST" (CONF:3259-18215).</sch:assert>
|
430
|
+
<sch:assert id="a-3259-18102-error" test="count(cda:entryRelationship[@typeCode='SUBJ'][@inversionInd='true'][count(cda:observation[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.3']])=1])=1">SHALL contain exactly one [1..1] entryRelationship (CONF:3259-18102) such that it SHALL contain exactly one [1..1] @typeCode="SUBJ" Has Subject (CodeSystem: HL7ActRelationshipType urn:oid:2.16.840.1.113883.5.1002 STATIC) (CONF:3259-18103). SHALL contain exactly one [1..1] @inversionInd="true" (CONF:3259-18104). SHALL contain exactly one [1..1] Aggregate Count (identifier: urn:oid:2.16.840.1.113883.10.20.27.3.3) (CONF:3259-18105).</sch:assert>
|
431
|
+
</sch:rule>
|
432
|
+
<sch:rule id="Postal_Code_Supplemental_Data_Element_V2-code-errors" context="cda:observation[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.10'][@extension='2016-09-01']]/cda:code">
|
433
|
+
<sch:assert id="a-3259-18214-error" test="@code='45401-7'">This code SHALL contain exactly one [1..1] @code="45401-7" Zip code (CONF:3259-18214).</sch:assert>
|
434
|
+
<sch:assert id="a-3259-21445-error" test="@codeSystem='2.16.840.1.113883.6.1'">This code SHALL contain exactly one [1..1] @codeSystem="2.16.840.1.113883.6.1" (CodeSystem: LOINC urn:oid:2.16.840.1.113883.6.1) (CONF:3259-21445).</sch:assert>
|
435
|
+
</sch:rule>
|
436
|
+
<sch:rule id="Postal_Code_Supplemental_Data_Element_V2-statusCode-errors" context="cda:observation[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.10'][@extension='2016-09-01']]/cda:statusCode">
|
437
|
+
<sch:assert id="a-3259-18101-error" test="@code='completed'">This statusCode SHALL contain exactly one [1..1] @code="completed" Completed (CodeSystem: ActStatus urn:oid:2.16.840.1.113883.5.14 STATIC) (CONF:3259-18101).</sch:assert>
|
438
|
+
</sch:rule>
|
439
|
+
</sch:pattern>
|
440
|
+
<sch:pattern id="Promoting_Interoperability_Measure_Performed_Reference_and_Result-pattern-errors">
|
441
|
+
<sch:rule id="Promoting_Interoperability_Measure_Performed_Reference_and_Result-errors" context="cda:organizer[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.29'][@extension='2016-09-01']]">
|
442
|
+
<sch:assert id="a-3259-21419-error" test="@classCode='CLUSTER'">SHALL contain exactly one [1..1] @classCode="CLUSTER" (CodeSystem: HL7ActClass urn:oid:2.16.840.1.113883.5.6 STATIC) (CONF:3259-21419).</sch:assert>
|
443
|
+
<sch:assert id="a-3259-21420-error" test="@moodCode='EVN'">SHALL contain exactly one [1..1] @moodCode="EVN" (CodeSystem: ActMood urn:oid:2.16.840.1.113883.5.1001 STATIC) (CONF:3259-21420).</sch:assert>
|
444
|
+
<sch:assert id="a-3259-21408-error" test="count(cda:templateId[@root='2.16.840.1.113883.10.20.27.3.29'][@extension='2016-09-01'])=1">SHALL contain exactly one [1..1] templateId (CONF:3259-21408) such that it SHALL contain exactly one [1..1] @root="2.16.840.1.113883.10.20.27.3.29" (CONF:3259-21417). SHALL contain exactly one [1..1] @extension="2016-09-01" (CONF:3259-21418).</sch:assert>
|
445
|
+
<sch:assert id="a-3259-21405-error" test="count(cda:reference[@typeCode='REFR'][count(cda:externalDocument)=1])=1">SHALL contain exactly one [1..1] reference (CONF:3259-21405) such that it SHALL contain exactly one [1..1] @typeCode="REFR" (CONF:3259-21416). SHALL contain exactly one [1..1] externalDocument (CodeSystem: HL7ActClass urn:oid:2.16.840.1.113883.5.6 STATIC) (CONF:3259-21406).</sch:assert>
|
446
|
+
<sch:assert id="a-3259-21404-error" test="count(cda:component[count(cda:observation[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.27'][@extension='2016-09-01']])=1])=1">SHALL contain exactly one [1..1] component (CONF:3259-21404) such that it SHALL contain exactly one [1..1] Measure Performed (identifier: urn:hl7ii:2.16.840.1.113883.10.20.27.3.27:2016-09-01) (CONF:3259-21411)</sch:assert>
|
447
|
+
</sch:rule>
|
448
|
+
<sch:rule id="Promoting_Interoperability_Measure_Performed_Reference_and_Result_reference_externalDocument-errors" context="cda:organizer[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.29'][@extension='2016-09-01']]/cda:reference/cda:externalDocument">
|
449
|
+
<sch:assert id="a-3259-21415-error" test="@classCode='DOC'">This externalDocument SHALL contain exactly one [1..1] @classCode="DOC" Document (CodeSystem: HL7ActClass urn:oid:2.16.840.1.113883.5.6) (CONF:3259-21415).</sch:assert>
|
450
|
+
<sch:assert id="a-3259-21407-error" test="count(cda:id[@root='2.16.840.1.113883.3.7031'][@extension])=1">This externalDocument SHALL contain exactly one [1..1] id (CONF:3259-21407) such that it SHALL contain exactly one [1..1] @root="2.16.840.1.113883.3.7031" (CONF:3259-21412). SHALL contain exactly one [1..1] @extension (CONF:3259-21413).</sch:assert>
|
451
|
+
</sch:rule>
|
452
|
+
</sch:pattern>
|
453
|
+
<sch:pattern id="Promoting_Interoperability_Numerator_Denominator_Type_Measure_Denominator-pattern-errors">
|
454
|
+
<sch:rule id="Promoting_Interoperability_Numerator_Denominator_Type_Measure_Denominator-errors" context="cda:observation[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.32'][@extension='2016-09-01']]">
|
455
|
+
<sch:assert id="a-3259-21378-error" test="@classCode='OBS'">SHALL contain exactly one [1..1] @classCode="OBS" (CodeSystem: HL7ActClass urn:oid:2.16.840.1.113883.5.6 STATIC) (CONF:3259-21378).</sch:assert>
|
456
|
+
<sch:assert id="a-3259-21379-error" test="@moodCode='EVN'">SHALL contain exactly one [1..1] @moodCode="EVN" (CodeSystem: ActMood urn:oid:2.16.840.1.113883.5.1001 STATIC) (CONF:3259-21379).</sch:assert>
|
457
|
+
<sch:assert id="a-3259-21366-error" test="count(cda:templateId[@root='2.16.840.1.113883.10.20.27.3.32'][@extension='2016-09-01'])=1">SHALL contain exactly one [1..1] templateId (CONF:3259-21366) such that it SHALL contain exactly one [1..1] @root="2.16.840.1.113883.10.20.27.3.32" (CONF:3259-21374). SHALL contain exactly one [1..1] @extension="2016-09-01" (CONF:3259-21400).</sch:assert>
|
458
|
+
<sch:assert id="a-3259-21365-error" test="count(cda:code)=1">SHALL contain exactly one [1..1] code (CONF:3259-21365).</sch:assert>
|
459
|
+
<sch:assert id="a-3259-21367-error" test="count(cda:statusCode)=1">SHALL contain exactly one [1..1] statusCode (CONF:3259-21367).</sch:assert>
|
460
|
+
<sch:assert id="a-3259-21368-error" test="count(cda:value[@xsi:type='CD'])=1">SHALL contain exactly one [1..1] value with @xsi:type="CD" (CONF:3259-21368).</sch:assert>
|
461
|
+
<sch:assert id="a-3259-21364-error" test="count(cda:entryRelationship[@typeCode='SUBJ'][@inversionInd='true'][count(cda:observation[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.3']])=1])=1">SHALL contain exactly one [1..1] entryRelationship (CONF:3259-21364) such that it SHALL contain exactly one [1..1] @typeCode="SUBJ" (CONF:3259-21370). SHALL contain exactly one [1..1] @inversionInd="true" (CONF:3259-21371). SHALL contain exactly one [1..1] Aggregate Count (identifier: urn:oid:2.16.840.1.113883.10.20.27.3.3) (CONF:3259-21369).</sch:assert>
|
462
|
+
</sch:rule>
|
463
|
+
<sch:rule id="Promoting_Interoperability_Numerator_Denominator_Type_Measure_Denominator-code-errors" context="cda:observation[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.32'][@extension='2016-09-01']]/cda:code">
|
464
|
+
<sch:assert id="a-3259-21372-error" test="@code='ASSERTION'">This code SHALL contain exactly one [1..1] @code="ASSERTION" Assertion (CONF:3259-21372).</sch:assert>
|
465
|
+
<sch:assert id="a-3259-21373-error" test="@codeSystem='2.16.840.1.113883.5.4'">This code SHALL contain exactly one [1..1] @codeSystem="2.16.840.1.113883.5.4" (CodeSystem: ActCode urn:oid:2.16.840.1.113883.5.4) (CONF:3259-21373).</sch:assert>
|
466
|
+
</sch:rule>
|
467
|
+
<sch:rule id="Promoting_Interoperability_Numerator_Denominator_Type_Measure_Denominator-statusCode-errors" context="cda:observation[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.32'][@extension='2016-09-01']]/cda:statusCode">
|
468
|
+
<sch:assert id="a-3259-21375-error" test="@code='completed'">This statusCode SHALL contain exactly one [1..1] @code="completed" Completed (CodeSystem: ActStatus urn:oid:2.16.840.1.113883.5.14) (CONF:3259-21375).</sch:assert>
|
469
|
+
</sch:rule>
|
470
|
+
<sch:rule id="Promoting_Interoperability_Numerator_Denominator_Type_Measure_Denominator-value-errors" context="cda:observation[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.32'][@extension='2016-09-01']]/cda:value">
|
471
|
+
<sch:assert id="a-3259-21376-error" test="@code='DENOM'">This value SHALL contain exactly one [1..1] @code="DENOM" Denominator (CONF:3259-21376).</sch:assert>
|
472
|
+
<sch:assert id="a-3259-21377-error" test="@codeSystem='2.16.840.1.113883.5.4'">This value SHALL contain exactly one [1..1] @codeSystem="2.16.840.1.113883.5.4" (CodeSystem: ActCode urn:oid:2.16.840.1.113883.5.4 STATIC) (CONF:3259-21377).</sch:assert>
|
473
|
+
</sch:rule>
|
474
|
+
</sch:pattern>
|
475
|
+
<sch:pattern id="Promoting_Interoperability_Numerator_Denominator_Type_Measure_Numerator-pattern-errors">
|
476
|
+
<sch:rule id="Promoting_Interoperability_Numerator_Denominator_Type_Measure_Numerator-errors" context="cda:observation[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.31'][@extension='2016-09-01']]">
|
477
|
+
<sch:assert id="a-3259-21360-error" test="@classCode='OBS'">SHALL contain exactly one [1..1] @classCode="OBS" (CodeSystem: HL7ActClass urn:oid:2.16.840.1.113883.5.6 STATIC) (CONF:3259-21360).</sch:assert>
|
478
|
+
<sch:assert id="a-3259-21361-error" test="@moodCode='EVN'">SHALL contain exactly one [1..1] @moodCode="EVN" (CodeSystem: ActMood urn:oid:2.16.840.1.113883.5.1001 STATIC) (CONF:3259-21361).</sch:assert>
|
479
|
+
<sch:assert id="a-3259-21324-error" test="count(cda:templateId[@root='2.16.840.1.113883.10.20.27.3.31'][@extension='2016-09-01'])=1">SHALL contain exactly one [1..1] templateId (CONF:3259-21324) such that it SHALL contain exactly one [1..1] @root="2.16.840.1.113883.10.20.27.3.31" (CONF:3259-21342). SHALL contain exactly one [1..1] @extension="2016-09-01" (CONF:3259-21401).</sch:assert>
|
480
|
+
<sch:assert id="a-3259-21323-error" test="count(cda:code)=1">SHALL contain exactly one [1..1] code (CONF:3259-21323).</sch:assert>
|
481
|
+
<sch:assert id="a-3259-21332-error" test="count(cda:statusCode)=1">SHALL contain exactly one [1..1] statusCode (CONF:3259-21332).</sch:assert>
|
482
|
+
<sch:assert id="a-3259-21336-error" test="count(cda:value[@xsi:type='CD'])=1">SHALL contain exactly one [1..1] value with @xsi:type="CD" (CONF:3259-21336).</sch:assert>
|
483
|
+
<sch:assert id="a-3259-21322-error" test="count(cda:entryRelationship[@typeCode='SUBJ'][@inversionInd='true'][count(cda:observation[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.3']])=1])=1">SHALL contain exactly one [1..1] entryRelationship (CONF:3259-21322) such that it SHALL contain exactly one [1..1] @typeCode="SUBJ" (CONF:3259-21338). SHALL contain exactly one [1..1] @inversionInd="true" (CONF:3259-21339). SHALL contain exactly one [1..1] Aggregate Count (identifier: urn:oid:2.16.840.1.113883.10.20.27.3.3) (CONF:3259-21337).</sch:assert>
|
484
|
+
</sch:rule>
|
485
|
+
<sch:rule id="Promoting_Interoperability_Numerator_Denominator_Type_Measure_Numerator-code-errors" context="cda:observation[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.31'][@extension='2016-09-01']]/cda:code">
|
486
|
+
<sch:assert id="a-3259-21340-error" test="@code='ASSERTION'">This code SHALL contain exactly one [1..1] @code="ASSERTION" Assertion (CONF:3259-21340).</sch:assert>
|
487
|
+
<sch:assert id="a-3259-21341-error" test="@codeSystem='2.16.840.1.113883.5.4'">This code SHALL contain exactly one [1..1] @codeSystem="2.16.840.1.113883.5.4" (CodeSystem: ActCode urn:oid:2.16.840.1.113883.5.4) (CONF:3259-21341).</sch:assert>
|
488
|
+
</sch:rule>
|
489
|
+
<sch:rule id="Promoting_Interoperability_Numerator_Denominator_Type_Measure_Numerator-statusCode-errors" context="cda:observation[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.31'][@extension='2016-09-01']]/cda:statusCode">
|
490
|
+
<sch:assert id="a-3259-21358-error" test="@code='completed'">This statusCode SHALL contain exactly one [1..1] @code="completed" Completed (CodeSystem: ActStatus urn:oid:2.16.840.1.113883.5.14) (CONF:3259-21358).</sch:assert>
|
491
|
+
</sch:rule>
|
492
|
+
<sch:rule id="Promoting_Interoperability_Numerator_Denominator_Type_Measure_Numerator-value-errors" context="cda:observation[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.31'][@extension='2016-09-01']]/cda:value">
|
493
|
+
<sch:assert id="a-3259-21362-error" test="@code='NUMER'">This value SHALL contain exactly one [1..1] @code="NUMER" Numerator (CONF:3259-21362).</sch:assert>
|
494
|
+
<sch:assert id="a-3259-21363-error" test="@codeSystem='2.16.840.1.113883.5.4'">This value SHALL contain exactly one [1..1] @codeSystem="2.16.840.1.113883.5.4" (CodeSystem: ActCode urn:oid:2.16.840.1.113883.5.4 STATIC) (CONF:3259-21363).</sch:assert>
|
495
|
+
</sch:rule>
|
496
|
+
</sch:pattern>
|
497
|
+
<sch:pattern id="Promoting_Interoperability_Numerator_Denominator_Measure_Reference_and_Results-pattern-errors">
|
498
|
+
<sch:rule id="Promoting_Interoperability_Numerator_Denominator_Measure_Reference_and_Results-errors" context="cda:organizer[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.28'][@extension='2017-06-01']]">
|
499
|
+
<sch:assert id="a-3338-21273-error" test="@classCode='CLUSTER'">SHALL contain exactly one [1..1] @classCode="CLUSTER" (CodeSystem: HL7ActClass urn:oid:2.16.840.1.113883.5.6 STATIC) (CONF:3338-21273).</sch:assert>
|
500
|
+
<sch:assert id="a-3338-21274-error" test="@moodCode='EVN'">SHALL contain exactly one [1..1] @moodCode="EVN" (CodeSystem: ActMood urn:oid:2.16.840.1.113883.5.1001 STATIC) (CONF:3338-21274).</sch:assert>
|
501
|
+
<sch:assert id="a-3338-21248-error" test="count(cda:templateId[@root='2.16.840.1.113883.10.20.27.3.28'][@extension='2017-06-01'])=1">SHALL contain exactly one [1..1] templateId (CONF:3338-21248) such that it SHALL contain exactly one [1..1] @root="2.16.840.1.113883.10.20.27.3.28" (CONF:3338-21266). SHALL contain exactly one [1..1] @extension="2017-06-01" (CONF:3338-21396).</sch:assert>
|
502
|
+
<sch:assert id="a-3338-21242-error" test="count(cda:reference[@typeCode='REFR'][count(cda:externalDocument)=1])=1">SHALL contain exactly one [1..1] reference (CONF:3338-21242) such that it SHALL contain exactly one [1..1] @typeCode="REFR" (CONF:3338-21265). SHALL contain exactly one [1..1] externalDocument (CodeSystem: HL7ActClass urn:oid:2.16.840.1.113883.5.6 STATIC) (CONF:3338-21243).</sch:assert>
|
503
|
+
<sch:assert id="a-3338-21312-error" test="count(cda:component[count(cda:observation[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.31'][@extension='2016-09-01']])=1])=1">SHALL contain exactly one [1..1] component (CONF:3338-21312) such that it SHALL contain exactly one [1..1] Advancing Care Information Numerator Denominator Type Measure Numerator Data (identifier: urn:hl7ii:2.16.840.1.113883.10.20.27.3.31:2016-09-01) (CONF:3338-21313).</sch:assert>
|
504
|
+
<sch:assert id="a-3338-21320-error" test="count(cda:component[count(cda:observation[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.32'][@extension='2016-09-01']])=1])=1">SHALL contain exactly one [1..1] component (CONF:3338-21320) such that it SHALL contain exactly one [1..1] Advancing Care Information Numerator Denominator Type Measure Denominator Data (identifier: urn:hl7ii:2.16.840.1.113883.10.20.27.3.32:2016-09-01) (CONF:3338-21321).</sch:assert>
|
505
|
+
</sch:rule>
|
506
|
+
<sch:rule id="Promoting_Interoperability_Numerator_Denominator_Measure_Reference_and_Results_reference_externalDocument-errors" context="cda:organizer[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.28'][@extension='2017-06-01']]/cda:reference/cda:externalDocument">
|
507
|
+
<sch:assert id="a-3338-21264-error" test="@classCode='DOC'">This externalDocument SHALL contain exactly one [1..1] @classCode="DOC" Document (CodeSystem: HL7ActClass urn:oid:2.16.840.1.113883.5.6) (CONF:3338-21264).</sch:assert>
|
508
|
+
<sch:assert id="a-3338-21247-error" test="count(cda:id[@root='2.16.840.1.113883.3.7031'][@extension])=1">This externalDocument SHALL contain exactly one [1..1] id (CONF:3338-21247) such that it SHALL contain exactly one [1..1] @root="2.16.840.1.113883.3.7031" (CONF:3338-21402). SHALL contain exactly one [1..1] @extension (CONF:3338-21403).</sch:assert>
|
509
|
+
</sch:rule>
|
510
|
+
</sch:pattern>
|
511
|
+
<sch:pattern id="Promoting_Interoperability-pattern-extension-check">
|
512
|
+
<sch:rule id="Promoting_Interoperability-extension-check" context="cda:section/cda:templateId[@root='2.16.840.1.113883.10.20.27.2.5']">
|
513
|
+
<sch:assert id="a-4484-21231-extension-error" test="@extension='2020-12-01'">SHALL contain exactly one [1..1] templateId (CONF:4484-21231) such that it SHALL contain exactly one [1..1] @root="2.16.840.1.113883.10.20.27.2.5" (CONF:4484-21233). SHALL contain exactly one [1..1] @extension="2020-12-01" (CONF:4484-21395).</sch:assert>
|
514
|
+
</sch:rule>
|
515
|
+
</sch:pattern>
|
516
|
+
<sch:pattern id="Promoting_Interoperability-pattern-errors">
|
517
|
+
<sch:rule id="Promoting_Interoperability-errors" context="cda:section[cda:templateId[@root='2.16.840.1.113883.10.20.27.2.5'][@extension='2020-12-01']]">
|
518
|
+
<sch:assert id="a-4484-21231-error" test="count(cda:templateId[@root='2.16.840.1.113883.10.20.27.2.5'][@extension='2020-12-01'])=1">SHALL contain exactly one [1..1] templateId (CONF:4484-21231) such that it SHALL contain exactly one [1..1] @root="2.16.840.1.113883.10.20.27.2.5" (CONF:4484-21233). SHALL contain exactly one [1..1] @extension="2020-12-01" (CONF:4484-21395).</sch:assert>
|
519
|
+
<!-- 11-25-2020 Updated templateID extension -->
|
520
|
+
<sch:assert id="a-4484-21440-error" test="count(cda:entry[cda:act[cda:templateId[@root='2.16.840.1.113883.10.20.17.3.8'][@extension='2020-12-01']]])=1">SHALL contain exactly one [1..1] entry (CONF:4484-21440) such that it SHALL contain exactly one [1..1] Reporting Parameters Act (V2) (identifier: urn:hl7ii:2.16.840.1.113883.10.20.17.3.8:2020-12-01) (CONF:4484-21441).</sch:assert>
|
521
|
+
<sch:assert id="a-4484-21438-error" test="count(cda:entry) > 0">SHALL contain at least one [1..*] entry (CONF:4484-21438).</sch:assert>
|
522
|
+
<sch:assert id="a-4484-21439-error" test="count(cda:entry[cda:organizer[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.28'][@extension='2017-06-01']]]) > 0 or count(cda:entry[cda:organizer[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.29'][@extension='2016-09-01']]]) > 0">This Promoting Interoperability Section SHALL contain at least a Promoting Interoperability Numerator Denominator Type Measure Reference and Results or a Promoting Interoperability Measure Performed Reference and Results (CONF:4484-21439).</sch:assert>
|
523
|
+
</sch:rule>
|
524
|
+
</sch:pattern>
|
525
|
+
<sch:pattern id="QRDA_Category_III_Measure-pattern-extension-check">
|
526
|
+
<sch:rule id="QRDA_Category_III_Measure-extension-check" context="cda:section/cda:templateId[@root='2.16.840.1.113883.10.20.27.2.1']">
|
527
|
+
<sch:assert id="a-4484-17284-extension-error" test="@extension='2020-12-01'">SHALL contain exactly one [1..1] templateId (CONF:4484-17284) such that it SHALL contain exactly one [1..1] @root="2.16.840.1.113883.10.20.27.2.1" (CONF:4484-17285). SHALL contain exactly one [1..1] @extension="2020-12-01" (CONF:4484-21171).</sch:assert>
|
528
|
+
</sch:rule>
|
529
|
+
</sch:pattern>
|
530
|
+
<sch:pattern id="QRDA_Category_III_Measure-pattern-errors">
|
531
|
+
<sch:rule id="QRDA_Category_III_Measure-errors" context="cda:section[cda:templateId[@root='2.16.840.1.113883.10.20.27.2.1'][@extension='2020-12-01']]">
|
532
|
+
<sch:assert id="a-4484-17284-error" test="count(cda:templateId[@root='2.16.840.1.113883.10.20.27.2.1'][@extension='2020-12-01'])=1">SHALL contain exactly one [1..1] templateId (CONF:4484-17284) such that it SHALL contain exactly one [1..1] @root="2.16.840.1.113883.10.20.27.2.1" (CONF:4484-17285). SHALL contain exactly one [1..1] @extension="2020-12-01" (CONF:4484-21171).</sch:assert>
|
533
|
+
<sch:assert id="a-4484-17906-error" test="count(cda:entry[count(cda:organizer[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.1'][@extension='2020-12-01']])=1]) > 0">SHALL contain at least one [1..*] entry (CONF:4484-17906) such that it SHALL contain exactly one [1..1] Measure Reference and Results (V4) (identifier: urn:hl7ii:2.16.840.1.113883.10.20.27.3.1:2016-09-01) (CONF:4484-17907)</sch:assert>
|
534
|
+
<!-- 11-25-2020 Updated templateId extension -->
|
535
|
+
<sch:assert id="a-4484-21467-error" test="count(cda:entry[cda:act[cda:templateId[@root='2.16.840.1.113883.10.20.17.3.8'][@extension='2020-12-01']]])=1">SHALL contain exactly one [1..1] entry (CONF:4484-21467) such that it SHALL contain exactly one [1..1] Reporting Parameters Act (V2) (identifier: urn:hl7ii:2.16.840.1.113883.10.20.17.3.8:2020-12-01) (CONF:4484-21468).</sch:assert>
|
536
|
+
</sch:rule>
|
537
|
+
</sch:pattern>
|
538
|
+
<sch:pattern id="QRDA_Category_III_Report-pattern-extension-check">
|
539
|
+
<sch:rule id="QRDA_Category_III_Report-extension-check" context="cda:ClinicalDocument/cda:templateId[@root='2.16.840.1.113883.10.20.24.3.1']">
|
540
|
+
<sch:assert id="a-4484-17208-extension-error" test="@extension='2020-12-01'">SHALL contain exactly one [1..1] templateId (CONF:4484-17208) such that it SHALL contain exactly one [1..1] @root="2.16.840.1.113883.10.20.27.1.1" (CONF:4484-17209). SHALL contain exactly one [1..1] @extension="2020-12-01" (CONF:4484-21319).</sch:assert>
|
541
|
+
</sch:rule>
|
542
|
+
</sch:pattern>
|
543
|
+
<sch:pattern id="QRDA_Category_III_Report-pattern-errors">
|
544
|
+
<sch:rule id="QRDA_Category_III_Report-errors" context="cda:ClinicalDocument">
|
545
|
+
<sch:assert id="a-4484-17226-error" test="count(cda:realmCode)=1">SHALL contain exactly one [1..1] realmCode (CONF:4484-17226).</sch:assert>
|
546
|
+
<sch:assert id="a-4484-18186-error" test="count(cda:typeId)=1">SHALL contain exactly one [1..1] typeId (CONF:4484-18186).</sch:assert>
|
547
|
+
<sch:assert id="a-4484-17208-error" test="count(cda:templateId[@root='2.16.840.1.113883.10.20.27.1.1'][@extension='2020-12-01'])=1">SHALL contain exactly one [1..1] templateId (CONF:4484-17208) such that it SHALL contain exactly one [1..1] @root="2.16.840.1.113883.10.20.27.1.1" (CONF:4484-17209). SHALL contain exactly one [1..1] @extension="2020-12-01" (CONF:4484-21319).</sch:assert>
|
548
|
+
<sch:assert id="a-4484-17236-error" test="count(cda:id)=1">SHALL contain exactly one [1..1] id (CONF:4484-17236).</sch:assert>
|
549
|
+
<sch:assert id="a-4484-17210-error" test="count(cda:code)=1">SHALL contain exactly one [1..1] code (CONF:4484-17210).</sch:assert>
|
550
|
+
<sch:assert id="a-4484-17211-error" test="count(cda:title)=1">SHALL contain exactly one [1..1] title (CONF:4484-17211).</sch:assert>
|
551
|
+
<sch:assert id="a-4484-17237-error" test="count(cda:effectiveTime)=1">SHALL contain exactly one [1..1] effectiveTime (CONF:4484-17237).</sch:assert>
|
552
|
+
<sch:assert id="a-4484-17238-error" test="count(cda:confidentialityCode)=1">SHALL contain exactly one [1..1] confidentialityCode, which SHOULD be selected from ValueSet HL7 BasicConfidentialityKind urn:oid:2.16.840.1.113883.1.11.16926 STATIC 2010-04-21 (CONF:4484-17238).</sch:assert>
|
553
|
+
<sch:assert id="a-4484-17239-error" test="count(cda:languageCode)=1">SHALL contain exactly one [1..1] languageCode (CONF:4484-17239).</sch:assert>
|
554
|
+
<sch:assert id="a-4484-17212-error" test="count(cda:recordTarget)=1">SHALL contain exactly one [1..1] recordTarget (CONF:4484-17212).</sch:assert>
|
555
|
+
<sch:assert id="a-4484-18156-error" test="count(cda:author[count(cda:time)=1][count(cda:assignedAuthor)=1]) > 0">SHALL contain at least one [1..*] author (CONF:4484-18156) such that it SHALL contain exactly one [1..1] time (CONF:4484-18158). SHALL contain exactly one [1..1] assignedAuthor (CONF:4484-18157).</sch:assert>
|
556
|
+
<sch:assert id="a-4484-17213-error" test="count(cda:custodian)=1">SHALL contain exactly one [1..1] custodian (CONF:4484-17213).</sch:assert>
|
557
|
+
<sch:assert id="a-4484-17217-error" test="count(cda:component)=1">SHALL contain exactly one [1..1] component (CONF:4484-17217).</sch:assert>
|
558
|
+
</sch:rule>
|
559
|
+
<!-- realmCode related rules -->
|
560
|
+
<sch:rule id="QRDA_Category_III_Report-typeId-errors" context="cda:ClinicalDocument[cda:templateId[@root='2.16.840.1.113883.10.20.27.1.1'][@extension='2020-12-01']]/cda:typeId">
|
561
|
+
<sch:assert id="a-4484-18187-error" test="@root='2.16.840.1.113883.1.3'">This typeId SHALL contain exactly one [1..1] @root="2.16.840.1.113883.1.3" (CONF:4484-18187).</sch:assert>
|
562
|
+
<sch:assert id="a-4484-18188-error" test="@extension='POCD_HD000040'">This typeId SHALL contain exactly one [1..1] @extension="POCD_HD000040" (CONF:4484-18188).</sch:assert>
|
563
|
+
</sch:rule>
|
564
|
+
<sch:rule id="QRDA_Category_III_Report-realmCode-errors" context="cda:ClinicalDocument[cda:templateId[@root='2.16.840.1.113883.10.20.27.1.1'][@extension='2020-12-01']]/cda:realmCode">
|
565
|
+
<sch:assert id="a-4484-17227-error" test="@code='US'">This realmCode SHALL contain exactly one [1..1] @code="US" (CONF:4484-17227).</sch:assert>
|
566
|
+
</sch:rule>
|
567
|
+
<sch:rule id="QRDA_Category_III_Report-code-errors" context="cda:ClinicalDocument[cda:templateId[@root='2.16.840.1.113883.10.20.27.1.1'][@extension='2020-12-01']]/cda:code">
|
568
|
+
<sch:assert id="a-4484-19549-error" test="@code='55184-6'">This code SHALL contain exactly one [1..1] @code="55184-6" Quality Reporting Document Architecture Calculated Summary Report (CONF:4484-19549).</sch:assert>
|
569
|
+
<sch:assert id="a-4484-21166-error" test="@codeSystem='2.16.840.1.113883.6.1'">This code SHALL contain exactly one [1..1] @codeSystem="2.16.840.1.113883.6.1" (CodeSystem: LOINC urn:oid:2.16.840.1.113883.6.1) (CONF:4484-21166).</sch:assert>
|
570
|
+
</sch:rule>
|
571
|
+
<!-- languageCode rules -->
|
572
|
+
<sch:rule id="QRDA_Category_III_Report-languageCode-errors" context="cda:ClinicalDocument[cda:templateId[@root='2.16.840.1.113883.10.20.27.1.1'][@extension='2020-12-01']]/cda:languageCode">
|
573
|
+
<sch:assert id="a-4484-19669-error" test="@code">This languageCode SHALL contain exactly one [1..1] @code, which SHALL be selected from ValueSet Language urn:oid:2.16.840.1.113883.1.11.11526 DYNAMIC (CONF:4484-19669).</sch:assert>
|
574
|
+
</sch:rule>
|
575
|
+
<!-- recordTarget rules -->
|
576
|
+
<sch:rule id="QRDA_Category_III_Report-recordTarget-errors" context="cda:ClinicalDocument[cda:templateId[@root='2.16.840.1.113883.10.20.27.1.1'][@extension='2020-12-01']]/cda:recordTarget">
|
577
|
+
<sch:assert id="a-4484-17232-error" test="count(cda:patientRole[count(cda:id[@nullFlavor='NA'])=1])=1">This recordTarget SHALL contain exactly one [1..1] patientRole (CONF:4484-17232) such that it SHALL contain exactly one [1..1] id (CONF:4484-17233). This id SHALL contain exactly one [1..1] @nullFlavor="NA" (CONF:4484-17234).</sch:assert>
|
578
|
+
</sch:rule>
|
579
|
+
<!-- author rules -->
|
580
|
+
<sch:rule id="QRDA_Category_III_Report-author-assignedAuthor-errors" context="cda:ClinicalDocument[cda:templateId[@root='2.16.840.1.113883.10.20.27.1.1'][@extension='2020-12-01']]/cda:author/cda:assignedAuthor">
|
581
|
+
<sch:assert id="a-4484-18163-error" test="count(cda:representedOrganization)=1">This assignedAuthor SHALL contain exactly one [1..1] representedOrganization (CONF:4484-18163).</sch:assert>
|
582
|
+
<sch:assert id="a-4484-19667-error" test="count(cda:assignedPerson)=1 or count(cda:assignedAuthoringDevice)=1">There SHALL be exactly one assignedAuthor/assignedPerson or exactly one assignedAuthor/assignedAuthoringDevice (CONF:4484-19667).</sch:assert>
|
583
|
+
</sch:rule>
|
584
|
+
<sch:rule id="QRDA_Category_III_Report-author-assignedAuthor-representedOrganization-errors" context="cda:ClinicalDocument[cda:templateId[@root='2.16.840.1.113883.10.20.27.1.1'][@extension='2020-12-01']]/cda:author/cda:assignedAuthor/cda:representedOrganization">
|
585
|
+
<sch:assert id="a-4484-18265-error" test="count(cda:name) > 0">This representedOrganization SHALL contain at least one [1..*] name (CONF:4484-18265).</sch:assert>
|
586
|
+
</sch:rule>
|
587
|
+
<sch:rule id="QRDA_Category_III_Report-author-assignedAuthor-assignedAuthoringDevice-errors" context="cda:ClinicalDocument[cda:templateId[@root='2.16.840.1.113883.10.20.27.1.1'][@extension='2020-12-01']]/cda:author/cda:assignedAuthor/cda:assignedAuthoringDevice">
|
588
|
+
<sch:assert id="a-4484-18262-error" test="count(cda:softwareName)=1">The assignedAuthoringDevice, if present, SHALL contain exactly one [1..1] softwareName (CONF:4484-18262).</sch:assert>
|
589
|
+
</sch:rule>
|
590
|
+
<!-- custodian rules -->
|
591
|
+
<sch:rule id="QRDA_Category_III_Report-custodian-errors" context="cda:ClinicalDocument[cda:templateId[@root='2.16.840.1.113883.10.20.27.1.1'][@extension='2020-12-01']]/cda:custodian">
|
592
|
+
<sch:assert id="a-4484-17214-error" test="count(cda:assignedCustodian)=1">This custodian SHALL contain exactly one [1..1] assignedCustodian (CONF:4484-17214).</sch:assert>
|
593
|
+
</sch:rule>
|
594
|
+
<sch:rule id="QRDA_Category_III_Report-custodian-assignedCustodian-errors" context="cda:ClinicalDocument[cda:templateId[@root='2.16.840.1.113883.10.20.27.1.1'][@extension='2020-12-01']]/cda:custodian/cda:assignedCustodian">
|
595
|
+
<sch:assert id="a-4484-17215-error" test="count(cda:representedCustodianOrganization)=1">This assignedCustodian SHALL contain exactly one [1..1] representedCustodianOrganization (CONF:4484-17215).</sch:assert>
|
596
|
+
</sch:rule>
|
597
|
+
<sch:rule id="QRDA_Category_III_Report-custodian-assignedCustodian-representedCustodianOrganization-errors" context="cda:ClinicalDocument[cda:templateId[@root='2.16.840.1.113883.10.20.27.1.1'][@extension='2020-12-01']]/cda:custodian/cda:assignedCustodian/cda:representedCustodianOrganization">
|
598
|
+
<sch:assert id="a-4484-18165-error" test="count(cda:id) > 0">This representedCustodianOrganization SHALL contain at least one [1..*] id (CONF:4484-18165).</sch:assert>
|
599
|
+
</sch:rule>
|
600
|
+
<!-- legalAuthenticator rules -->
|
601
|
+
<sch:rule id="QRDA_Category_III_Report-legalAuthenticator-errors" context="cda:ClinicalDocument[cda:templateId[@root='2.16.840.1.113883.10.20.27.1.1'][@extension='2020-12-01']]/cda:legalAuthenticator">
|
602
|
+
<!-- 11-18-2020 added 'if present' to conformance text messages -->
|
603
|
+
<sch:assert id="a-4484-18167-error" test="count(cda:time)=1">This legalAuthenticator, if present, SHALL contain exactly one [1..1] time (CONF:4484-18167).</sch:assert>
|
604
|
+
<sch:assert id="a-4484-18168-error" test="count(cda:signatureCode)=1">This legalAuthenticator, if present, SHALL contain exactly one [1..1] signatureCode (CONF:4484-18168).</sch:assert>
|
605
|
+
<sch:assert id="a-4484-19670-error" test="count(cda:assignedEntity)=1">This legalAuthenticator, if present SHALL contain exactly one [1..1] assignedEntity (CONF:4484-19670).</sch:assert>
|
606
|
+
</sch:rule>
|
607
|
+
<sch:rule id="QRDA_Category_III_Report-legalAuthenticator-signatureCode-errors" context="cda:ClinicalDocument[cda:templateId[@root='2.16.840.1.113883.10.20.27.1.1'][@extension='2020-12-01']]/cda:legalAuthenticator/cda:signatureCode">
|
608
|
+
<!-- 11-18-2020 added STATIC oid to conformance text message -->
|
609
|
+
<sch:assert id="a-4484-18169-error" test="@code='S'">This signatureCode SHALL contain exactly one [1..1] @code="S" (CodeSystem: HL7ParticipationSignature urn:oid:2.16.840.1.113883.5.89 STATIC) (CONF:4484-18169).</sch:assert>
|
610
|
+
</sch:rule>
|
611
|
+
<sch:rule id="QRDA_Category_III_Report-legalAuthenticator-assignedEntity-representedOrganization-errors" context="cda:ClinicalDocument[cda:templateId[@root='2.16.840.1.113883.10.20.27.1.1'][@extension='2020-12-01']]/cda:legalAuthenticator/cda:assignedEntity/cda:representedOrganization">
|
612
|
+
<sch:assert id="a-4484-19672-error" test="count(cda:id) > 0">The representedOrganization, if present, SHALL contain at least one [1..*] id (CONF:4484-19672).</sch:assert>
|
613
|
+
</sch:rule>
|
614
|
+
<!-- participant (as device) rules -->
|
615
|
+
<sch:rule id="QRDA_Category_III_Report-participant-associatedEntity-errors" context="cda:ClinicalDocument[cda:templateId[@root='2.16.840.1.113883.10.20.27.1.1'][@extension='2020-12-01']]/cda:participant[@typeCode='DEV']/cda:associatedEntity">
|
616
|
+
<sch:assert id="a-4484-18303-error" test="@classCode='RGPR'">This associatedEntity SHALL contain exactly one [1..1] @classCode="RGPR" regulated product (CodeSystem: HL7ActClass urn:oid:2.16.840.1.113883.5.6 STATIC) (CONF:4484-18303).</sch:assert>
|
617
|
+
<sch:assert id="a-4484-20954-error" test="count(cda:id) > 0">This associatedEntity SHALL contain at least one [1..*] id (CONF:4484-20954).</sch:assert>
|
618
|
+
<sch:assert id="a-4484-18308-error" test="count(cda:code)=1">This associatedEntity SHALL contain exactly one [1..1] code (CONF:4484-18308).</sch:assert>
|
619
|
+
</sch:rule>
|
620
|
+
<sch:rule id="QRDA_Category_III_Report-participant-DEV-associatedEntity-code-errors" context="cda:ClinicalDocument[cda:templateId[@root='2.16.840.1.113883.10.20.27.1.1'][@extension='2020-12-01']]/cda:participant[@typeCode='DEV']/cda:associatedEntity/cda:code">
|
621
|
+
<sch:assert id="a-4484-18309-error" test="@code='129465004'">This code SHALL contain exactly one [1..1] @code="129465004" medical record, device (CONF:4484-18309).</sch:assert>
|
622
|
+
<sch:assert id="a-4484-21167-error" test="@codeSystem='2.16.840.1.113883.6.96'">This code SHALL contain exactly one [1..1] @codeSystem="2.16.840.1.113883.6.96" (CodeSystem: SNOMED CT urn:oid:2.16.840.1.113883.6.96) (CONF:4484-21167).</sch:assert>
|
623
|
+
</sch:rule>
|
624
|
+
<!-- 11-18-2020 Added SHALL constraints for when Participant location (4484-18300) is present -->
|
625
|
+
<sch:rule id="QRDA_Category_III_Report-participant-LOC-associatedEntity-errors" context="cda:ClinicalDocument[cda:templateId[@root='2.16.840.1.113883.10.20.27.1.1'][@extension='2020-12-01']]/cda:participant[@typeCode='LOC']/cda:associatedEntity">
|
626
|
+
<sch:assert id="a-4484-21454-error" test="@classCode='SDLOC'">This associatedEntity SHALL contain exactly one [1..1] @classCode="SDLOC" Service Delivery Location (CONF:4484-21454).</sch:assert>
|
627
|
+
<sch:assert id="a-4484-21455-error" test="count(cda:id)> 0">This associatedEntity SHALL contain at least one [1..*] id (CONF:4484-21455).</sch:assert>
|
628
|
+
<sch:assert id="a-4484-21450-error" test="count(cda:code) =1">This associatedEntity SHALL contain exactly one [1..1] code (CONF:4484-21450).</sch:assert>
|
629
|
+
<sch:assert id="a-4484-21458-error" test="count(cda:addr) =1">This associatedEntity SHALL contain exactly one [1..1] addr (CONF:4484-21458).</sch:assert>
|
630
|
+
</sch:rule>
|
631
|
+
<!-- participant (as location) rules -->
|
632
|
+
<!-- 11-18-2020 Added SHALL constraints to associatedEntity code for when Participant location (4484-21448) is present -->
|
633
|
+
<sch:rule id="QRDA_Category_III_Report-participant-LOC-associatedEntity-code-errors" context="cda:ClinicalDocument[cda:templateId[@root='2.16.840.1.113883.10.20.27.1.1'][@extension='2020-12-01']]/cda:participant[@typeCode='LOC']/cda:associatedEntity/cda:code">
|
634
|
+
<sch:assert id="a-4484-18300-21456-error" test="@code='394730007'">This code SHALL contain exactly one [1..1] @code="394730007" Healthcare Related Organization (CONF:4484-21456).</sch:assert>
|
635
|
+
<sch:assert id="a-4484-18300-iii-2-error" test="@codeSystem='2.16.840.1.113883.6.96'">This code SHALL contain exactly one [1..1] @codeSystem (CodeSystem: SNOMED CT urn:oid:2.16.840.1.113883.6.96) (CONF:4484-21457).</sch:assert>
|
636
|
+
</sch:rule>
|
637
|
+
<!-- documentation rules -->
|
638
|
+
<sch:rule id="QRDA_Category_III_Report-documentationOf-errors" context="cda:ClinicalDocument[cda:templateId[@root='2.16.840.1.113883.10.20.27.1.1'][@extension='2020-12-01']]/cda:documentationOf">
|
639
|
+
<sch:assert id="a-4484-18171-error" test="count(cda:serviceEvent)=1">The documentationOf, if present, SHALL contain exactly one [1..1] serviceEvent (CONF:4484-18171).</sch:assert>
|
640
|
+
</sch:rule>
|
641
|
+
<sch:rule id="QRDA_Category_III_Report-documentationOf-serviceEvent-errors" context="cda:ClinicalDocument[cda:templateId[@root='2.16.840.1.113883.10.20.27.1.1'][@extension='2020-12-01']]/cda:documentationOf/cda:serviceEvent">
|
642
|
+
<sch:assert id="a-4484-18172-error" test="@classCode='PCPR'">This serviceEvent SHALL contain exactly one [1..1] @classCode="PCPR" Care Provision (CodeSystem: HL7ActClass urn:oid:2.16.840.1.113883.5.6 STATIC) (CONF:4484-18172).</sch:assert>
|
643
|
+
<sch:assert id="a-4484-18173-error" test="count(cda:performer) > 0">This serviceEvent SHALL contain at least one [1..*] performer (CONF:4484-18173).</sch:assert>
|
644
|
+
</sch:rule>
|
645
|
+
<sch:rule id="QRDA_Category_III_Report-documentationOf-serviceEvent-performer-errors" context="cda:ClinicalDocument[cda:templateId[@root='2.16.840.1.113883.10.20.27.1.1'][@extension='2020-12-01']]/cda:documentationOf/cda:serviceEvent/cda:performer">
|
646
|
+
<sch:assert id="a-4484-18174-error" test="@typeCode='PRF'">Such performers SHALL contain exactly one [1..1] @typeCode="PRF" Performer (CodeSystem: HL7ParticipationType urn:oid:2.16.840.1.113883.5.90 STATIC) (CONF:4484-18174).</sch:assert>
|
647
|
+
<sch:assert id="a-4484-18176-error" test="count(cda:assignedEntity)=1">Such performers SHALL contain exactly one [1..1] assignedEntity (CONF:4484-18176).</sch:assert>
|
648
|
+
</sch:rule>
|
649
|
+
<sch:rule id="QRDA_Category_III_Report-documentationOf-serviceEvent-performer-assignedEntity-errors" context="cda:ClinicalDocument[cda:templateId[@root='2.16.840.1.113883.10.20.27.1.1'][@extension='2020-12-01']]/cda:documentationOf/cda:serviceEvent/cda:performer/cda:assignedEntity">
|
650
|
+
<sch:assert id="a-4484-19474-error" test="count(cda:id) > 0">This assignedEntity SHALL contain at least one [1..*] id (CONF:4484-19474).</sch:assert>
|
651
|
+
<sch:assert id="a-4484-18180-error" test="count(cda:representedOrganization)=1">This assignedEntity SHALL contain exactly one [1..1] representedOrganization (CONF:4484-18180).</sch:assert>
|
652
|
+
</sch:rule>
|
653
|
+
<!-- authorization rules -->
|
654
|
+
<sch:rule id="QRDA_Category_III_Report-authorization-errors" context="cda:ClinicalDocument[cda:templateId[@root='2.16.840.1.113883.10.20.27.1.1'][@extension='2020-12-01']]/cda:authorization">
|
655
|
+
<sch:assert id="a-4484-18360-error" test="count(cda:consent)=1">The authorization, if present, SHALL contain exactly one [1..1] consent (CONF:4484-18360).</sch:assert>
|
656
|
+
</sch:rule>
|
657
|
+
<sch:rule id="QRDA_Category_III_Report-authorization-consent-errors" context="cda:ClinicalDocument[cda:templateId[@root='2.16.840.1.113883.10.20.27.1.1'][@extension='2020-12-01']]/cda:authorization/cda:consent">
|
658
|
+
<sch:assert id="a-4484-18361-error" test="count(cda:id)=1">This consent SHALL contain exactly one [1..1] id (CONF:4484-18361).</sch:assert>
|
659
|
+
<sch:assert id="a-4484-18363-error" test="count(cda:code)=1">This consent SHALL contain exactly one [1..1] code (CONF:4484-18363).</sch:assert>
|
660
|
+
<sch:assert id="a-4484-18364-error" test="count(cda:statusCode)=1">This consent SHALL contain exactly one [1..1] statusCode (CONF:4484-18364).</sch:assert>
|
661
|
+
</sch:rule>
|
662
|
+
<sch:rule id="QRDA_Category_III_Report-authorization-consent-code-errors" context="cda:ClinicalDocument[cda:templateId[@root='2.16.840.1.113883.10.20.27.1.1'][@extension='2020-12-01']]/cda:authorization/cda:consent/cda:code">
|
663
|
+
<sch:assert id="a-4484-19550-error" test="@code='425691002'">This code SHALL contain exactly one [1..1] @code="425691002" Consent given for electronic record sharing (CONF:4484-19550).</sch:assert>
|
664
|
+
<sch:assert id="a-4484-21172-error" test="@codeSystem='2.16.840.1.113883.6.96'">This code SHALL contain exactly one [1..1] @codeSystem="2.16.840.1.113883.6.96" (CodeSystem: SNOMED CT urn:oid:2.16.840.1.113883.6.96) (CONF:4484-21172).</sch:assert>
|
665
|
+
</sch:rule>
|
666
|
+
<sch:rule id="QRDA_Category_III_Report-authorization-consent-statusCode-errors" context="cda:ClinicalDocument[cda:templateId[@root='2.16.840.1.113883.10.20.27.1.1'][@extension='2020-12-01']]/cda:authorization/cda:consent/cda:statusCode">
|
667
|
+
<sch:assert id="a-4484-19551-error" test="@code='completed'">This statusCode SHALL contain exactly one [1..1] @code="completed" Completed (CodeSystem: ActStatus urn:oid:2.16.840.1.113883.5.14) (CONF:4484-19551).</sch:assert>
|
668
|
+
</sch:rule>
|
669
|
+
<!-- component rules -->
|
670
|
+
<sch:rule id="QRDA_Category_III_Report-component-errors" context="cda:ClinicalDocument[cda:templateId[@root='2.16.840.1.113883.10.20.27.1.1'][@extension='2020-12-01']]/cda:component">
|
671
|
+
<sch:assert id="a-4484-17235-error" test="count(cda:structuredBody)=1">This component SHALL contain exactly one [1..1] structuredBody (CONF:4484-17235).</sch:assert>
|
672
|
+
</sch:rule>
|
673
|
+
<sch:rule id="QRDA_Category_III_Report-component-structuredBody-errors" context="cda:ClinicalDocument[cda:templateId[@root='2.16.840.1.113883.10.20.27.1.1'][@extension='2020-12-01']]/cda:component/cda:structuredBody">
|
674
|
+
<!-- 11-18-2020 Updated section names in message text -->
|
675
|
+
<sch:assert id="a-4484-21394-error" test="count(cda:component[count(cda:section[cda:templateId[@root='2.16.840.1.113883.10.20.27.2.1'][@extension='2020-12-01']])=1])=1 or count(cda:component[count(cda:section[cda:templateId[@root='2.16.840.1.113883.10.20.27.2.4'][@extension='2020-12-01']])=1])=1 or count(cda:component[count(cda:section[cda:templateId[@root='2.16.840.1.113883.10.20.27.2.5'][@extension='2020-12-01']])=1])=1">This structuredBody SHALL contain at least a QRDA Category III Measure Section (V5), or an Improvement Activity Section (V3), or an Promoting Interoperability Measure Section (V3) (CONF:4484-21394).</sch:assert>
|
676
|
+
</sch:rule>
|
677
|
+
</sch:pattern>
|
678
|
+
<sch:pattern id="Race_Supplemental_Data_Element-pattern-extension-check">
|
679
|
+
<sch:rule id="Race_Supplemental_Data_Element-extension-check" context="cda:observation/cda:templateId[@root='2.16.840.1.113883.10.20.27.3.8']">
|
680
|
+
<sch:assert id="a-3259-18225-extension-error" test="@extension='2016-09-01'">SHALL contain exactly one [1..1] templateId (CONF:3259-18225) such that it SHALL contain exactly one [1..1] @root="2.16.840.1.113883.10.20.27.3.8" (CONF:3259-18226). SHALL contain exactly one [1..1] @extension="2016-09-01" (CONF:3259-21178).</sch:assert>
|
681
|
+
</sch:rule>
|
682
|
+
</sch:pattern>
|
683
|
+
<sch:pattern id="Race_Supplemental_Data_Element-pattern-errors">
|
684
|
+
<sch:rule id="Race_Supplemental_Data_Element-errors" context="cda:observation[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.8'][@extension='2016-09-01']]">
|
685
|
+
<sch:assert id="a-3259-18223-error" test="@classCode='OBS'">SHALL contain exactly one [1..1] @classCode="OBS" (CodeSystem: HL7ActClass urn:oid:2.16.840.1.113883.5.6 STATIC) (CONF:3259-18223).</sch:assert>
|
686
|
+
<sch:assert id="a-3259-18224-error" test="@moodCode='EVN'">SHALL contain exactly one [1..1] @moodCode="EVN" (CodeSystem: ActMood urn:oid:2.16.840.1.113883.5.1001 STATIC) (CONF:3259-18224).</sch:assert>
|
687
|
+
<sch:assert id="a-3259-18225-error" test="count(cda:templateId[@root='2.16.840.1.113883.10.20.27.3.8'][@extension='2016-09-01'])=1">SHALL contain exactly one [1..1] templateId (CONF:3259-18225) such that it SHALL contain exactly one [1..1] @root="2.16.840.1.113883.10.20.27.3.8" (CONF:3259-18226). SHALL contain exactly one [1..1] @extension="2016-09-01" (CONF:3259-21178).</sch:assert>
|
688
|
+
<sch:assert id="a-3259-18227-error" test="count(cda:code)=1">SHALL contain exactly one [1..1] code (CONF:3259-18227).</sch:assert>
|
689
|
+
<sch:assert id="a-3259-18112-error" test="count(cda:statusCode)=1">SHALL contain exactly one [1..1] statusCode (CONF:3259-18112).</sch:assert>
|
690
|
+
<sch:assert id="a-3259-18114-error" test="count(cda:entryRelationship[@typeCode='SUBJ'][@inversionInd='true'][count(cda:observation[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.3']])=1])=1">SHALL contain exactly one [1..1] entryRelationship (CONF:3259-18114) such that it SHALL contain exactly one [1..1] @typeCode="SUBJ" Has Subject (CodeSystem: HL7ActRelationshipType urn:oid:2.16.840.1.113883.5.1002 STATIC) (CONF:3259-18115). SHALL contain exactly one [1..1] @inversionInd="true" (CONF:3259-18116). SHALL contain exactly one [1..1] Aggregate Count (identifier: urn:oid:2.16.840.1.113883.10.20.27.3.3) (CONF:3259-18117).</sch:assert>
|
691
|
+
<sch:assert id="a-3259-18229-error" test="count(cda:value[@xsi:type='CD'])=1">SHALL contain exactly one [1..1] value with @xsi:type="CD", where the code SHALL be selected from ValueSet Race urn:oid:2.16.840.1.114222.4.11.836 DYNAMIC (CONF:3259-18229).</sch:assert>
|
692
|
+
</sch:rule>
|
693
|
+
<sch:rule id="Race_Supplemental_Data_Element-code-errors" context="cda:observation[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.8'][@extension='2016-09-01']]/cda:code">
|
694
|
+
<sch:assert id="a-3259-18228-error" test="@code='72826-1'">This code SHALL contain exactly one [1..1] @code="72826-1" Race (CONF:3259-18228).</sch:assert>
|
695
|
+
<sch:assert id="a-3259-21447-error" test="@codeSystem='2.16.840.1.113883.6.1'">This code SHALL contain exactly one [1..1] @codeSystem="2.16.840.1.113883.6.1" (CodeSystem: LOINC urn:oid:2.16.840.1.113883.6.1) (CONF:3259-21447).</sch:assert>
|
696
|
+
</sch:rule>
|
697
|
+
<sch:rule id="Race_Supplemental_Data_Element-statusCode-errors" context="cda:observation[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.8'][@extension='2016-09-01']]/cda:statusCode">
|
698
|
+
<sch:assert id="a-3259-18113-error" test="@code='completed'">This statusCode SHALL contain exactly one [1..1] @code="completed" Completed (CodeSystem: ActStatus urn:oid:2.16.840.1.113883.5.14 STATIC) (CONF:3259-18113).</sch:assert>
|
699
|
+
</sch:rule>
|
700
|
+
</sch:pattern>
|
701
|
+
<sch:pattern id="Reporting_Rate_for_Proportion_Measure-pattern-errors">
|
702
|
+
<sch:rule id="Reporting_Rate_for_Proportion_Measure-errors" context="cda:observation[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.15']]">
|
703
|
+
<sch:assert id="a-77-18411-error" test="@classCode='OBS'">SHALL contain exactly one [1..1] @classCode="OBS" Observation (CodeSystem: HL7ActClass urn:oid:2.16.840.1.113883.5.6 STATIC) (CONF:77-18411).</sch:assert>
|
704
|
+
<sch:assert id="a-77-18412-error" test="@moodCode='EVN'">SHALL contain exactly one [1..1] @moodCode="EVN" Event (CodeSystem: ActMood urn:oid:2.16.840.1.113883.5.1001 STATIC) (CONF:77-18412).</sch:assert>
|
705
|
+
<sch:assert id="a-77-21157-error" test="count(cda:templateId[@root='2.16.840.1.113883.10.20.27.3.15'][not(@extension)])=1">SHALL contain exactly one [1..1] templateId (CONF:77-21157) such that it SHALL contain exactly one [1..1] @root="2.16.840.1.113883.10.20.27.3.15" (CONF:77-21158).</sch:assert>
|
706
|
+
<sch:assert id="a-77-18413-error" test="count(cda:code)=1">SHALL contain exactly one [1..1] code (CONF:77-18413).</sch:assert>
|
707
|
+
<sch:assert id="a-77-18419-error" test="count(cda:statusCode)=1">SHALL contain exactly one [1..1] statusCode (CONF:77-18419).</sch:assert>
|
708
|
+
<sch:assert id="a-77-18415-error" test="count(cda:value[@xsi:type='REAL'])=1">SHALL contain exactly one [1..1] value with @xsi:type="REAL" (CONF:77-18415).</sch:assert>
|
709
|
+
</sch:rule>
|
710
|
+
<sch:rule id="Reporting_Rate_for_Proportion_Measure-code-errors" context="cda:observation[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.15']]/cda:code">
|
711
|
+
<sch:assert id="a-77-18414-error" test="@code='72509-3'">This code SHALL contain exactly one [1..1] @code="72509-3" Reporting Rate (CONF:77-18414).</sch:assert>
|
712
|
+
<sch:assert id="a-77-21168-error" test="@codeSystem='2.16.840.1.113883.6.1'">This code SHALL contain exactly one [1..1] @codeSystem="2.16.840.1.113883.6.1" (CodeSystem: LOINC urn:oid:2.16.840.1.113883.6.1) (CONF:77-21168).</sch:assert>
|
713
|
+
</sch:rule>
|
714
|
+
<sch:rule id="Reporting_Rate_for_Proportion_Measure-statusCode-errors" context="cda:observation[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.15']]/cda:statusCode">
|
715
|
+
<sch:assert id="a-77-18420-error" test="@code='completed'">This statusCode SHALL contain exactly one [1..1] @code="completed" completed (CodeSystem: ActStatus urn:oid:2.16.840.1.113883.5.14 STATIC) (CONF:77-18420).</sch:assert>
|
716
|
+
</sch:rule>
|
717
|
+
<sch:rule id="Reporting_Rate_for_Proportion_Measure-referenceRange-errors" context="cda:observation[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.15']]/cda:referenceRange">
|
718
|
+
<sch:assert id="a-77-18417-error" test="count(cda:observationRange)=1">The referenceRange, if present, SHALL contain exactly one [1..1] observationRange (CONF:77-18417).</sch:assert>
|
719
|
+
</sch:rule>
|
720
|
+
<sch:rule id="Reporting_Rate_for_Proportion_Measure-referenceRange-observationRange-errors" context="cda:observation[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.15']]/cda:referenceRange/cda:observationRange">
|
721
|
+
<sch:assert id="a-77-18418-error" test="count(cda:value[@xsi:type='REAL'])=1">This observationRange SHALL contain exactly one [1..1] value with @xsi:type="REAL" (CONF:77-18418).</sch:assert>
|
722
|
+
</sch:rule>
|
723
|
+
</sch:pattern>
|
724
|
+
<sch:pattern id="Reporting_Stratum-pattern-errors">
|
725
|
+
<sch:rule id="Reporting_Stratum-errors" context="cda:observation[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.4']]">
|
726
|
+
<sch:assert id="a-77-17575-error" test="@classCode='OBS'">SHALL contain exactly one [1..1] @classCode="OBS" (CodeSystem: HL7ActClass urn:oid:2.16.840.1.113883.5.6 STATIC) (CONF:77-17575).</sch:assert>
|
727
|
+
<sch:assert id="a-77-17576-error" test="@moodCode='EVN'">SHALL contain exactly one [1..1] @moodCode="EVN" (CodeSystem: ActMood urn:oid:2.16.840.1.113883.5.1001 STATIC) (CONF:77-17576).</sch:assert>
|
728
|
+
<sch:assert id="a-77-18093-error" test="count(cda:templateId[@root='2.16.840.1.113883.10.20.27.3.4'][not(@extension)])=1">SHALL contain exactly one [1..1] templateId (CONF:77-18093) such that it SHALL contain exactly one [1..1] @root="2.16.840.1.113883.10.20.27.3.4" (CONF:77-18094).</sch:assert>
|
729
|
+
<sch:assert id="a-77-17577-error" test="count(cda:code)=1">SHALL contain exactly one [1..1] code (CONF:77-17577).</sch:assert>
|
730
|
+
<sch:assert id="a-77-17579-error" test="count(cda:statusCode)=1">SHALL contain exactly one [1..1] statusCode (CONF:77-17579).</sch:assert>
|
731
|
+
<sch:assert id="a-77-17581-error" test="count(cda:entryRelationship[@typeCode='SUBJ'][@inversionInd='true'][count(cda:observation[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.3']])=1])=1">SHALL contain exactly one [1..1] entryRelationship (CONF:77-17581) such that it SHALL contain exactly one [1..1] @typeCode="SUBJ" (CONF:77-17582). SHALL contain exactly one [1..1] @inversionInd="true" (CONF:77-17583). SHALL contain exactly one [1..1] Aggregate Count (identifier: urn:oid:2.16.840.1.113883.10.20.27.3.3) (CONF:77-17584).</sch:assert>
|
732
|
+
<sch:assert id="a-77-18204-error" test="count(cda:reference)=1">SHALL contain exactly one [1..1] reference (CONF:77-18204).</sch:assert>
|
733
|
+
</sch:rule>
|
734
|
+
<sch:rule id="Reporting_Stratum-code-errors" context="cda:observation[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.4']]/cda:code">
|
735
|
+
<sch:assert id="a-77-17578-error" test="@code='ASSERTION'">This code SHALL contain exactly one [1..1] @code="ASSERTION" Assertion (CONF:77-17578).</sch:assert>
|
736
|
+
<sch:assert id="a-77-21169-error" test="@codeSystem='2.16.840.1.113883.5.4'">This code SHALL contain exactly one [1..1] @codeSystem="2.16.840.1.113883.5.4" (CodeSystem: ActCode urn:oid:2.16.840.1.113883.5.4) (CONF:77-21169).</sch:assert>
|
737
|
+
</sch:rule>
|
738
|
+
<sch:rule id="Reporting_Stratum-statusCode-errors" context="cda:observation[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.4']]/cda:statusCode">
|
739
|
+
<sch:assert id="a-77-18201-error" test="@code='completed'">This statusCode SHALL contain exactly one [1..1] @code="completed" Completed (CodeSystem: ActStatus urn:oid:2.16.840.1.113883.5.14 STATIC) (CONF:77-18201).</sch:assert>
|
740
|
+
</sch:rule>
|
741
|
+
<sch:rule id="Reporting_Stratum-reference-errors" context="cda:observation[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.4']]/cda:reference">
|
742
|
+
<sch:assert id="a-77-18205-error" test="@typeCode='REFR'">This reference SHALL contain exactly one [1..1] @typeCode="REFR" (CodeSystem: HL7ActRelationshipType urn:oid:2.16.840.1.113883.5.1002 STATIC) (CONF:77-18205).</sch:assert>
|
743
|
+
<sch:assert id="a-77-18206-error" test="count(cda:externalObservation)=1">This reference SHALL contain exactly one [1..1] externalObservation (CONF:77-18206).</sch:assert>
|
744
|
+
</sch:rule>
|
745
|
+
<sch:rule id="Reporting_Stratum-reference-externalObservation-errors" context="cda:observation[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.4']]/cda:reference/cda:externalObservation">
|
746
|
+
<sch:assert id="a-77-18207-error" test="count(cda:id)=1">This externalObservation SHALL contain exactly one [1..1] id (CONF:77-18207).</sch:assert>
|
747
|
+
</sch:rule>
|
748
|
+
</sch:pattern>
|
749
|
+
<sch:pattern id="Sex_Supplemental_Data_Element-pattern-extension-check">
|
750
|
+
<sch:rule id="Sex_Supplemental_Data_Element-extension-check" context="cda:observation/cda:templateId[@root='2.16.840.1.113883.10.20.27.3.6']">
|
751
|
+
<sch:assert id="a-3259-18232-extension-error" test="@extension='2016-09-01'">SHALL contain exactly one [1..1] templateId (CONF:3259-18232) such that it SHALL contain exactly one [1..1] @root="2.16.840.1.113883.10.20.27.3.6" (CONF:3259-18233). SHALL contain exactly one [1..1] @extension="2016-09-01" (CONF:3259-21160).</sch:assert>
|
752
|
+
</sch:rule>
|
753
|
+
</sch:pattern>
|
754
|
+
<sch:pattern id="Sex_Supplemental_Data_Element-pattern-errors">
|
755
|
+
<sch:rule id="Sex_Supplemental_Data_Element-errors" context="cda:observation[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.6'][@extension='2016-09-01']]">
|
756
|
+
<sch:assert id="a-3259-18230-error" test="@classCode='OBS'">SHALL contain exactly one [1..1] @classCode="OBS" (CodeSystem: HL7ActClass urn:oid:2.16.840.1.113883.5.6 STATIC) (CONF:3259-18230).</sch:assert>
|
757
|
+
<sch:assert id="a-3259-18231-error" test="@moodCode='EVN'">SHALL contain exactly one [1..1] @moodCode="EVN" (CodeSystem: ActMood urn:oid:2.16.840.1.113883.5.1001 STATIC) (CONF:3259-18231).</sch:assert>
|
758
|
+
<sch:assert id="a-3259-18232-error" test="count(cda:templateId[@root='2.16.840.1.113883.10.20.27.3.6'][@extension='2016-09-01'])=1">SHALL contain exactly one [1..1] templateId (CONF:3259-18232) such that it SHALL contain exactly one [1..1] @root="2.16.840.1.113883.10.20.27.3.6" (CONF:3259-18233). SHALL contain exactly one [1..1] @extension="2016-09-01" (CONF:3259-21160).</sch:assert>
|
759
|
+
<sch:assert id="a-3259-18234-error" test="count(cda:code)=1">SHALL contain exactly one [1..1] code (CONF:3259-18234).</sch:assert>
|
760
|
+
<sch:assert id="a-3259-18124-error" test="count(cda:statusCode)=1">SHALL contain exactly one [1..1] statusCode (CONF:3259-18124).</sch:assert>
|
761
|
+
<sch:assert id="a-3259-18236-error" test="count(cda:value[@xsi:type='CD'])=1">SHALL contain exactly one [1..1] value with @xsi:type="CD", where the code SHALL be selected from ValueSet ONC Administrative Sex urn:oid:2.16.840.1.113762.1.4.1 DYNAMIC (CONF:3259-18236).</sch:assert>
|
762
|
+
<sch:assert id="a-3259-18126-error" test="count(cda:entryRelationship[@typeCode='SUBJ'][@inversionInd='true'][count(cda:observation[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.3']])=1])=1">SHALL contain exactly one [1..1] entryRelationship (CONF:3259-18126) such that it SHALL contain exactly one [1..1] @typeCode="SUBJ" Has Subject (CodeSystem: HL7ActRelationshipType urn:oid:2.16.840.1.113883.5.1002 STATIC) (CONF:3259-18127). SHALL contain exactly one [1..1] @inversionInd="true" (CONF:3259-18128). SHALL contain exactly one [1..1] Aggregate Count (identifier: urn:oid:2.16.840.1.113883.10.20.27.3.3) (CONF:3259-18129).</sch:assert>
|
763
|
+
</sch:rule>
|
764
|
+
<sch:rule id="Sex_Supplemental_Data_Element-code-errors" context="cda:observation[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.6'][@extension='2016-09-01']]/cda:code">
|
765
|
+
<sch:assert id="a-3259-18235-error" test="@code='76689-9'">This code SHALL contain exactly one [1..1] @code="76689-9" Sex assigned at birth (CONF:3259-18235).</sch:assert>
|
766
|
+
<sch:assert id="a-3259-21163-error" test="@codeSystem='2.16.840.1.113883.6.1'">This code SHALL contain exactly one [1..1] @codeSystem="2.16.840.1.113883.6.1" (CodeSystem: LOINC urn:oid:2.16.840.1.113883.6.1 STATIC) (CONF:3259-21163).</sch:assert>
|
767
|
+
</sch:rule>
|
768
|
+
<sch:rule id="Sex_Supplemental_Data_Element-statusCode-errors" context="cda:observation[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.6'][@extension='2016-09-01']]/cda:statusCode">
|
769
|
+
<sch:assert id="a-3259-18125-error" test="@code='completed'">This statusCode SHALL contain exactly one [1..1] @code="completed" Completed (CodeSystem: ActStatus urn:oid:2.16.840.1.113883.5.14 STATIC) (CONF:3259-18125).</sch:assert>
|
770
|
+
</sch:rule>
|
771
|
+
</sch:pattern>
|
772
|
+
<sch:pattern id="Measure-section-pattern-errors">
|
773
|
+
<sch:rule id="Measure-section-errors" context="cda:section[cda:templateId[@root='2.16.840.1.113883.10.20.24.2.2']]">
|
774
|
+
<sch:assert id="a-67-12801-error" test="count(cda:templateId[@root='2.16.840.1.113883.10.20.24.2.2'][not(@extension)])=1">SHALL contain exactly one [1..1] templateId (CONF:67-12801) such that it SHALL contain exactly one [1..1] @root="2.16.840.1.113883.10.20.24.2.2" (CONF:67-12802).</sch:assert>
|
775
|
+
<sch:assert id="a-67-12798-error" test="count(cda:code)=1">SHALL contain exactly one [1..1] code (CONF:67-12798).</sch:assert>
|
776
|
+
<sch:assert id="a-67-12799-error" test="count(cda:title[translate(text(), 'ABCDEFGHIJKLMNOPQRSTUVWXYZ', 'abcdefghijklmnopqrstuvwxyz')='measure section'])=1">SHALL contain exactly one [1..1] title="Measure Section" (CONF:67-12799).</sch:assert>
|
777
|
+
<sch:assert id="a-67-12800-error" test="count(cda:text)=1">SHALL contain exactly one [1..1] text (CONF:67-12800).</sch:assert>
|
778
|
+
<sch:assert id="a-67-13003-error" test="count(cda:entry[cda:organizer[cda:templateId[@root='2.16.840.1.113883.10.20.24.3.98']]]) > 0">SHALL contain at least one [1..*] entry (CONF:67-13003) such that it SHALL contain exactly one [1..1] Measure Reference (identifier: urn:oid:2.16.840.1.113883.10.20.24.3.98) (CONF:67-16677).</sch:assert>
|
779
|
+
</sch:rule>
|
780
|
+
<sch:rule id="Measure-section-code-errors" context="cda:section[cda:templateId[@root='2.16.840.1.113883.10.20.24.2.2']]/cda:code">
|
781
|
+
<sch:assert id="a-67-19230-error" test="@code='55186-1'">This code SHALL contain exactly one [1..1] @code="55186-1" Measure Section (CONF:67-19230).</sch:assert>
|
782
|
+
<sch:assert id="a-67-27012-error" test="@codeSystem='2.16.840.1.113883.6.1'">This code SHALL contain exactly one [1..1] @codeSystem="2.16.840.1.113883.6.1" (CodeSystem: LOINC urn:oid:2.16.840.1.113883.6.1) (CONF:67-27012).</sch:assert>
|
783
|
+
</sch:rule>
|
784
|
+
</sch:pattern>
|
785
|
+
<sch:pattern id="Reporting-Parameters-Act-pattern-extension-check">
|
786
|
+
<sch:rule id="Reporting-Parameters-Act-extension-check" context="cda:act/cda:templateId[@root='2.16.840.1.113883.10.20.17.3.8']">
|
787
|
+
<sch:assert id="a-4484-1098-extension-error" test="@extension='2020-12-01'">SHALL contain exactly one [1..1] templateId (CONF:4484-18098) such that it SHALL contain exactly one [1..1] @root="2.16.840.1.113883.10.20.17.3.8" (CONF:4484-18099). SHALL contain exactly one [1..1] @extension="2020-12-01" (CONF:4484-26552).</sch:assert>
|
788
|
+
</sch:rule>
|
789
|
+
</sch:pattern>
|
790
|
+
<sch:pattern id="Reporting-Parameters-Act-pattern-errors">
|
791
|
+
<sch:rule id="Reporting-Parameters-Act-errors" context="cda:act[cda:templateId[@root='2.16.840.1.113883.10.20.17.3.8'][@extension='2020-12-01']]">
|
792
|
+
<sch:assert id="a-4484-3269-error" test="@classCode='ACT'">SHALL contain exactly one [1..1] @classCode="ACT" (CodeSystem: HL7ActClass urn:oid:2.16.840.1.113883.5.6 STATIC) (CONF:4484-3269).</sch:assert>
|
793
|
+
<sch:assert id="a-4484-3270-error" test="@moodCode='EVN'">SHALL contain exactly one [1..1] @moodCode="EVN" Event (CodeSystem: ActMood urn:oid:2.16.840.1.113883.5.1001 STATIC) (CONF:4484-3270).</sch:assert>
|
794
|
+
<sch:assert id="a-4484-18098-error" test="count(cda:templateId[@root='2.16.840.1.113883.10.20.17.3.8'][@extension='2020-12-01'])=1">SHALL contain exactly one [1..1] templateId (CONF:4484-18098) such that it SHALL contain exactly one [1..1] @root="2.16.840.1.113883.10.20.17.3.8" (CONF:4484-18099). SHALL contain exactly one [1..1] @extension="2020-12-01" (CONF:4484-26552).</sch:assert>
|
795
|
+
<sch:assert id="a-4484-26549-error" test="count(cda:id) >= 1">SHALL contain at least one [1..*] id (CONF:4484-26549).</sch:assert>
|
796
|
+
<sch:assert id="a-4484-3272-error" test="count(cda:code)=1">SHALL contain exactly one [1..1] code (CONF:4484-3272).</sch:assert>
|
797
|
+
<sch:assert id="a-4484-3273-error" test="count(cda:effectiveTime)=1">SHALL contain exactly one [1..1] effectiveTime (CONF:4484-3273).</sch:assert>
|
798
|
+
</sch:rule>
|
799
|
+
<sch:rule id="Reporting-Parameters-Act-code-errors" context="cda:act[cda:templateId[@root='2.16.840.1.113883.10.20.17.3.8'][@extension='2020-12-01']]/cda:code">
|
800
|
+
<sch:assert id="a-4484-26550-error" test="@code='252116004'">This code SHALL contain exactly one [1..1] @code="252116004" Observation Parameters (CONF:4484-26550).</sch:assert>
|
801
|
+
<sch:assert id="a-4484-26551-error" test="@codeSystem='2.16.840.1.113883.6.96'">This code SHALL contain exactly one [1..1] @codeSystem="2.16.840.1.113883.6.96" (CodeSystem: SNOMED CT urn:oid:2.16.840.1.113883.6.96) (CONF:4484-26551).</sch:assert>
|
802
|
+
</sch:rule>
|
803
|
+
<sch:rule id="Reporting-Parameters-Act-effectiveTime-errors" context="cda:act[cda:templateId[@root='2.16.840.1.113883.10.20.17.3.8'][@extension='2020-12-01']]/cda:effectiveTime">
|
804
|
+
<sch:assert id="a-4484-3274-error" test="count(cda:low)=1">This effectiveTime SHALL contain exactly one [1..1] low (CONF:4484-3274).</sch:assert>
|
805
|
+
<sch:assert id="a-4484-3275-error" test="count(cda:high)=1">This effectiveTime SHALL contain exactly one [1..1] high (CONF:4484-3275).</sch:assert>
|
806
|
+
</sch:rule>
|
807
|
+
<!-- 12-02-02 Added constraints on effective time low value -->
|
808
|
+
<sch:rule id="Reporting-Parameters-Act-effectiveTime-low-errors" context="cda:act[cda:templateId[@root='2.16.840.1.113883.10.20.17.3.8'][@extension='2020-12-01']]/cda:effectiveTime/cda:low">
|
809
|
+
<sch:assert id="a-4484-26553-error" test="@value">This low SHALL contain exactly one [1..1] @value (CONF:4484-26553).</sch:assert>
|
810
|
+
<sch:assert id="a-4484-26554-error" test="string-length(@value) >= 8">SHALL be precise to day (CONF:4484-26554).</sch:assert>
|
811
|
+
</sch:rule>
|
812
|
+
<!-- 12-02-02 Added constraints on effective time high value -->
|
813
|
+
<sch:rule id="Reporting-Parameters-Act-effectiveTime-high-errors" context="cda:act[cda:templateId[@root='2.16.840.1.113883.10.20.17.3.8'][@extension='2020-12-01']]/cda:effectiveTime/cda:high">
|
814
|
+
<sch:assert id="a-4484-26555-error" test="@value">This high SHALL contain exactly one [1..1] @value (CONF:4484-26555).</sch:assert>
|
815
|
+
<sch:assert id="a-4484-26556-error" test="string-length(@value) >= 8">SHALL be precise to day (CONF:4484-26556).</sch:assert>
|
816
|
+
</sch:rule>
|
817
|
+
</sch:pattern>
|
818
|
+
<!--
|
819
|
+
WARNING Patterns and Assertions
|
820
|
+
-->
|
821
|
+
<sch:pattern id="Improvement_Activity_Performed_Reference_and_Result-pattern-warnings">
|
822
|
+
<sch:rule id="Improvement_Activity_Performed_Reference_and_Result-warnings" context="cda:organizer[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.33'][@extension='2016-09-01']]/cda:reference/cda:externalDocument">
|
823
|
+
<sch:assert id="a-3259-21429-warning" test="count(cda:text)=1">This externalDocument SHOULD contain zero or one [0..1] text (CONF:3259-21429).</sch:assert>
|
824
|
+
</sch:rule>
|
825
|
+
</sch:pattern>
|
826
|
+
<sch:pattern id="Measure_Reference-pattern-warnings">
|
827
|
+
<sch:rule id="Measure_Reference-reference-externalDocument-warnings" context="cda:organizer[cda:templateId[@root='2.16.840.1.113883.10.20.24.3.98']]/cda:reference/cda:externalDocument">
|
828
|
+
<sch:assert id="a-67-12997-warning" test="count(cda:text)=1">This externalDocument SHOULD contain zero or one [0..1] text (CONF:67-12997).</sch:assert>
|
829
|
+
</sch:rule>
|
830
|
+
</sch:pattern>
|
831
|
+
<sch:pattern id="Measure_Reference_and_Results-pattern-warnings">
|
832
|
+
<sch:rule id="Measure_Reference_and_Results-warnings" context="cda:organizer[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.1'][@extension='2020-12-01']]">
|
833
|
+
<sch:assert id="a-4484-18353-warning" test="count(cda:reference[count(cda:externalObservation)=1])=1">SHOULD contain exactly one [1..1] reference (CONF:4484-18353) such that it SHALL contain exactly one [1..1] externalObservation (CONF:4484-18354).</sch:assert>
|
834
|
+
</sch:rule>
|
835
|
+
<sch:rule id="Measure_Reference_and_Results-reference-externalDocument-warnings" context="cda:organizer[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.1'][@extension='2020-12-01']]/cda:reference/cda:externalDocument">
|
836
|
+
<sch:assert id="a-4484-17896-warning" test="count(cda:code)=1">This externalDocument SHOULD contain zero or one [0..1] code (CodeSystem: LOINC urn:oid:2.16.840.1.113883.6.1 STATIC) (CONF:4484-17896).</sch:assert>
|
837
|
+
<sch:assert id="a-4484-17897-warning" test="count(cda:text)=1">This externalDocument SHOULD contain zero or one [0..1] text (CONF:4484-17897).</sch:assert>
|
838
|
+
</sch:rule>
|
839
|
+
</sch:pattern>
|
840
|
+
<sch:pattern id="Promoting_Interoperability_Measure_Performed_Reference_and_Result-pattern-warnings">
|
841
|
+
<sch:rule id="Promoting_Interoperability_Measure_Performed_Reference_and_Result_reference_externalDocument-warnings" context="cda:organizer[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.29'][@extension='2016-09-01']]/cda:reference/cda:externalDocument">
|
842
|
+
<sch:assert id="a-3259-21414-warning" test="count(cda:text)=1">This externalDocument SHOULD contain zero or one [0..1] text (CONF:3259-21414).</sch:assert>
|
843
|
+
</sch:rule>
|
844
|
+
</sch:pattern>
|
845
|
+
<sch:pattern id="Promoting_Interoperability_Numerator_Denominator_Measure_Reference_and_Results-pattern-warnings">
|
846
|
+
<sch:rule id="Promoting_Interoperability_Numerator_Denominator_Measure_Reference_and_Results-reference-externalDocument-warnings" context="cda:organizer[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.28'][@extension='2017-06-01']]/cda:reference/cda:externalDocument">
|
847
|
+
<sch:assert id="a-3338-21263-warning" test="count(cda:text)=1">This externalDocument SHOULD contain zero or one [0..1] text (CONF:3338-21263).</sch:assert>
|
848
|
+
</sch:rule>
|
849
|
+
</sch:pattern>
|
850
|
+
<sch:pattern id="QRDA_Category_III_Report-pattern-warnings">
|
851
|
+
<sch:rule id="QRDA_Category_III_Report-warnings" context="cda:ClinicalDocument[cda:templateId[@root='2.16.840.1.113883.10.20.27.1.1'][@extension='2020-12-01']]">
|
852
|
+
<sch:assert id="a-4484-17238-v-warning" test="count(cda:confidentialityCode[@code=document('voc.xml')/voc:systems/voc:system[@valueSetOid='2.16.840.1.113883.1.11.16926']/voc:code/@value])=1">SHALL contain exactly one [1..1] confidentialityCode, which SHOULD be selected from ValueSet HL7 BasicConfidentialityKind urn:oid:2.16.840.1.113883.1.11.16926 STATIC 2010-04-21 (CONF:4484-17238).</sch:assert>
|
853
|
+
<sch:assert id="a-4484-18260-warning" test="count(cda:versionNumber)=1">SHOULD contain zero or one [0..1] versionNumber (CONF:4484-18260).</sch:assert>
|
854
|
+
<!-- 11-18-2020 legalAuthenticator changed from SHALL to SHOULD -->
|
855
|
+
<sch:assert id="a-4484-17225-warning" test="count(cda:legalAuthenticator)=1">SHOULD contain zero or one [0..1] legalAuthenticator (CONF:4484-17225).</sch:assert>
|
856
|
+
</sch:rule>
|
857
|
+
<!-- custodian warnings -->
|
858
|
+
<sch:rule id="QRDA_Category_III_Report-custodian-assignedCustodian-representedCustodianOrganization-warnings" context="cda:ClinicalDocument[cda:templateId[@root='2.16.840.1.113883.10.20.27.1.1'][@extension='2020-12-01']]/cda:custodian/cda:assignedCustodian/cda:representedCustodianOrganization">
|
859
|
+
<sch:assert id="a-4484-18166-warning" test="count(cda:name)=1">This representedCustodianOrganization SHOULD contain zero or one [0..1] name (CONF:4484-18166).</sch:assert>
|
860
|
+
</sch:rule>
|
861
|
+
<!-- legalAuthenticator warnings -->
|
862
|
+
<sch:rule id="QRDA_Category_III_Report-legalAuthenticator-assignedEntity-representedOrganization-warnings" context="cda:ClinicalDocument[cda:templateId[@root='2.16.840.1.113883.10.20.27.1.1'][@extension='2020-12-01']]/cda:legalAuthenticator/cda:assignedEntity/cda:representedOrganization">
|
863
|
+
<sch:assert id="a-4484-19673-warning" test="count(cda:name)=1">The representedOrganization, if present, SHOULD contain zero or one [0..1] name (CONF:4484-19673).</sch:assert>
|
864
|
+
</sch:rule>
|
865
|
+
<!-- documentationOf warnings -->
|
866
|
+
<sch:rule id="QRDA_Category_III_Report-documentationOf-serviceEvent-performer-assignedEntity-representedOrganization-warnings" context="cda:ClinicalDocument[cda:templateId[@root='2.16.840.1.113883.10.20.27.1.1'][@extension='2020-12-01']]/cda:documentationOf/cda:serviceEvent/cda:performer/cda:assignedEntity/cda:representedOrganization">
|
867
|
+
<sch:assert id="a-4484-19659-warning" test="count(cda:name) > 0">This representedOrganization SHOULD contain zero or more [0..*] name (CONF:4484-19659).</sch:assert>
|
868
|
+
</sch:rule>
|
869
|
+
<!-- 11-18-2020 Added conformance rule warning for 4484-18177 -->
|
870
|
+
<sch:rule id="QRDA_Category_III_Report-documentationOf-serviceEvent-performer-assignedEntity-warnings" context="cda:ClinicalDocument[cda:templateId[@root='2.16.840.1.113883.10.20.27.1.1'][@extension='2020-12-01']]/cda:documentationOf/cda:serviceEvent/cda:performer/cda:assignedEntity">
|
871
|
+
<sch:assert id="a-4484-18177-warning" test="count(cda:id[@root='2.16.840.1.113883.4.6']) =1">This assignedEntity SHOULD contain zero or one [1..1] id (CONF:4484-18177) such that it SHALL contain exactly one [1..1] @root="2.16.840.1.113883.4.6" National Provider ID (CONF:4484-18178) MAY contain zero or one [0..1] @extension (CONF:4484-18247).</sch:assert>
|
872
|
+
</sch:rule>
|
873
|
+
</sch:pattern>
|
874
|
+
<sch:pattern id="Reporting_Stratum-pattern-warnings">
|
875
|
+
<sch:rule id="Reporting_Stratum-warnings" context="cda:observation[cda:templateId[@root='2.16.840.1.113883.10.20.27.3.4']]">
|
876
|
+
<sch:assert id="a-77-17580-warning" test="count(cda:value)=1">SHOULD contain zero or one [0..1] value (CONF:77-17580).</sch:assert>
|
877
|
+
</sch:rule>
|
878
|
+
</sch:pattern>
|
879
|
+
</sch:schema>
|