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
//! FHIR Release 4 (R3).
//!
//! This module holds the FHIR R3 (3.0.2) implementation, laid out exactly like
//! [`crate::r5`] so that porting between releases is a matter of changing one
//! path segment. The pieces you use day to day are:
//!
//! - [`resources`] — the 146 R3 resources plus the polymorphic
//! [`Resource`](resources::Resource) enum.
//! - [`types`] — the 43 complex datatypes and 20 primitive newtypes.
//! - [`codes`] — FHIR `CodeSystem`s as type-safe enums.
//! - [`validate`] — the R3 primitive-format constraints, over the shared
//! [`Validate`](crate::validate::Validate) trait.
//!
//! Unlike [`crate::r5`], every model module here is **generated** from the
//! official R3 definition JSON by [`crate::codegen`]; regenerate with
//! `cargo run -- r3` rather than editing `src/r3/types` or `src/r3/resources`
//! by hand.
//!
//! # R3 is not R5
//!
//! The releases are deliberately separate types, because they disagree in ways
//! that silently corrupt data if conflated. For example `Observation.value[x]`
//! allows 11 types in R3 and 13 in R5; `MedicationRequest.medication[x]` is a
//! choice in R3 but a `CodeableReference` in R5; and R3 has no `integer64`,
//! `CodeableReference`, or `RatioRange` datatype at all. Convert between them
//! explicitly, through JSON, rather than assuming they interoperate.
//!
//! See the [crate-level guide](crate) for a task-oriented walkthrough.
/// FHIR R3 datatypes.
/// FHIR R3 resources.
/// FHIR R3 code systems as type-safe enums.
/// Lightweight FHIR R3 validation.
/// Per-element metadata extracted from the FHIR R3 specification (cardinality,
/// bindings, choice types, reference targets, summary membership).
/// Support types for `value[x]` choice elements (see `spec/11-choice-types.md`).
/// The [`Coded`](coded::Coded) wrapper for `required`-binding coded fields.
/// Support for the generated `#[derive(Builder)]` builders.
/// Ergonomic extension accessors ([`ExtensionExt`](extension_ext::ExtensionExt)).
/// Utilities for `Bundle`s: iteration, paging, and transaction/batch building.
/// Summary serialization (the FHIR `_summary=true` view).
/// Parsing and precision-aware comparison for the date/time primitives.
/// Common imports for working with FHIR R3.
/// An async FHIR R3 REST client (feature `client`).
/// FHIR XML serialization (feature `xml`).
/// The FHIR R3 release, as a type.
///
/// Marker for release-parameterized code such as
/// [`ReleaseClient`](crate::client::ReleaseClient); see [`crate::release`].
;