This page is part of the FHIR Specification (v5.0.0: R5 - STU). This is the current published version in it's permanent home (it will always be available at this URL). For a full list of available versions, see the Directory of published versions . Page versions: R5 R4B R4 R3
Group.shex
Raw ShEx
ShEx statement for group
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 <code.shex>
IMPORT <Range.shex>
IMPORT <string.shex>
IMPORT <Device.shex>
IMPORT <Period.shex>
IMPORT <boolean.shex>
IMPORT <Patient.shex>
IMPORT <markdown.shex>
IMPORT <CareTeam.shex>
IMPORT <Location.shex>
IMPORT <Specimen.shex>
IMPORT <Quantity.shex>
IMPORT <Reference.shex>
IMPORT <Identifier.shex>
IMPORT <unsignedInt.shex>
IMPORT <Organization.shex>
IMPORT <Practitioner.shex>
IMPORT <RelatedPerson.shex>
IMPORT <DomainResource.shex>
IMPORT <CodeableConcept.shex>
IMPORT <BackboneElement.shex>
IMPORT <PractitionerRole.shex>
IMPORT <HealthcareService.shex>
start=@<Group> AND {fhir:nodeRole [fhir:treeRoot]}
# Group of multiple entities
<Group> EXTENDS @<DomainResource> CLOSED {
a [fhir:Group]?;
fhir:nodeRole [fhir:treeRoot]?;
fhir:identifier @<OneOrMore_Identifier>?; # Business Identifier for this Group
fhir:active @<boolean>?; # Whether this group's record is in
# active use
fhir:type @<code> AND
{fhir:v @fhirvs:group-type}; # person | animal | practitioner |
# device | careteam |
# healthcareservice | location |
# organization | relatedperson |
# specimen
fhir:membership @<code> AND
{fhir:v @fhirvs:group-membership-basis}; # definitional | enumerated
fhir:code @<CodeableConcept>?; # Kind of Group members
fhir:name @<string>?; # Label for Group
fhir:description @<markdown>?; # Natural language description of
# the group
fhir:quantity @<unsignedInt>?; # Number of members
fhir:managingEntity @<Reference> AND {fhir:link
@<Organization> OR
@<Practitioner> OR
@<PractitionerRole> OR
@<RelatedPerson> ? }?; # Entity that is the custodian of
# the Group's definition
fhir:characteristic @<OneOrMore_Group.characteristic>?; # Include / Exclude group members by
# Trait
fhir:member @<OneOrMore_Group.member>?; # Who or what is in group
}
# Who or what is in group
<Group.member> EXTENDS @<BackboneElement> CLOSED {
fhir:entity @<Reference> AND {fhir:link
@<CareTeam> OR
@<Device> OR
@<Group> OR
@<HealthcareService> OR
@<Location> OR
@<Organization> OR
@<Patient> OR
@<Practitioner> OR
@<PractitionerRole> OR
@<RelatedPerson> OR
@<Specimen> ? }; # Reference to the group member
fhir:period @<Period>?; # Period member belonged to the group
fhir:inactive @<boolean>?; # If member is no longer in group
}
# Include / Exclude group members by Trait
<Group.characteristic> EXTENDS @<BackboneElement> CLOSED {
fhir:code @<CodeableConcept>; # Kind of characteristic
fhir:value @<CodeableConcept> OR
@<boolean> OR
@<Quantity> OR
@<Range> OR
@<Reference> ; # Value held by characteristic
fhir:exclude @<boolean>; # Group includes or excludes
fhir:period @<Period>?; # Period over which characteristic
# is tested
}
#---------------------- Cardinality Types (OneOrMore) -------------------
<OneOrMore_Identifier> CLOSED {
rdf:first @<Identifier> ;
rdf:rest [rdf:nil] OR @<OneOrMore_Identifier>
}
<OneOrMore_Group.characteristic> CLOSED {
rdf:first @<Group.characteristic> ;
rdf:rest [rdf:nil] OR @<OneOrMore_Group.characteristic>
}
<OneOrMore_Group.member> CLOSED {
rdf:first @<Group.member> ;
rdf:rest [rdf:nil] OR @<OneOrMore_Group.member>
}
#---------------------- Value Sets ------------------------
# Basis for membership in a group
fhirvs:group-membership-basis ["definitional" "enumerated"]
# Types of resources that are part of group.
fhirvs:group-type ["person" "animal" "practitioner" "device" "careteam" "healthcareservice" "location" "organization" "relatedperson" "specimen"]
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.