1#[doc = "The time or time-period the observed values are related to. When the subject of the report is a patient, this is usually either the time of the procedure or of specimen collection(s), but very often the source of the date/time is not known, only the date/time itself."]
3#[derive(Default, Debug, Clone, PartialEq)]
4pub enum DiagnosticReportEffective {
5 DateTime(super::super::types::DateTime),
6 Period(Box<super::super::types::Period>),
7 #[default]
8 Invalid,
9}
10#[doc = "This backbone element contains supporting information that was used in the creation of the report not included in the results already included in the report."]
11#[derive(Debug, Clone, PartialEq)]
12pub struct DiagnosticReportSupportingInfo {
13 #[doc = "Unique id for the element within a resource (for internal references). This may be any string value that does not contain spaces."]
14 pub r#id: Option<std::string::String>,
15 #[doc = "May be used to represent additional information that is not part of the basic definition of the element. To make the use of extensions safe and managable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension."]
16 pub r#extension: Vec<super::super::types::Extension>,
17 #[doc = "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and managable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself)."]
18 pub r#modifier_extension: Vec<super::super::types::Extension>,
19 #[doc = "The code value for the role of the supporting information in the diagnostic report."]
20 pub r#type: Box<super::super::types::CodeableConcept>,
21 #[doc = "The reference for the supporting information in the diagnostic report."]
22 pub r#reference: Box<super::super::types::Reference>,
23}
24#[allow(clippy::derivable_impls)]
25impl Default for DiagnosticReportSupportingInfo {
26 fn default() -> Self {
27 Self {
28 r#id: Default::default(),
29 r#extension: Default::default(),
30 r#modifier_extension: Default::default(),
31 r#type: Box::new(super::super::types::CodeableConcept {
32 id: Some("$invalid".to_string()),
33 ..Default::default()
34 }),
35 r#reference: Box::new(super::super::types::Reference {
36 id: Some("$invalid".to_string()),
37 ..Default::default()
38 }),
39 }
40 }
41}
42#[doc = "A list of key images or data associated with this report. The images or data are generally created during the diagnostic process, and may be directly of the patient, or of treated specimens (i.e. slides of interest)."]
43#[derive(Debug, Clone, PartialEq)]
44pub struct DiagnosticReportMedia {
45 #[doc = "Unique id for the element within a resource (for internal references). This may be any string value that does not contain spaces."]
46 pub r#id: Option<std::string::String>,
47 #[doc = "May be used to represent additional information that is not part of the basic definition of the element. To make the use of extensions safe and managable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension."]
48 pub r#extension: Vec<super::super::types::Extension>,
49 #[doc = "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and managable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself)."]
50 pub r#modifier_extension: Vec<super::super::types::Extension>,
51 #[doc = "A comment about the image or data. Typically, this is used to provide an explanation for why the image or data is included, or to draw the viewer's attention to important features."]
52 pub r#comment: Option<super::super::types::String>,
53 #[doc = "Reference to the image or data source."]
54 pub r#link: Box<super::super::types::Reference>,
55}
56#[allow(clippy::derivable_impls)]
57impl Default for DiagnosticReportMedia {
58 fn default() -> Self {
59 Self {
60 r#id: Default::default(),
61 r#extension: Default::default(),
62 r#modifier_extension: Default::default(),
63 r#comment: Default::default(),
64 r#link: Box::new(super::super::types::Reference {
65 id: Some("$invalid".to_string()),
66 ..Default::default()
67 }),
68 }
69 }
70}
71#[doc = "The findings and interpretation of diagnostic tests performed on patients, groups of patients, products, substances, devices, and locations, and/or specimens derived from these. The report includes clinical context such as requesting provider information, and some mix of atomic results, images, textual and coded interpretations, and formatted representation of diagnostic reports. The report also includes non-clinical context such as batch analysis and stability reporting of products and substances.\n\nTo support reporting for any diagnostic report into a clinical data repository."]
72#[derive(Debug, Clone, PartialEq)]
73pub struct DiagnosticReport {
74 #[doc = "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."]
75 pub r#id: Option<super::super::types::Id>,
76 #[doc = "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource."]
77 pub r#meta: Option<Box<super::super::types::Meta>>,
78 #[doc = "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."]
79 pub r#implicit_rules: Option<super::super::types::Uri>,
80 #[doc = "The base language in which the resource is written."]
81 pub r#language: Option<super::super::types::Code>,
82 #[doc = "A human-readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety."]
83 pub r#text: Option<Box<super::super::types::Narrative>>,
84 #[doc = "These resources do not have an independent existence apart from the resource that contains them - they cannot be identified independently, nor can they have their own independent transaction scope. This is allowed to be a Parameters resource if and only if it is referenced by a resource that provides context/meaning."]
85 pub r#contained: Vec<super::super::Resource>,
86 #[doc = "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and managable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension."]
87 pub r#extension: Vec<super::super::types::Extension>,
88 #[doc = "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and managable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself)."]
89 pub r#modifier_extension: Vec<super::super::types::Extension>,
90 #[doc = "Identifiers assigned to this report by the performer or other systems."]
91 pub r#identifier: Vec<super::super::types::Identifier>,
92 #[doc = "Details concerning a service requested."]
93 pub r#based_on: Vec<super::super::types::Reference>,
94 #[doc = "The status of the diagnostic report."]
95 pub r#status: super::super::types::Code,
96 #[doc = "A code that classifies the clinical discipline, department or diagnostic service that created the report (e.g. cardiology, biochemistry, hematology, MRI). This is used for searching, sorting and display purposes."]
97 pub r#category: Vec<super::super::types::CodeableConcept>,
98 #[doc = "A code or name that describes this diagnostic report."]
99 pub r#code: Box<super::super::types::CodeableConcept>,
100 #[doc = "The subject of the report. Usually, but not always, this is a patient. However, diagnostic services also perform analyses on specimens collected from a variety of other sources."]
101 pub r#subject: Option<Box<super::super::types::Reference>>,
102 #[doc = "The healthcare event (e.g. a patient and healthcare provider interaction) which this DiagnosticReport is about."]
103 pub r#encounter: Option<Box<super::super::types::Reference>>,
104 #[doc = "The time or time-period the observed values are related to. When the subject of the report is a patient, this is usually either the time of the procedure or of specimen collection(s), but very often the source of the date/time is not known, only the date/time itself."]
105 pub r#effective: Option<DiagnosticReportEffective>,
106 #[doc = "The date and time that this version of the report was made available to providers, typically after the report was reviewed and verified."]
107 pub r#issued: Option<super::super::types::Instant>,
108 #[doc = "The diagnostic service that is responsible for issuing the report."]
109 pub r#performer: Vec<super::super::types::Reference>,
110 #[doc = "The practitioner or organization that is responsible for the report's conclusions and interpretations."]
111 pub r#results_interpreter: Vec<super::super::types::Reference>,
112 #[doc = "Details about the specimens on which this diagnostic report is based."]
113 pub r#specimen: Vec<super::super::types::Reference>,
114 #[doc = "[Observations](https://hl7.org/FHIR/observation.html)) that are part of this diagnostic report."]
115 pub r#result: Vec<super::super::types::Reference>,
116 #[doc = "Comments about the diagnostic report."]
117 pub r#note: Vec<super::super::types::Annotation>,
118 #[doc = "One or more links to full details of any study performed during the diagnostic investigation. An ImagingStudy might comprise a set of radiologic images obtained via a procedure that are analyzed as a group. Typically, this is imaging performed by DICOM enabled modalities, but this is not required. A fully enabled PACS viewer can use this information to provide views of the source images. A GenomicStudy might comprise one or more analyses, each serving a specific purpose. These analyses may vary in method (e.g., karyotyping, CNV, or SNV detection), performer, software, devices used, or regions targeted."]
119 pub r#study: Vec<super::super::types::Reference>,
120 #[doc = "This backbone element contains supporting information that was used in the creation of the report not included in the results already included in the report."]
121 pub r#supporting_info: Vec<DiagnosticReportSupportingInfo>,
122 #[doc = "A list of key images or data associated with this report. The images or data are generally created during the diagnostic process, and may be directly of the patient, or of treated specimens (i.e. slides of interest)."]
123 pub r#media: Vec<DiagnosticReportMedia>,
124 #[doc = "Reference to a Composition resource instance that provides structure for organizing the contents of the DiagnosticReport."]
125 pub r#composition: Option<Box<super::super::types::Reference>>,
126 #[doc = "Concise and clinically contextualized summary conclusion (interpretation/impression) of the diagnostic report."]
127 pub r#conclusion: Option<super::super::types::Markdown>,
128 #[doc = "One or more codes that represent the summary conclusion (interpretation/impression) of the diagnostic report."]
129 pub r#conclusion_code: Vec<super::super::types::CodeableConcept>,
130 #[doc = "Rich text representation of the entire result as issued by the diagnostic service. Multiple formats are allowed but they SHALL be semantically equivalent."]
131 pub r#presented_form: Vec<super::super::types::Attachment>,
132}
133#[allow(clippy::derivable_impls)]
134impl Default for DiagnosticReport {
135 fn default() -> Self {
136 Self {
137 r#id: Default::default(),
138 r#meta: Default::default(),
139 r#implicit_rules: Default::default(),
140 r#language: Default::default(),
141 r#text: Default::default(),
142 r#contained: Default::default(),
143 r#extension: Default::default(),
144 r#modifier_extension: Default::default(),
145 r#identifier: Default::default(),
146 r#based_on: Default::default(),
147 r#status: super::super::types::Code {
148 id: Some("$invalid".to_string()),
149 ..Default::default()
150 },
151 r#category: Default::default(),
152 r#code: Box::new(super::super::types::CodeableConcept {
153 id: Some("$invalid".to_string()),
154 ..Default::default()
155 }),
156 r#subject: Default::default(),
157 r#encounter: Default::default(),
158 r#effective: Default::default(),
159 r#issued: Default::default(),
160 r#performer: Default::default(),
161 r#results_interpreter: Default::default(),
162 r#specimen: Default::default(),
163 r#result: Default::default(),
164 r#note: Default::default(),
165 r#study: Default::default(),
166 r#supporting_info: Default::default(),
167 r#media: Default::default(),
168 r#composition: Default::default(),
169 r#conclusion: Default::default(),
170 r#conclusion_code: Default::default(),
171 r#presented_form: Default::default(),
172 }
173 }
174}