R5 Final QA

This page is part of the FHIR Specification (v5.0.0-draft-final: Final QA Preview for R5 - see ballot notes). The current version which supercedes this version is 5.0.0. For a full list of available versions, see the Directory of published versions . Page versions: R5 R4B R4 R3

Domainresource.shex

FHIR Infrastructure Work GroupMaturity Level: N/AStandards Status: InformativeCompartments: Not linked to any defined compartments

Raw ShEx

ShEx statement for domainresource

PREFIX fhir: <http://hl7.org/fhir/> 
PREFIX fhirvs: <http://hl7.org/fhir/ValueSet/>
PREFIX xsd: <http://www.w3.org/2001/XMLSchema#> 
PREFIX rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> 

IMPORT <Resource.shex>
IMPORT <Narrative.shex>
IMPORT <Extension.shex>


start=@<DomainResource> AND {fhir:nodeRole [fhir:treeRoot]}

# A resource with narrative, extensions, and contained resources
<DomainResource> EXTENDS @<Resource> CLOSED {   

    a [fhir:DomainResource]?;
    fhir:nodeRole [fhir:treeRoot]?;

    fhir:text @<Narrative>?;                # Text summary of the resource, for 
                                            # human interpretation 
    fhir:contained @<OneOrMore_Resource>?;  # Contained, inline Resources
    fhir:extension @<OneOrMore_Extension>?;  # Additional content defined by 
                                            # implementations 
    fhir:modifierExtension @<OneOrMore_Extension>?;  # Extensions that cannot be ignored
}  

#---------------------- Cardinality Types (OneOrMore) -------------------

<OneOrMore_Resource> CLOSED {
    rdf:first @<Resource>  ;
    rdf:rest [rdf:nil] OR @<OneOrMore_Resource> 
}

<OneOrMore_Extension> CLOSED {
    rdf:first @<Extension>  ;
    rdf:rest [rdf:nil] OR @<OneOrMore_Extension> 
}


Usage note: every effort has been made to ensure that the ShEx files are correct and useful, but they are not a normative part of the specification.