pub struct ElementDefinition {Show 37 fields
pub id: Option<String>,
pub extension: Option<Vec<Box<Extension>>>,
pub modifierExtension: Option<Vec<Box<Extension>>>,
pub path: Box<FHIRString>,
pub representation: Option<Vec<Box<PropertyRepresentation>>>,
pub sliceName: Option<Box<FHIRString>>,
pub sliceIsConstraining: Option<Box<FHIRBoolean>>,
pub label: Option<Box<FHIRString>>,
pub code: Option<Vec<Box<Coding>>>,
pub slicing: Option<ElementDefinitionSlicing>,
pub short: Option<Box<FHIRString>>,
pub definition: Option<Box<FHIRMarkdown>>,
pub comment: Option<Box<FHIRMarkdown>>,
pub requirements: Option<Box<FHIRMarkdown>>,
pub alias: Option<Vec<Box<FHIRString>>>,
pub min: Option<Box<FHIRUnsignedInt>>,
pub max: Option<Box<FHIRString>>,
pub base: Option<ElementDefinitionBase>,
pub contentReference: Option<Box<FHIRUri>>,
pub type_: Option<Vec<ElementDefinitionType>>,
pub defaultValue: Option<ElementDefinitionDefaultValueTypeChoice>,
pub meaningWhenMissing: Option<Box<FHIRMarkdown>>,
pub orderMeaning: Option<Box<FHIRString>>,
pub fixed: Option<ElementDefinitionFixedTypeChoice>,
pub pattern: Option<ElementDefinitionPatternTypeChoice>,
pub example: Option<Vec<ElementDefinitionExample>>,
pub minValue: Option<ElementDefinitionMinValueTypeChoice>,
pub maxValue: Option<ElementDefinitionMaxValueTypeChoice>,
pub maxLength: Option<Box<FHIRInteger>>,
pub condition: Option<Vec<Box<FHIRId>>>,
pub constraint: Option<Vec<ElementDefinitionConstraint>>,
pub mustSupport: Option<Box<FHIRBoolean>>,
pub isModifier: Option<Box<FHIRBoolean>>,
pub isModifierReason: Option<Box<FHIRString>>,
pub isSummary: Option<Box<FHIRBoolean>>,
pub binding: Option<ElementDefinitionBinding>,
pub mapping: Option<Vec<ElementDefinitionMapping>>,
}Expand description
Captures constraints on each element within the resource, profile, or extension.
Fields§
§id: Option<String>Unique id for the element within a resource (for internal references). This may be any string value that does not contain spaces.
extension: Option<Vec<Box<Extension>>>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 manageable, 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.
modifierExtension: Option<Vec<Box<Extension>>>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 manageable, 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.
Modifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).
path: Box<FHIRString>The path identifies the element and is expressed as a “.”-separated list of ancestor elements, beginning with the name of the resource or extension.
representation: Option<Vec<Box<PropertyRepresentation>>>Codes that define how this element is represented in instances, when the deviation varies from the normal case.
sliceName: Option<Box<FHIRString>>The name of this element definition slice, when slicing is working. The name must be a token with no dots or spaces. This is a unique name referring to a specific set of constraints applied to this element, used to provide a name to different slices of the same element.
sliceIsConstraining: Option<Box<FHIRBoolean>>If true, indicates that this slice definition is constraining a slice definition with the same name in an inherited profile. If false, the slice is not overriding any slice in an inherited profile. If missing, the slice might or might not be overriding a slice in an inherited profile, depending on the sliceName.
label: Option<Box<FHIRString>>A single preferred label which is the text to display beside the element indicating its meaning or to use to prompt for the element in a user display or form.
code: Option<Vec<Box<Coding>>>A code that has the same meaning as the element in a particular terminology.
slicing: Option<ElementDefinitionSlicing>Indicates that the element is sliced into a set of alternative definitions (i.e. in a structure definition, there are multiple different constraints on a single element in the base resource). Slicing can be used in any resource that has cardinality ..* on the base resource, or any resource with a choice of types. The set of slices is any elements that come after this in the element sequence that have the same path, until a shorter path occurs (the shorter path terminates the set).
short: Option<Box<FHIRString>>A concise description of what this element means (e.g. for use in autogenerated summaries).
definition: Option<Box<FHIRMarkdown>>Provides a complete explanation of the meaning of the data element for human readability. For the case of elements derived from existing elements (e.g. constraints), the definition SHALL be consistent with the base definition, but convey the meaning of the element in the particular context of use of the resource. (Note: The text you are reading is specified in ElementDefinition.definition).
comment: Option<Box<FHIRMarkdown>>Explanatory notes and implementation guidance about the data element, including notes about how to use the data properly, exceptions to proper use, etc. (Note: The text you are reading is specified in ElementDefinition.comment).
requirements: Option<Box<FHIRMarkdown>>This element is for traceability of why the element was created and why the constraints exist as they do. This may be used to point to source materials or specifications that drove the structure of this element.
alias: Option<Vec<Box<FHIRString>>>Identifies additional names by which this element might also be known.
min: Option<Box<FHIRUnsignedInt>>The minimum number of times this element SHALL appear in the instance.
max: Option<Box<FHIRString>>The maximum number of times this element is permitted to appear in the instance.
base: Option<ElementDefinitionBase>Information about the base definition of the element, provided to make it unnecessary for tools to trace the deviation of the element through the derived and related profiles. When the element definition is not the original definition of an element - i.g. either in a constraint on another type, or for elements from a super type in a snap shot - then the information in provided in the element definition may be different to the base definition. On the original definition of the element, it will be same.
contentReference: Option<Box<FHIRUri>>Identifies an element defined elsewhere in the definition whose content rules should be applied to the current element. ContentReferences bring across all the rules that are in the ElementDefinition for the element, including definitions, cardinality constraints, bindings, invariants etc.
type_: Option<Vec<ElementDefinitionType>>The data type or resource that the value of this element is permitted to be.
defaultValue: Option<ElementDefinitionDefaultValueTypeChoice>The value that should be used if there is no value stated in the instance (e.g. ‘if not otherwise specified, the abstract is false’).
meaningWhenMissing: Option<Box<FHIRMarkdown>>The Implicit meaning that is to be understood when this element is missing (e.g. ‘when this element is missing, the period is ongoing’).
orderMeaning: Option<Box<FHIRString>>If present, indicates that the order of the repeating element has meaning and describes what that meaning is. If absent, it means that the order of the element has no meaning.
fixed: Option<ElementDefinitionFixedTypeChoice>Specifies a value that SHALL be exactly the value for this element in the instance. For purposes of comparison, non-significant whitespace is ignored, and all values must be an exact match (case and accent sensitive). Missing elements/attributes must also be missing.
pattern: Option<ElementDefinitionPatternTypeChoice>Specifies a value that the value in the instance SHALL follow - that is, any value in the pattern must be found in the instance. Other additional values may be found too. This is effectively constraint by example.
When pattern[x] is used to constrain a primitive, it means that the value provided in the pattern[x] must match the instance value exactly.
When pattern[x] is used to constrain an array, it means that each element provided in the pattern[x] array must (recursively) match at least one element from the instance array.
When pattern[x] is used to constrain a complex object, it means that each property in the pattern must be present in the complex object, and its value must recursively match – i.e.,
- If primitive: it must match exactly the pattern value
- If a complex object: it must match (recursively) the pattern value
- If an array: it must match (recursively) the pattern value.
example: Option<Vec<ElementDefinitionExample>>A sample value for this element demonstrating the type of information that would typically be found in the element.
minValue: Option<ElementDefinitionMinValueTypeChoice>The minimum allowed value for the element. The value is inclusive. This is allowed for the types date, dateTime, instant, time, decimal, integer, and Quantity.
maxValue: Option<ElementDefinitionMaxValueTypeChoice>The maximum allowed value for the element. The value is inclusive. This is allowed for the types date, dateTime, instant, time, decimal, integer, and Quantity.
maxLength: Option<Box<FHIRInteger>>Indicates the maximum length in characters that is permitted to be present in conformant instances and which is expected to be supported by conformant consumers that support the element.
condition: Option<Vec<Box<FHIRId>>>A reference to an invariant that may make additional statements about the cardinality or value in the instance.
constraint: Option<Vec<ElementDefinitionConstraint>>Formal constraints such as co-occurrence and other constraints that can be computationally evaluated within the context of the instance.
mustSupport: Option<Box<FHIRBoolean>>If true, implementations that produce or consume resources SHALL provide “support” for the element in some meaningful way. If false, the element may be ignored and not supported. If false, whether to populate or use the data element in any way is at the discretion of the implementation.
isModifier: Option<Box<FHIRBoolean>>If true, the value of this element affects the interpretation of the element or resource that contains it, and the value of the element cannot be ignored. Typically, this is used for status, negation and qualification codes. The effect of this is that the element cannot be ignored by systems: they SHALL either recognize the element and process it, and/or a pre-determination has been made that it is not relevant to their particular system.
isModifierReason: Option<Box<FHIRString>>Explains how that element affects the interpretation of the resource or element that contains it.
isSummary: Option<Box<FHIRBoolean>>Whether the element should be included if a client requests a search with the parameter _summary=true.
binding: Option<ElementDefinitionBinding>Binds to a value set if this element is coded (code, Coding, CodeableConcept, Quantity), or the data types (string, uri).
mapping: Option<Vec<ElementDefinitionMapping>>Identifies a concept from an external specification that roughly corresponds to this element.
Trait Implementations§
Source§impl Clone for ElementDefinition
impl Clone for ElementDefinition
Source§fn clone(&self) -> ElementDefinition
fn clone(&self) -> ElementDefinition
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for ElementDefinition
impl Debug for ElementDefinition
Source§impl Default for ElementDefinition
impl Default for ElementDefinition
Source§fn default() -> ElementDefinition
fn default() -> ElementDefinition
Source§impl FHIRJSONDeserializer for ElementDefinition
impl FHIRJSONDeserializer for ElementDefinition
fn from_json_str(s: &str) -> Result<Self, DeserializeError>
fn from_serde_value( obj: &Value, context: Context<'_>, ) -> Result<Self, DeserializeError>
Source§impl FHIRJSONSerializer for ElementDefinition
impl FHIRJSONSerializer for ElementDefinition
fn serialize_value( &self, writer: &mut dyn Write, ) -> Result<bool, SerializeError>
fn serialize_extension( &self, writer: &mut dyn Write, ) -> Result<bool, SerializeError>
fn serialize_field( &self, field: &str, writer: &mut dyn Write, ) -> Result<bool, SerializeError>
fn is_fp_primitive(&self) -> bool
Source§impl MetaValue for ElementDefinition
impl MetaValue for ElementDefinition
fn fields(&self) -> Vec<&'static str>
fn get_field<'a>(&'a self, field: &str) -> Option<&'a dyn MetaValue>
fn get_field_mut<'a>(&'a mut self, field: &str) -> Option<&'a mut dyn MetaValue>
fn get_index_mut<'a>( &'a mut self, index: usize, ) -> Option<&'a mut dyn MetaValue>
fn get_index<'a>(&'a self, _index: usize) -> Option<&'a dyn MetaValue>
fn typename(&self) -> &'static str
fn as_any(&self) -> &dyn Any
fn flatten(&self) -> Vec<&dyn MetaValue>
Auto Trait Implementations§
impl Freeze for ElementDefinition
impl RefUnwindSafe for ElementDefinition
impl Send for ElementDefinition
impl Sync for ElementDefinition
impl Unpin for ElementDefinition
impl UnwindSafe for ElementDefinition
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more