1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
// @generated by fhir-codegen from HL7/v2ig 9c307dadb0bb3f99de399d30cd80c24b47bb08da input/sourceOfTruth. DO NOT EDIT.
// Change the emitter (tools/fhir-codegen) and regenerate.
// SPDX-FileCopyrightText: Cadasto B.V.
// SPDX-License-Identifier: Apache-2.0
//! The `CRM_C01` message structure.
use crate::model::{
Cardinality, Group, GroupKind, Max, Node, SegmentRef, SegmentStatus, Structure,
};
use crate::segment;
/// The top-level nodes of [`CRM_C01`], one `static` so a structure with the same tree links to it.
pub static CRM_C01_NODES: [Node; 5] = [
Node::Segment(SegmentRef {
id: "CRM_C01.1-MSH",
position: 1,
segment: &segment::msh::MSH,
cardinality: Cardinality {
min: 1,
max: Max::Bounded(1),
},
status: Some(SegmentStatus::A),
}),
Node::Segment(SegmentRef {
id: "CRM_C01.2-ARV",
position: 2,
segment: &segment::arv::ARV,
cardinality: Cardinality {
min: 0,
max: Max::Unbounded,
},
status: Some(SegmentStatus::A),
}),
Node::Segment(SegmentRef {
id: "CRM_C01.3-SFT",
position: 3,
segment: &segment::sft::SFT,
cardinality: Cardinality {
min: 0,
max: Max::Unbounded,
},
status: Some(SegmentStatus::A),
}),
Node::Segment(SegmentRef {
id: "CRM_C01.4-UAC",
position: 4,
segment: &segment::uac::UAC,
cardinality: Cardinality {
min: 0,
max: Max::Bounded(1),
},
status: Some(SegmentStatus::A),
}),
Node::Group(Group {
id: "CRM_C01.5-PATIENT",
position: 5,
name: "PATIENT",
cardinality: Cardinality {
min: 1,
max: Max::Unbounded,
},
kind: GroupKind::Sequence,
children: &[
Node::Segment(SegmentRef {
id: "CRM_C01.5-PATIENT.1-PID",
position: 1,
segment: &segment::pid::PID,
cardinality: Cardinality {
min: 1,
max: Max::Bounded(1),
},
status: Some(SegmentStatus::A),
}),
Node::Segment(SegmentRef {
id: "CRM_C01.5-PATIENT.2-GSP",
position: 2,
segment: &segment::gsp::GSP,
cardinality: Cardinality {
min: 0,
max: Max::Unbounded,
},
status: Some(SegmentStatus::A),
}),
Node::Segment(SegmentRef {
id: "CRM_C01.5-PATIENT.3-GSR",
position: 3,
segment: &segment::gsr::GSR,
cardinality: Cardinality {
min: 0,
max: Max::Unbounded,
},
status: Some(SegmentStatus::A),
}),
Node::Segment(SegmentRef {
id: "CRM_C01.5-PATIENT.4-GSC",
position: 4,
segment: &segment::gsc::GSC,
cardinality: Cardinality {
min: 0,
max: Max::Unbounded,
},
status: Some(SegmentStatus::A),
}),
Node::Segment(SegmentRef {
id: "CRM_C01.5-PATIENT.5-PRT",
position: 5,
segment: &segment::prt::PRT,
cardinality: Cardinality {
min: 0,
max: Max::Unbounded,
},
status: Some(SegmentStatus::A),
}),
Node::Segment(SegmentRef {
id: "CRM_C01.5-PATIENT.6-ARV",
position: 6,
segment: &segment::arv::ARV,
cardinality: Cardinality {
min: 0,
max: Max::Unbounded,
},
status: Some(SegmentStatus::B),
}),
Node::Group(Group {
id: "CRM_C01.5-PATIENT.7-PATIENT_VISIT",
position: 7,
name: "PATIENT_VISIT",
cardinality: Cardinality {
min: 0,
max: Max::Bounded(1),
},
kind: GroupKind::Sequence,
children: &[
Node::Segment(SegmentRef {
id: "CRM_C01.5-PATIENT.7-PATIENT_VISIT.1-PV1",
position: 1,
segment: &segment::pv1::PV1,
cardinality: Cardinality {
min: 1,
max: Max::Bounded(1),
},
status: Some(SegmentStatus::A),
}),
Node::Segment(SegmentRef {
id: "CRM_C01.5-PATIENT.7-PATIENT_VISIT.2-PRT",
position: 2,
segment: &segment::prt::PRT,
cardinality: Cardinality {
min: 0,
max: Max::Unbounded,
},
status: Some(SegmentStatus::A),
}),
],
}),
Node::Segment(SegmentRef {
id: "CRM_C01.5-PATIENT.8-CSR",
position: 8,
segment: &segment::csr::CSR,
cardinality: Cardinality {
min: 1,
max: Max::Bounded(1),
},
status: Some(SegmentStatus::A),
}),
Node::Segment(SegmentRef {
id: "CRM_C01.5-PATIENT.9-CSP",
position: 9,
segment: &segment::csp::CSP,
cardinality: Cardinality {
min: 0,
max: Max::Unbounded,
},
status: Some(SegmentStatus::A),
}),
],
}),
];
/// The `CRM_C01` message structure definition, `http://hl7.org/v2/StructureDefinition/CRM_C01`.
pub static CRM_C01: Structure = Structure {
id: "CRM_C01",
url: Some("http://hl7.org/v2/StructureDefinition/CRM_C01"),
version: "2.9.1",
withdrawn_as_of: None,
nodes: &CRM_C01_NODES,
};