PackagesCanonicalsLogsProblems
    Packages
    laniado.test.fhir.r4@0.1.72
    http://fhir.laniado.org.il/StructureDefinition/laniado-flag
{
  "description": "Laniado Proposed Flag Profile",
  "_filename": "StructureDefinition-laniado-flag.json",
  "package_name": "laniado.test.fhir.r4",
  "date": null,
  "derivation": "constraint",
  "publisher": null,
  "fhirVersion": "4.0.1",
  "name": "LaniadoFlag",
  "mapping": [ {
    "uri": "http://hl7.org/v3",
    "name": "RIM Mapping",
    "identity": "rim"
  }, {
    "uri": "http://hl7.org/fhir/fivews",
    "name": "FiveWs Pattern Mapping",
    "identity": "w5"
  } ],
  "abstract": false,
  "type": "Flag",
  "experimental": null,
  "resourceType": "StructureDefinition",
  "title": "Laniado Flag Profile",
  "package_version": "0.1.72",
  "snapshot": {
    "element": [ {
      "constraint": [ {
        "key": "dom-2",
        "human": "If the resource is contained in another resource, it SHALL NOT contain nested Resources",
        "xpath": "not(parent::f:contained and f:contained)",
        "source": "http://hl7.org/fhir/StructureDefinition/DomainResource",
        "severity": "error",
        "expression": "contained.contained.empty()"
      }, {
        "key": "dom-3",
        "human": "If the resource is contained in another resource, it SHALL be referred to from elsewhere in the resource or SHALL refer to the containing resource",
        "xpath": "not(exists(for $id in f:contained/*/f:id/@value return $contained[not(parent::*/descendant::f:reference/@value=concat('#', $contained/*/id/@value) or descendant::f:reference[@value='#'])]))",
        "source": "http://hl7.org/fhir/StructureDefinition/DomainResource",
        "severity": "error",
        "expression": "contained.where((('#'+id in (%resource.descendants().reference | %resource.descendants().as(canonical) | %resource.descendants().as(uri) | %resource.descendants().as(url))) or descendants().where(reference = '#').exists() or descendants().where(as(canonical) = '#').exists() or descendants().where(as(canonical) = '#').exists()).not()).trace('unmatched', id).empty()"
      }, {
        "key": "dom-4",
        "human": "If a resource is contained in another resource, it SHALL NOT have a meta.versionId or a meta.lastUpdated",
        "xpath": "not(exists(f:contained/*/f:meta/f:versionId)) and not(exists(f:contained/*/f:meta/f:lastUpdated))",
        "source": "http://hl7.org/fhir/StructureDefinition/DomainResource",
        "severity": "error",
        "expression": "contained.meta.versionId.empty() and contained.meta.lastUpdated.empty()"
      }, {
        "key": "dom-5",
        "human": "If a resource is contained in another resource, it SHALL NOT have a security label",
        "xpath": "not(exists(f:contained/*/f:meta/f:security))",
        "source": "http://hl7.org/fhir/StructureDefinition/DomainResource",
        "severity": "error",
        "expression": "contained.meta.security.empty()"
      }, {
        "key": "dom-6",
        "human": "A resource should have narrative for robust management",
        "xpath": "exists(f:text/h:div)",
        "source": "http://hl7.org/fhir/StructureDefinition/DomainResource",
        "severity": "warning",
        "extension": [ {
          "url": "http://hl7.org/fhir/StructureDefinition/elementdefinition-bestpractice",
          "valueBoolean": true
        }, {
          "url": "http://hl7.org/fhir/StructureDefinition/elementdefinition-bestpractice-explanation",
          "valueMarkdown": "When a resource has no narrative, only systems that fully understand the data can display the resource to a human safely. Including a human readable representation in the resource makes for a much more robust eco-system and cheaper handling of resources by intermediary systems. Some ecosystems restrict distribution of resources to only those systems that do fully understand the resources, and as a consequence implementers may believe that the narrative is superfluous. However experience shows that such eco-systems often open up to new participants over time."
        } ],
        "expression": "text.`div`.exists()"
      } ],
      "path": "Flag",
      "min": 0,
      "definition": "Prospective warnings of potential issues when providing care to the patient.",
      "isModifier": false,
      "short": "Key information to flag to healthcare providers",
      "mapping": [ {
        "map": "Entity. Role, or Act",
        "identity": "rim"
      }, {
        "map": "Observation[classCode=ISSUE, moodCode=EVN]",
        "identity": "rim"
      } ],
      "alias": [ "Barriers to Care", "Alert", "Warning" ],
      "max": "*",
      "id": "Flag",
      "base": {
        "max": "*",
        "min": 0,
        "path": "Flag"
      },
      "isSummary": false
    }, {
      "path": "Flag.id",
      "min": 0,
      "definition": "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes.",
      "isModifier": false,
      "short": "Logical id of this artifact",
      "type": [ {
        "code": "http://hl7.org/fhirpath/System.String",
        "extension": [ {
          "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-fhir-type",
          "valueUrl": "string"
        } ]
      } ],
      "max": "1",
      "id": "Flag.id",
      "comment": "The only time that a resource does not have an id is when it is being submitted to the server using a create operation.",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Resource.id"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "http://hl7.org/fhir/StructureDefinition/Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Flag.meta",
      "min": 0,
      "definition": "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.",
      "isModifier": false,
      "short": "Metadata about the resource",
      "type": [ {
        "code": "Meta"
      } ],
      "max": "1",
      "id": "Flag.meta",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Resource.meta"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "http://hl7.org/fhir/StructureDefinition/Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Flag.implicitRules",
      "min": 0,
      "definition": "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.",
      "isModifier": true,
      "short": "A set of rules under which this content was created",
      "type": [ {
        "code": "uri"
      } ],
      "max": "1",
      "id": "Flag.implicitRules",
      "comment": "Asserting this rule set restricts the content to be only understood by a limited set of trading partners. This inherently limits the usefulness of the data in the long term. However, the existing health eco-system is highly fractured, and not yet ready to define, collect, and exchange data in a generally computable sense. Wherever possible, implementers and/or specification writers should avoid using this element. Often, when used, the URL is a reference to an implementation guide that defines these special rules as part of it's narrative along with other profiles, value sets, etc.",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Resource.implicitRules"
      },
      "isModifierReason": "This element is labeled as a modifier because the implicit rules may provide additional knowledge about the resource that modifies it's meaning or interpretation",
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "http://hl7.org/fhir/StructureDefinition/Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Flag.language",
      "min": 0,
      "definition": "The base language in which the resource is written.",
      "isModifier": false,
      "short": "Language of the resource content",
      "type": [ {
        "code": "code"
      } ],
      "binding": {
        "strength": "preferred",
        "valueSet": "http://hl7.org/fhir/ValueSet/languages",
        "extension": [ {
          "url": "http://hl7.org/fhir/StructureDefinition/elementdefinition-maxValueSet",
          "valueCanonical": "http://hl7.org/fhir/ValueSet/all-languages"
        }, {
          "url": "http://hl7.org/fhir/StructureDefinition/elementdefinition-bindingName",
          "valueString": "Language"
        }, {
          "url": "http://hl7.org/fhir/StructureDefinition/elementdefinition-isCommonBinding",
          "valueBoolean": true
        } ],
        "description": "A human language."
      },
      "max": "1",
      "id": "Flag.language",
      "comment": "Language is provided to support indexing and accessibility (typically, services such as text to speech use the language tag). The html language tag in the narrative applies  to the narrative. The language tag on the resource may be used to specify the language of other presentations generated from the data in the resource. Not all the content has to be in the base language. The Resource.language should not be assumed to apply to the narrative automatically. If a language is specified, it should it also be specified on the div element in the html (see rules in HTML5 for information about the relationship between xml:lang and the html lang attribute).",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Resource.language"
      },
      "isSummary": false
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "http://hl7.org/fhir/StructureDefinition/Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Flag.text",
      "min": 0,
      "definition": "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.",
      "isModifier": false,
      "short": "Text summary of the resource, for human interpretation",
      "mapping": [ {
        "map": "Act.text?",
        "identity": "rim"
      } ],
      "type": [ {
        "code": "Narrative"
      } ],
      "alias": [ "narrative", "html", "xhtml", "display" ],
      "max": "1",
      "id": "Flag.text",
      "comment": "Contained resources do not have narrative. Resources that are not contained SHOULD have a narrative. In some cases, a resource may only have text with little or no additional discrete data (as long as all minOccurs=1 elements are satisfied).  This may be necessary for data from legacy systems where information is captured as a \"text blob\" or where text is additionally entered raw or narrated and encoded information is added later.",
      "base": {
        "max": "1",
        "min": 0,
        "path": "DomainResource.text"
      },
      "isSummary": false
    }, {
      "path": "Flag.contained",
      "min": 0,
      "definition": "These resources do not have an independent existence apart from the resource that contains them - they cannot be identified independently, and nor can they have their own independent transaction scope.",
      "isModifier": false,
      "short": "Contained, inline Resources",
      "mapping": [ {
        "map": "N/A",
        "identity": "rim"
      } ],
      "type": [ {
        "code": "Resource"
      } ],
      "alias": [ "inline resources", "anonymous resources", "contained resources" ],
      "max": "*",
      "id": "Flag.contained",
      "comment": "This should never be done when the content can be identified properly, as once identification is lost, it is extremely difficult (and context dependent) to restore it again. Contained resources may have profiles and tags In their meta elements, but SHALL NOT have security labels.",
      "base": {
        "max": "*",
        "min": 0,
        "path": "DomainResource.contained"
      },
      "isSummary": false
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "http://hl7.org/fhir/StructureDefinition/Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      }, {
        "key": "ext-1",
        "human": "Must have either extensions or value[x], not both",
        "xpath": "exists(f:extension)!=exists(f:*[starts-with(local-name(.), \"value\")])",
        "source": "http://hl7.org/fhir/StructureDefinition/Extension",
        "severity": "error",
        "expression": "extension.exists() != value.exists()"
      } ],
      "path": "Flag.extension",
      "min": 0,
      "definition": "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 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.",
      "isModifier": false,
      "short": "Additional content defined by implementations",
      "mapping": [ {
        "map": "N/A",
        "identity": "rim"
      } ],
      "slicing": {
        "rules": "open",
        "ordered": false,
        "discriminator": [ {
          "path": "url",
          "type": "value"
        } ]
      },
      "type": [ {
        "code": "Extension"
      } ],
      "alias": [ "extensions", "user content" ],
      "max": "*",
      "id": "Flag.extension",
      "comment": "There can be no stigma associated with the use of extensions by any application, project, or standard - regardless of the institution or jurisdiction that uses or defines the extensions.  The use of extensions is what allows the FHIR specification to retain a core level of simplicity for everyone.",
      "base": {
        "max": "*",
        "min": 0,
        "path": "DomainResource.extension"
      },
      "isSummary": false
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "http://hl7.org/fhir/StructureDefinition/Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      }, {
        "key": "ext-1",
        "human": "Must have either extensions or value[x], not both",
        "xpath": "exists(f:extension)!=exists(f:*[starts-with(local-name(.), \"value\")])",
        "source": "http://hl7.org/fhir/StructureDefinition/Extension",
        "severity": "error",
        "expression": "extension.exists() != value.exists()"
      } ],
      "path": "Flag.extension",
      "min": 0,
      "definition": "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 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.",
      "isModifier": false,
      "short": "Additional content defined by implementations",
      "mapping": [ {
        "map": "N/A",
        "identity": "rim"
      } ],
      "type": [ {
        "code": "Extension",
        "profile": [ "http://fhir.laniado.org.il/StructureDefinition/ext-flag-note" ]
      } ],
      "sliceName": "note",
      "alias": [ "extensions", "user content" ],
      "max": "2",
      "id": "Flag.extension:note",
      "comment": "There can be no stigma associated with the use of extensions by any application, project, or standard - regardless of the institution or jurisdiction that uses or defines the extensions.  The use of extensions is what allows the FHIR specification to retain a core level of simplicity for everyone.",
      "base": {
        "max": "*",
        "min": 0,
        "path": "DomainResource.extension"
      },
      "isSummary": false
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "http://hl7.org/fhir/StructureDefinition/Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      }, {
        "key": "ext-1",
        "human": "Must have either extensions or value[x], not both",
        "xpath": "exists(f:extension)!=exists(f:*[starts-with(local-name(.), \"value\")])",
        "source": "http://hl7.org/fhir/StructureDefinition/Extension",
        "severity": "error",
        "expression": "extension.exists() != value.exists()"
      } ],
      "path": "Flag.modifierExtension",
      "requirements": "Modifier extensions allow for extensions that *cannot* be safely ignored to be clearly distinguished from the vast majority of extensions which can be safely ignored.  This promotes interoperability by eliminating the need for implementers to prohibit the presence of extensions. For further information, see the [definition of modifier extensions](extensibility.html#modifierExtension).",
      "min": 0,
      "definition": "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 manageable, 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).",
      "isModifier": true,
      "short": "Extensions that cannot be ignored",
      "mapping": [ {
        "map": "N/A",
        "identity": "rim"
      } ],
      "type": [ {
        "code": "Extension"
      } ],
      "alias": [ "extensions", "user content" ],
      "max": "*",
      "id": "Flag.modifierExtension",
      "comment": "There can be no stigma associated with the use of extensions by any application, project, or standard - regardless of the institution or jurisdiction that uses or defines the extensions.  The use of extensions is what allows the FHIR specification to retain a core level of simplicity for everyone.",
      "base": {
        "max": "*",
        "min": 0,
        "path": "DomainResource.modifierExtension"
      },
      "isModifierReason": "Modifier extensions are expected to modify the meaning or interpretation of the resource that contains them",
      "isSummary": false
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "http://hl7.org/fhir/StructureDefinition/Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Flag.identifier",
      "requirements": "Allows identification of the flag as it is known by various participating systems and in a way that remains consistent across servers.",
      "min": 0,
      "definition": "Business identifiers assigned to this flag by the performer or other systems which remain constant as the resource is updated and propagates from server to server.",
      "isModifier": false,
      "short": "Business identifier",
      "mapping": [ {
        "map": "FiveWs.identifier",
        "identity": "w5"
      }, {
        "map": ".id",
        "identity": "rim"
      } ],
      "slicing": {
        "rules": "open",
        "discriminator": [ {
          "path": "system",
          "type": "value"
        } ]
      },
      "type": [ {
        "code": "Identifier"
      } ],
      "max": "*",
      "id": "Flag.identifier",
      "comment": "This is a business identifier, not a resource identifier (see [discussion](resource.html#identifiers)).  It is best practice for the identifier to only appear on a single resource instance, however business practices may occasionally dictate that multiple resource instances with the same identifier can exist - possibly even with different resource types.  For example, multiple Patient and a Person resource instance might share the same social insurance number.",
      "base": {
        "max": "*",
        "min": 0,
        "path": "Flag.identifier"
      },
      "isSummary": true
    }, {
      "path": "Flag.identifier.id",
      "min": 0,
      "definition": "Unique id for the element within a resource (for internal references). This may be any string value that does not contain spaces.",
      "short": "Unique id for inter-element referencing",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      } ],
      "type": [ {
        "code": "http://hl7.org/fhirpath/System.String",
        "extension": [ {
          "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-fhir-type",
          "valueUrl": "string"
        } ]
      } ],
      "representation": [ "xmlAttr" ],
      "max": "1",
      "id": "Flag.identifier.id",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Element.id"
      }
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "http://hl7.org/fhir/StructureDefinition/Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      }, {
        "key": "ext-1",
        "human": "Must have either extensions or value[x], not both",
        "xpath": "exists(f:extension)!=exists(f:*[starts-with(local-name(.), 'value')])",
        "source": "http://hl7.org/fhir/StructureDefinition/Element",
        "severity": "error",
        "expression": "extension.exists() != value.exists()"
      } ],
      "path": "Flag.identifier.extension",
      "min": 0,
      "definition": "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.",
      "short": "Additional content defined by implementations",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "N/A",
        "identity": "rim"
      } ],
      "slicing": {
        "rules": "open",
        "description": "Extensions are always sliced by (at least) url",
        "discriminator": [ {
          "path": "url",
          "type": "value"
        } ]
      },
      "type": [ {
        "code": "Extension"
      } ],
      "extension": [ {
        "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-standards-status",
        "valueCode": "normative"
      }, {
        "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-normative-version",
        "valueCode": "4.0.0"
      } ],
      "alias": [ "extensions", "user content" ],
      "max": "*",
      "id": "Flag.identifier.extension",
      "condition": [ "ele-1" ],
      "comment": "There can be no stigma associated with the use of extensions by any application, project, or standard - regardless of the institution or jurisdiction that uses or defines the extensions.  The use of extensions is what allows the FHIR specification to retain a core level of simplicity for everyone.",
      "base": {
        "max": "*",
        "min": 0,
        "path": "Element.extension"
      }
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "http://hl7.org/fhir/StructureDefinition/Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Flag.identifier.use",
      "requirements": "Allows the appropriate identifier for a particular context of use to be selected from among a set of identifiers.",
      "min": 0,
      "definition": "The purpose of this identifier.",
      "isModifier": true,
      "short": "usual | official | temp | secondary | old (If known)",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "N/A",
        "identity": "v2"
      }, {
        "map": "Role.code or implied by context",
        "identity": "rim"
      } ],
      "type": [ {
        "code": "code"
      } ],
      "extension": [ {
        "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-standards-status",
        "valueCode": "normative"
      }, {
        "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-normative-version",
        "valueCode": "4.0.0"
      } ],
      "binding": {
        "strength": "required",
        "valueSet": "http://hl7.org/fhir/ValueSet/identifier-use|4.0.1",
        "extension": [ {
          "url": "http://hl7.org/fhir/StructureDefinition/elementdefinition-bindingName",
          "valueString": "IdentifierUse"
        } ],
        "description": "Identifies the purpose for this identifier, if known ."
      },
      "max": "1",
      "id": "Flag.identifier.use",
      "condition": [ "ele-1" ],
      "comment": "Applications can assume that an identifier is permanent unless it explicitly says that it is temporary.",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Identifier.use"
      },
      "isModifierReason": "This is labeled as \"Is Modifier\" because applications should not mistake a temporary id for a permanent one.",
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "http://hl7.org/fhir/StructureDefinition/Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Flag.identifier.type",
      "requirements": "Allows users to make use of identifiers when the identifier system is not known.",
      "min": 0,
      "definition": "A coded type for the identifier that can be used to determine which identifier to use for a specific purpose.",
      "short": "Description of identifier",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "CE/CNE/CWE",
        "identity": "v2"
      }, {
        "map": "CD",
        "identity": "rim"
      }, {
        "map": "fhir:CodeableConcept rdfs:subClassOf dt:CD",
        "identity": "orim"
      }, {
        "map": "CX.5",
        "identity": "v2"
      }, {
        "map": "Role.code or implied by context",
        "identity": "rim"
      } ],
      "type": [ {
        "code": "CodeableConcept"
      } ],
      "extension": [ {
        "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-standards-status",
        "valueCode": "normative"
      }, {
        "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-normative-version",
        "valueCode": "4.0.0"
      } ],
      "binding": {
        "strength": "extensible",
        "valueSet": "http://hl7.org/fhir/ValueSet/identifier-type",
        "extension": [ {
          "url": "http://hl7.org/fhir/StructureDefinition/elementdefinition-bindingName",
          "valueString": "IdentifierType"
        }, {
          "url": "http://hl7.org/fhir/StructureDefinition/elementdefinition-isCommonBinding",
          "valueBoolean": true
        } ],
        "description": "A coded type for an identifier that can be used to determine which identifier to use for a specific purpose."
      },
      "max": "1",
      "id": "Flag.identifier.type",
      "condition": [ "ele-1" ],
      "comment": "This element deals only with general categories of identifiers.  It SHOULD not be used for codes that correspond 1..1 with the Identifier.system. Some identifiers may fall into multiple categories due to common usage.   Where the system is known, a type is unnecessary because the type is always part of the system definition. However systems often need to handle identifiers where the system is not known. There is not a 1:1 relationship between type and system, since many different systems have the same type.",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Identifier.type"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "http://hl7.org/fhir/StructureDefinition/Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Flag.identifier.system",
      "requirements": "There are many sets  of identifiers.  To perform matching of two identifiers, we need to know what set we're dealing with. The system identifies a particular set of unique identifiers.",
      "min": 1,
      "definition": "Establishes the namespace for the value - that is, a URL that describes a set values that are unique.",
      "short": "The namespace for the identifier value",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "CX.4 / EI-2-4",
        "identity": "v2"
      }, {
        "map": "II.root or Role.id.root",
        "identity": "rim"
      }, {
        "map": "./IdentifierType",
        "identity": "servd"
      } ],
      "type": [ {
        "code": "uri"
      } ],
      "extension": [ {
        "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-standards-status",
        "valueCode": "normative"
      }, {
        "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-normative-version",
        "valueCode": "4.0.0"
      } ],
      "max": "1",
      "id": "Flag.identifier.system",
      "condition": [ "ele-1" ],
      "comment": "Identifier.system is always case sensitive.",
      "example": [ {
        "label": "General",
        "valueUri": "http://www.acme.com/identifiers/patient"
      } ],
      "base": {
        "max": "1",
        "min": 0,
        "path": "Identifier.system"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "http://hl7.org/fhir/StructureDefinition/Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Flag.identifier.value",
      "min": 1,
      "definition": "The portion of the identifier typically relevant to the user and which is unique within the context of the system.",
      "short": "The value that is unique within the system.",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "CX.1 / EI.1",
        "identity": "v2"
      }, {
        "map": "II.extension or II.root if system indicates OID or GUID (Or Role.id.extension or root)",
        "identity": "rim"
      }, {
        "map": "./Value",
        "identity": "servd"
      } ],
      "type": [ {
        "code": "string"
      } ],
      "extension": [ {
        "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-standards-status",
        "valueCode": "normative"
      }, {
        "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-normative-version",
        "valueCode": "4.0.0"
      } ],
      "max": "1",
      "id": "Flag.identifier.value",
      "condition": [ "ele-1" ],
      "comment": "If the value is a full URI, then the system SHALL be urn:ietf:rfc:3986.  The value's primary purpose is computational mapping.  As a result, it may be normalized for comparison purposes (e.g. removing non-significant whitespace, dashes, etc.)  A value formatted for human display can be conveyed using the [Rendered Value extension](extension-rendered-value.html). Identifier.value is to be treated as case sensitive unless knowledge of the Identifier.system allows the processer to be confident that non-case-sensitive processing is safe.",
      "example": [ {
        "label": "General",
        "valueString": "123456"
      } ],
      "base": {
        "max": "1",
        "min": 0,
        "path": "Identifier.value"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "http://hl7.org/fhir/StructureDefinition/Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      }, {
        "key": "per-1",
        "human": "If present, start SHALL have a lower value than end",
        "xpath": "not(exists(f:start/@value)) or not(exists(f:end/@value)) or (xs:dateTime(f:start/@value) <= xs:dateTime(f:end/@value))",
        "source": "http://hl7.org/fhir/StructureDefinition/Account",
        "severity": "error",
        "expression": "start.hasValue().not() or end.hasValue().not() or (start <= end)"
      } ],
      "path": "Flag.identifier.period",
      "min": 0,
      "definition": "Time period during which identifier is/was valid for use.",
      "short": "Time period when id is/was valid for use",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "DR",
        "identity": "v2"
      }, {
        "map": "IVL[lowClosed=\"true\" and highClosed=\"true\"] or URG[lowClosed=\"true\" and highClosed=\"true\"]",
        "identity": "rim"
      }, {
        "map": "CX.7 + CX.8",
        "identity": "v2"
      }, {
        "map": "Role.effectiveTime or implied by context",
        "identity": "rim"
      }, {
        "map": "./StartDate and ./EndDate",
        "identity": "servd"
      } ],
      "type": [ {
        "code": "Period"
      } ],
      "extension": [ {
        "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-standards-status",
        "valueCode": "normative"
      }, {
        "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-normative-version",
        "valueCode": "4.0.0"
      } ],
      "max": "1",
      "id": "Flag.identifier.period",
      "condition": [ "ele-1" ],
      "comment": "A Period specifies a range of time; the context of use will specify whether the entire range applies (e.g. \"the patient was an inpatient of the hospital for this time range\") or one value from the range applies (e.g. \"give to the patient between these two times\").\n\nPeriod is not used for a duration (a measure of elapsed time). See [Duration](datatypes.html#Duration).",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Identifier.period"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "http://hl7.org/fhir/StructureDefinition/Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      }, {
        "key": "ref-1",
        "human": "SHALL have a contained resource if a local reference is provided",
        "xpath": "not(starts-with(f:reference/@value, '#')) or exists(ancestor::*[self::f:entry or self::f:parameter]/f:resource/f:*/f:contained/f:*[f:id/@value=substring-after(current()/f:reference/@value, '#')]|/*/f:contained/f:*[f:id/@value=substring-after(current()/f:reference/@value, '#')])",
        "source": "http://hl7.org/fhir/StructureDefinition/Account",
        "severity": "error",
        "expression": "reference.startsWith('#').not() or (reference.substring(1).trace('url') in %rootResource.contained.id.trace('ids'))"
      } ],
      "path": "Flag.identifier.assigner",
      "min": 0,
      "definition": "Organization that issued/manages the identifier.",
      "short": "Organization that issued id (may be just text)",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "The target of a resource reference is a RIM entry point (Act, Role, or Entity)",
        "identity": "rim"
      }, {
        "map": "CX.4 / (CX.4,CX.9,CX.10)",
        "identity": "v2"
      }, {
        "map": "II.assigningAuthorityName but note that this is an improper use by the definition of the field.  Also Role.scoper",
        "identity": "rim"
      }, {
        "map": "./IdentifierIssuingAuthority",
        "identity": "servd"
      } ],
      "type": [ {
        "code": "Reference",
        "targetProfile": [ "http://hl7.org/fhir/StructureDefinition/Organization" ]
      } ],
      "extension": [ {
        "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-standards-status",
        "valueCode": "normative"
      }, {
        "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-normative-version",
        "valueCode": "4.0.0"
      } ],
      "max": "1",
      "id": "Flag.identifier.assigner",
      "condition": [ "ele-1" ],
      "comment": "The Identifier.assigner may omit the .reference element and only contain a .display element reflecting the name or other textual information about the assigning organization.",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Identifier.assigner"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "http://hl7.org/fhir/StructureDefinition/Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Flag.identifier",
      "requirements": "Allows identification of the flag as it is known by various participating systems and in a way that remains consistent across servers.",
      "min": 0,
      "definition": "Business identifiers assigned to this flag by the performer or other systems which remain constant as the resource is updated and propagates from server to server.",
      "isModifier": false,
      "short": "Business identifier",
      "mapping": [ {
        "map": "FiveWs.identifier",
        "identity": "w5"
      }, {
        "map": ".id",
        "identity": "rim"
      } ],
      "type": [ {
        "code": "Identifier"
      } ],
      "sliceName": "demogAlert",
      "max": "1",
      "id": "Flag.identifier:demogAlert",
      "comment": "This is a business identifier, not a resource identifier (see [discussion](resource.html#identifiers)).  It is best practice for the identifier to only appear on a single resource instance, however business practices may occasionally dictate that multiple resource instances with the same identifier can exist - possibly even with different resource types.  For example, multiple Patient and a Person resource instance might share the same social insurance number.",
      "base": {
        "max": "*",
        "min": 0,
        "path": "Flag.identifier"
      },
      "isSummary": true
    }, {
      "path": "Flag.identifier.id",
      "min": 0,
      "definition": "Unique id for the element within a resource (for internal references). This may be any string value that does not contain spaces.",
      "short": "Unique id for inter-element referencing",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      } ],
      "type": [ {
        "code": "http://hl7.org/fhirpath/System.String",
        "extension": [ {
          "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-fhir-type",
          "valueUrl": "string"
        } ]
      } ],
      "representation": [ "xmlAttr" ],
      "max": "1",
      "id": "Flag.identifier:demogAlert.id",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Element.id"
      }
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "http://hl7.org/fhir/StructureDefinition/Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      }, {
        "key": "ext-1",
        "human": "Must have either extensions or value[x], not both",
        "xpath": "exists(f:extension)!=exists(f:*[starts-with(local-name(.), 'value')])",
        "source": "http://hl7.org/fhir/StructureDefinition/Element",
        "severity": "error",
        "expression": "extension.exists() != value.exists()"
      } ],
      "path": "Flag.identifier.extension",
      "min": 0,
      "definition": "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.",
      "short": "Additional content defined by implementations",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "N/A",
        "identity": "rim"
      } ],
      "slicing": {
        "rules": "open",
        "description": "Extensions are always sliced by (at least) url",
        "discriminator": [ {
          "path": "url",
          "type": "value"
        } ]
      },
      "type": [ {
        "code": "Extension"
      } ],
      "extension": [ {
        "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-standards-status",
        "valueCode": "normative"
      }, {
        "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-normative-version",
        "valueCode": "4.0.0"
      } ],
      "alias": [ "extensions", "user content" ],
      "max": "*",
      "id": "Flag.identifier:demogAlert.extension",
      "condition": [ "ele-1" ],
      "comment": "There can be no stigma associated with the use of extensions by any application, project, or standard - regardless of the institution or jurisdiction that uses or defines the extensions.  The use of extensions is what allows the FHIR specification to retain a core level of simplicity for everyone.",
      "base": {
        "max": "*",
        "min": 0,
        "path": "Element.extension"
      }
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "http://hl7.org/fhir/StructureDefinition/Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Flag.identifier.use",
      "requirements": "Allows the appropriate identifier for a particular context of use to be selected from among a set of identifiers.",
      "min": 0,
      "definition": "The purpose of this identifier.",
      "isModifier": true,
      "short": "usual | official | temp | secondary | old (If known)",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "N/A",
        "identity": "v2"
      }, {
        "map": "Role.code or implied by context",
        "identity": "rim"
      } ],
      "type": [ {
        "code": "code"
      } ],
      "extension": [ {
        "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-standards-status",
        "valueCode": "normative"
      }, {
        "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-normative-version",
        "valueCode": "4.0.0"
      } ],
      "binding": {
        "strength": "required",
        "valueSet": "http://hl7.org/fhir/ValueSet/identifier-use|4.0.1",
        "extension": [ {
          "url": "http://hl7.org/fhir/StructureDefinition/elementdefinition-bindingName",
          "valueString": "IdentifierUse"
        } ],
        "description": "Identifies the purpose for this identifier, if known ."
      },
      "max": "1",
      "id": "Flag.identifier:demogAlert.use",
      "condition": [ "ele-1" ],
      "comment": "Applications can assume that an identifier is permanent unless it explicitly says that it is temporary.",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Identifier.use"
      },
      "isModifierReason": "This is labeled as \"Is Modifier\" because applications should not mistake a temporary id for a permanent one.",
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "http://hl7.org/fhir/StructureDefinition/Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Flag.identifier.type",
      "requirements": "Allows users to make use of identifiers when the identifier system is not known.",
      "min": 0,
      "definition": "A coded type for the identifier that can be used to determine which identifier to use for a specific purpose.",
      "short": "Description of identifier",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "CE/CNE/CWE",
        "identity": "v2"
      }, {
        "map": "CD",
        "identity": "rim"
      }, {
        "map": "fhir:CodeableConcept rdfs:subClassOf dt:CD",
        "identity": "orim"
      }, {
        "map": "CX.5",
        "identity": "v2"
      }, {
        "map": "Role.code or implied by context",
        "identity": "rim"
      } ],
      "type": [ {
        "code": "CodeableConcept"
      } ],
      "extension": [ {
        "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-standards-status",
        "valueCode": "normative"
      }, {
        "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-normative-version",
        "valueCode": "4.0.0"
      } ],
      "binding": {
        "strength": "extensible",
        "valueSet": "http://hl7.org/fhir/ValueSet/identifier-type",
        "extension": [ {
          "url": "http://hl7.org/fhir/StructureDefinition/elementdefinition-bindingName",
          "valueString": "IdentifierType"
        }, {
          "url": "http://hl7.org/fhir/StructureDefinition/elementdefinition-isCommonBinding",
          "valueBoolean": true
        } ],
        "description": "A coded type for an identifier that can be used to determine which identifier to use for a specific purpose."
      },
      "max": "1",
      "id": "Flag.identifier:demogAlert.type",
      "condition": [ "ele-1" ],
      "comment": "This element deals only with general categories of identifiers.  It SHOULD not be used for codes that correspond 1..1 with the Identifier.system. Some identifiers may fall into multiple categories due to common usage.   Where the system is known, a type is unnecessary because the type is always part of the system definition. However systems often need to handle identifiers where the system is not known. There is not a 1:1 relationship between type and system, since many different systems have the same type.",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Identifier.type"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "http://hl7.org/fhir/StructureDefinition/Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Flag.identifier.system",
      "requirements": "There are many sets  of identifiers.  To perform matching of two identifiers, we need to know what set we're dealing with. The system identifies a particular set of unique identifiers.",
      "min": 1,
      "definition": "Establishes the namespace for the value - that is, a URL that describes a set values that are unique.",
      "short": "The namespace for the identifier value",
      "fixedUri": "http://fhir.laniado.org.il/Identifier/demog-alert",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "CX.4 / EI-2-4",
        "identity": "v2"
      }, {
        "map": "II.root or Role.id.root",
        "identity": "rim"
      }, {
        "map": "./IdentifierType",
        "identity": "servd"
      } ],
      "type": [ {
        "code": "uri"
      } ],
      "extension": [ {
        "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-standards-status",
        "valueCode": "normative"
      }, {
        "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-normative-version",
        "valueCode": "4.0.0"
      } ],
      "max": "1",
      "id": "Flag.identifier:demogAlert.system",
      "condition": [ "ele-1" ],
      "comment": "Identifier.system is always case sensitive.",
      "example": [ {
        "label": "General",
        "valueUri": "http://www.acme.com/identifiers/patient"
      } ],
      "base": {
        "max": "1",
        "min": 0,
        "path": "Identifier.system"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "http://hl7.org/fhir/StructureDefinition/Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Flag.identifier.value",
      "min": 1,
      "definition": "The portion of the identifier typically relevant to the user and which is unique within the context of the system.",
      "short": "The value that is unique within the system.",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "CX.1 / EI.1",
        "identity": "v2"
      }, {
        "map": "II.extension or II.root if system indicates OID or GUID (Or Role.id.extension or root)",
        "identity": "rim"
      }, {
        "map": "./Value",
        "identity": "servd"
      } ],
      "type": [ {
        "code": "string"
      } ],
      "extension": [ {
        "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-standards-status",
        "valueCode": "normative"
      }, {
        "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-normative-version",
        "valueCode": "4.0.0"
      } ],
      "max": "1",
      "id": "Flag.identifier:demogAlert.value",
      "condition": [ "ele-1" ],
      "comment": "If the value is a full URI, then the system SHALL be urn:ietf:rfc:3986.  The value's primary purpose is computational mapping.  As a result, it may be normalized for comparison purposes (e.g. removing non-significant whitespace, dashes, etc.)  A value formatted for human display can be conveyed using the [Rendered Value extension](extension-rendered-value.html). Identifier.value is to be treated as case sensitive unless knowledge of the Identifier.system allows the processer to be confident that non-case-sensitive processing is safe.",
      "example": [ {
        "label": "General",
        "valueString": "123456"
      } ],
      "base": {
        "max": "1",
        "min": 0,
        "path": "Identifier.value"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "http://hl7.org/fhir/StructureDefinition/Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      }, {
        "key": "per-1",
        "human": "If present, start SHALL have a lower value than end",
        "xpath": "not(exists(f:start/@value)) or not(exists(f:end/@value)) or (xs:dateTime(f:start/@value) <= xs:dateTime(f:end/@value))",
        "source": "http://hl7.org/fhir/StructureDefinition/Account",
        "severity": "error",
        "expression": "start.hasValue().not() or end.hasValue().not() or (start <= end)"
      } ],
      "path": "Flag.identifier.period",
      "min": 0,
      "definition": "Time period during which identifier is/was valid for use.",
      "short": "Time period when id is/was valid for use",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "DR",
        "identity": "v2"
      }, {
        "map": "IVL[lowClosed=\"true\" and highClosed=\"true\"] or URG[lowClosed=\"true\" and highClosed=\"true\"]",
        "identity": "rim"
      }, {
        "map": "CX.7 + CX.8",
        "identity": "v2"
      }, {
        "map": "Role.effectiveTime or implied by context",
        "identity": "rim"
      }, {
        "map": "./StartDate and ./EndDate",
        "identity": "servd"
      } ],
      "type": [ {
        "code": "Period"
      } ],
      "extension": [ {
        "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-standards-status",
        "valueCode": "normative"
      }, {
        "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-normative-version",
        "valueCode": "4.0.0"
      } ],
      "max": "1",
      "id": "Flag.identifier:demogAlert.period",
      "condition": [ "ele-1" ],
      "comment": "A Period specifies a range of time; the context of use will specify whether the entire range applies (e.g. \"the patient was an inpatient of the hospital for this time range\") or one value from the range applies (e.g. \"give to the patient between these two times\").\n\nPeriod is not used for a duration (a measure of elapsed time). See [Duration](datatypes.html#Duration).",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Identifier.period"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "http://hl7.org/fhir/StructureDefinition/Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      }, {
        "key": "ref-1",
        "human": "SHALL have a contained resource if a local reference is provided",
        "xpath": "not(starts-with(f:reference/@value, '#')) or exists(ancestor::*[self::f:entry or self::f:parameter]/f:resource/f:*/f:contained/f:*[f:id/@value=substring-after(current()/f:reference/@value, '#')]|/*/f:contained/f:*[f:id/@value=substring-after(current()/f:reference/@value, '#')])",
        "source": "http://hl7.org/fhir/StructureDefinition/Account",
        "severity": "error",
        "expression": "reference.startsWith('#').not() or (reference.substring(1).trace('url') in %rootResource.contained.id.trace('ids'))"
      } ],
      "path": "Flag.identifier.assigner",
      "min": 0,
      "definition": "Organization that issued/manages the identifier.",
      "short": "Organization that issued id (may be just text)",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "The target of a resource reference is a RIM entry point (Act, Role, or Entity)",
        "identity": "rim"
      }, {
        "map": "CX.4 / (CX.4,CX.9,CX.10)",
        "identity": "v2"
      }, {
        "map": "II.assigningAuthorityName but note that this is an improper use by the definition of the field.  Also Role.scoper",
        "identity": "rim"
      }, {
        "map": "./IdentifierIssuingAuthority",
        "identity": "servd"
      } ],
      "type": [ {
        "code": "Reference",
        "targetProfile": [ "http://hl7.org/fhir/StructureDefinition/Organization" ]
      } ],
      "extension": [ {
        "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-standards-status",
        "valueCode": "normative"
      }, {
        "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-normative-version",
        "valueCode": "4.0.0"
      } ],
      "max": "1",
      "id": "Flag.identifier:demogAlert.assigner",
      "condition": [ "ele-1" ],
      "comment": "The Identifier.assigner may omit the .reference element and only contain a .display element reflecting the name or other textual information about the assigning organization.",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Identifier.assigner"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "http://hl7.org/fhir/StructureDefinition/Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Flag.status",
      "min": 1,
      "definition": "Supports basic workflow.",
      "isModifier": true,
      "short": "active | inactive | entered-in-error",
      "mapping": [ {
        "map": "FiveWs.status",
        "identity": "w5"
      }, {
        "map": ".status",
        "identity": "rim"
      } ],
      "type": [ {
        "code": "code"
      } ],
      "binding": {
        "strength": "required",
        "valueSet": "http://hl7.org/fhir/ValueSet/flag-status|4.0.1",
        "extension": [ {
          "url": "http://hl7.org/fhir/StructureDefinition/elementdefinition-bindingName",
          "valueString": "FlagStatus"
        } ],
        "description": "Indicates whether this flag is active and needs to be displayed to a user, or whether it is no longer needed or was entered in error."
      },
      "max": "1",
      "id": "Flag.status",
      "comment": "This element is labeled as a modifier because the status contains codes that mark the resource as not currently valid.",
      "base": {
        "max": "1",
        "min": 1,
        "path": "Flag.status"
      },
      "isModifierReason": "This element is labelled as a modifier because it is a status element that contains status entered-in-error which means that the resource should not be treated as valid",
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "http://hl7.org/fhir/StructureDefinition/Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Flag.category",
      "min": 1,
      "definition": "Allows a flag to be divided into different categories like clinical, administrative etc. Intended to be used as a means of filtering which flags are displayed to particular user or in a given context.",
      "isModifier": false,
      "short": "Clinical, administrative, etc.",
      "mapping": [ {
        "map": "FiveWs.class",
        "identity": "w5"
      }, {
        "map": ".code",
        "identity": "rim"
      } ],
      "type": [ {
        "code": "CodeableConcept"
      } ],
      "binding": {
        "strength": "example",
        "valueSet": "http://hl7.org/fhir/ValueSet/flag-category",
        "extension": [ {
          "url": "http://hl7.org/fhir/StructureDefinition/elementdefinition-bindingName",
          "valueString": "FlagCategory"
        } ],
        "description": "A general category for flags for filtering/display purposes."
      },
      "max": "*",
      "id": "Flag.category",
      "comment": "The value set will often need to be adjusted based on local business rules and usage context.",
      "base": {
        "max": "*",
        "min": 0,
        "path": "Flag.category"
      },
      "isSummary": true
    }, {
      "path": "Flag.category.id",
      "min": 0,
      "definition": "Unique id for the element within a resource (for internal references). This may be any string value that does not contain spaces.",
      "short": "Unique id for inter-element referencing",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      } ],
      "type": [ {
        "code": "http://hl7.org/fhirpath/System.String",
        "extension": [ {
          "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-fhir-type",
          "valueUrl": "string"
        } ]
      } ],
      "representation": [ "xmlAttr" ],
      "max": "1",
      "id": "Flag.category.id",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Element.id"
      }
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "http://hl7.org/fhir/StructureDefinition/Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      }, {
        "key": "ext-1",
        "human": "Must have either extensions or value[x], not both",
        "xpath": "exists(f:extension)!=exists(f:*[starts-with(local-name(.), 'value')])",
        "source": "http://hl7.org/fhir/StructureDefinition/Element",
        "severity": "error",
        "expression": "extension.exists() != value.exists()"
      } ],
      "path": "Flag.category.extension",
      "min": 0,
      "definition": "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.",
      "short": "Additional content defined by implementations",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "N/A",
        "identity": "rim"
      } ],
      "slicing": {
        "rules": "open",
        "description": "Extensions are always sliced by (at least) url",
        "discriminator": [ {
          "path": "url",
          "type": "value"
        } ]
      },
      "type": [ {
        "code": "Extension"
      } ],
      "extension": [ {
        "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-standards-status",
        "valueCode": "normative"
      }, {
        "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-normative-version",
        "valueCode": "4.0.0"
      } ],
      "alias": [ "extensions", "user content" ],
      "max": "*",
      "id": "Flag.category.extension",
      "condition": [ "ele-1" ],
      "comment": "There can be no stigma associated with the use of extensions by any application, project, or standard - regardless of the institution or jurisdiction that uses or defines the extensions.  The use of extensions is what allows the FHIR specification to retain a core level of simplicity for everyone.",
      "base": {
        "max": "*",
        "min": 0,
        "path": "Element.extension"
      }
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "http://hl7.org/fhir/StructureDefinition/Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Flag.category.coding",
      "requirements": "Allows for alternative encodings within a code system, and translations to other code systems.",
      "min": 0,
      "definition": "A reference to a code defined by a terminology system.",
      "short": "Code defined by a terminology system",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "CE/CNE/CWE subset one of the sets of component 1-3 or 4-6",
        "identity": "v2"
      }, {
        "map": "CV",
        "identity": "rim"
      }, {
        "map": "fhir:Coding rdfs:subClassOf dt:CDCoding",
        "identity": "orim"
      }, {
        "map": "C*E.1-8, C*E.10-22",
        "identity": "v2"
      }, {
        "map": "union(., ./translation)",
        "identity": "rim"
      }, {
        "map": "fhir:CodeableConcept.coding rdfs:subPropertyOf dt:CD.coding",
        "identity": "orim"
      } ],
      "slicing": {
        "rules": "open",
        "discriminator": [ {
          "path": "code",
          "type": "value"
        } ]
      },
      "type": [ {
        "code": "Coding"
      } ],
      "extension": [ {
        "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-standards-status",
        "valueCode": "normative"
      }, {
        "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-normative-version",
        "valueCode": "4.0.0"
      } ],
      "max": "*",
      "id": "Flag.category.coding",
      "condition": [ "ele-1" ],
      "comment": "Codes may be defined very casually in enumerations, or code lists, up to very formal definitions such as SNOMED CT - see the HL7 v3 Core Principles for more information.  Ordering of codings is undefined and SHALL NOT be used to infer meaning. Generally, at most only one of the coding values will be labeled as UserSelected = true.",
      "base": {
        "max": "*",
        "min": 0,
        "path": "CodeableConcept.coding"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "http://hl7.org/fhir/StructureDefinition/Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Flag.category.coding",
      "requirements": "Allows for alternative encodings within a code system, and translations to other code systems.",
      "min": 0,
      "definition": "A reference to a code defined by a terminology system.",
      "short": "Code defined by a terminology system",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "CE/CNE/CWE subset one of the sets of component 1-3 or 4-6",
        "identity": "v2"
      }, {
        "map": "CV",
        "identity": "rim"
      }, {
        "map": "fhir:Coding rdfs:subClassOf dt:CDCoding",
        "identity": "orim"
      }, {
        "map": "C*E.1-8, C*E.10-22",
        "identity": "v2"
      }, {
        "map": "union(., ./translation)",
        "identity": "rim"
      }, {
        "map": "fhir:CodeableConcept.coding rdfs:subPropertyOf dt:CD.coding",
        "identity": "orim"
      } ],
      "type": [ {
        "code": "Coding"
      } ],
      "sliceName": "alert",
      "extension": [ {
        "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-standards-status",
        "valueCode": "normative"
      }, {
        "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-normative-version",
        "valueCode": "4.0.0"
      } ],
      "max": "1",
      "id": "Flag.category.coding:alert",
      "condition": [ "ele-1" ],
      "comment": "Codes may be defined very casually in enumerations, or code lists, up to very formal definitions such as SNOMED CT - see the HL7 v3 Core Principles for more information.  Ordering of codings is undefined and SHALL NOT be used to infer meaning. Generally, at most only one of the coding values will be labeled as UserSelected = true.",
      "base": {
        "max": "*",
        "min": 0,
        "path": "CodeableConcept.coding"
      },
      "isSummary": true
    }, {
      "path": "Flag.category.coding.id",
      "min": 0,
      "definition": "Unique id for the element within a resource (for internal references). This may be any string value that does not contain spaces.",
      "short": "Unique id for inter-element referencing",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      } ],
      "type": [ {
        "code": "http://hl7.org/fhirpath/System.String",
        "extension": [ {
          "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-fhir-type",
          "valueUrl": "string"
        } ]
      } ],
      "representation": [ "xmlAttr" ],
      "max": "1",
      "id": "Flag.category.coding:alert.id",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Element.id"
      }
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "http://hl7.org/fhir/StructureDefinition/Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      }, {
        "key": "ext-1",
        "human": "Must have either extensions or value[x], not both",
        "xpath": "exists(f:extension)!=exists(f:*[starts-with(local-name(.), 'value')])",
        "source": "http://hl7.org/fhir/StructureDefinition/Element",
        "severity": "error",
        "expression": "extension.exists() != value.exists()"
      } ],
      "path": "Flag.category.coding.extension",
      "min": 0,
      "definition": "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.",
      "short": "Additional content defined by implementations",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "N/A",
        "identity": "rim"
      } ],
      "slicing": {
        "rules": "open",
        "description": "Extensions are always sliced by (at least) url",
        "discriminator": [ {
          "path": "url",
          "type": "value"
        } ]
      },
      "type": [ {
        "code": "Extension"
      } ],
      "extension": [ {
        "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-standards-status",
        "valueCode": "normative"
      }, {
        "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-normative-version",
        "valueCode": "4.0.0"
      } ],
      "alias": [ "extensions", "user content" ],
      "max": "*",
      "id": "Flag.category.coding:alert.extension",
      "condition": [ "ele-1" ],
      "comment": "There can be no stigma associated with the use of extensions by any application, project, or standard - regardless of the institution or jurisdiction that uses or defines the extensions.  The use of extensions is what allows the FHIR specification to retain a core level of simplicity for everyone.",
      "base": {
        "max": "*",
        "min": 0,
        "path": "Element.extension"
      }
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "http://hl7.org/fhir/StructureDefinition/Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Flag.category.coding.system",
      "requirements": "Need to be unambiguous about the source of the definition of the symbol.",
      "min": 0,
      "definition": "The identification of the code system that defines the meaning of the symbol in the code.",
      "short": "Identity of the terminology system",
      "fixedUri": "http://loinc.org",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "C*E.3",
        "identity": "v2"
      }, {
        "map": "./codeSystem",
        "identity": "rim"
      }, {
        "map": "fhir:Coding.system rdfs:subPropertyOf dt:CDCoding.codeSystem",
        "identity": "orim"
      } ],
      "type": [ {
        "code": "uri"
      } ],
      "extension": [ {
        "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-standards-status",
        "valueCode": "normative"
      }, {
        "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-normative-version",
        "valueCode": "4.0.0"
      } ],
      "max": "1",
      "id": "Flag.category.coding:alert.system",
      "condition": [ "ele-1" ],
      "comment": "The URI may be an OID (urn:oid:...) or a UUID (urn:uuid:...).  OIDs and UUIDs SHALL be references to the HL7 OID registry. Otherwise, the URI should come from HL7's list of FHIR defined special URIs or it should reference to some definition that establishes the system clearly and unambiguously.",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Coding.system"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "http://hl7.org/fhir/StructureDefinition/Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Flag.category.coding.version",
      "min": 0,
      "definition": "The version of the code system which was used when choosing this code. Note that a well-maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged.",
      "short": "Version of the system - if relevant",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "C*E.7",
        "identity": "v2"
      }, {
        "map": "./codeSystemVersion",
        "identity": "rim"
      }, {
        "map": "fhir:Coding.version rdfs:subPropertyOf dt:CDCoding.codeSystemVersion",
        "identity": "orim"
      } ],
      "type": [ {
        "code": "string"
      } ],
      "extension": [ {
        "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-standards-status",
        "valueCode": "normative"
      }, {
        "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-normative-version",
        "valueCode": "4.0.0"
      } ],
      "max": "1",
      "id": "Flag.category.coding:alert.version",
      "condition": [ "ele-1" ],
      "comment": "Where the terminology does not clearly define what string should be used to identify code system versions, the recommendation is to use the date (expressed in FHIR date format) on which that version was officially published as the version date.",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Coding.version"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "http://hl7.org/fhir/StructureDefinition/Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Flag.category.coding.code",
      "fixedCode": "74018-3",
      "requirements": "Need to refer to a particular code in the system.",
      "min": 1,
      "definition": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post-coordination).",
      "short": "Symbol in syntax defined by the system",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "C*E.1",
        "identity": "v2"
      }, {
        "map": "./code",
        "identity": "rim"
      }, {
        "map": "fhir:Coding.code rdfs:subPropertyOf dt:CDCoding.code",
        "identity": "orim"
      } ],
      "type": [ {
        "code": "code"
      } ],
      "extension": [ {
        "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-standards-status",
        "valueCode": "normative"
      }, {
        "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-normative-version",
        "valueCode": "4.0.0"
      } ],
      "max": "1",
      "id": "Flag.category.coding:alert.code",
      "condition": [ "ele-1" ],
      "comment": "Note that FHIR strings SHALL NOT exceed 1MB in size",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Coding.code"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "http://hl7.org/fhir/StructureDefinition/Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Flag.category.coding.display",
      "requirements": "Need to be able to carry a human-readable meaning of the code for readers that do not know  the system.",
      "min": 0,
      "definition": "A representation of the meaning of the code in the system, following the rules of the system.",
      "short": "Representation defined by the system",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "C*E.2 - but note this is not well followed",
        "identity": "v2"
      }, {
        "map": "CV.displayName",
        "identity": "rim"
      }, {
        "map": "fhir:Coding.display rdfs:subPropertyOf dt:CDCoding.displayName",
        "identity": "orim"
      } ],
      "type": [ {
        "code": "string"
      } ],
      "extension": [ {
        "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-standards-status",
        "valueCode": "normative"
      }, {
        "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-normative-version",
        "valueCode": "4.0.0"
      }, {
        "url": "http://hl7.org/fhir/StructureDefinition/elementdefinition-translatable",
        "valueBoolean": true
      } ],
      "max": "1",
      "fixedString": "Alert category",
      "id": "Flag.category.coding:alert.display",
      "condition": [ "ele-1" ],
      "comment": "Note that FHIR strings SHALL NOT exceed 1MB in size",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Coding.display"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "http://hl7.org/fhir/StructureDefinition/Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Flag.category.coding.userSelected",
      "requirements": "This has been identified as a clinical safety criterium - that this exact system/code pair was chosen explicitly, rather than inferred by the system based on some rules or language processing.",
      "min": 0,
      "definition": "Indicates that this coding was chosen by a user directly - e.g. off a pick list of available items (codes or displays).",
      "short": "If this coding was chosen directly by the user",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "Sometimes implied by being first",
        "identity": "v2"
      }, {
        "map": "CD.codingRationale",
        "identity": "rim"
      }, {
        "map": "fhir:Coding.userSelected fhir:mapsTo dt:CDCoding.codingRationale. fhir:Coding.userSelected fhir:hasMap fhir:Coding.userSelected.map. fhir:Coding.userSelected.map a fhir:Map;   fhir:target dt:CDCoding.codingRationale. fhir:Coding.userSelected\\#true a [     fhir:source \"true\";     fhir:target dt:CDCoding.codingRationale\\#O   ]",
        "identity": "orim"
      } ],
      "type": [ {
        "code": "boolean"
      } ],
      "extension": [ {
        "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-standards-status",
        "valueCode": "normative"
      }, {
        "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-normative-version",
        "valueCode": "4.0.0"
      } ],
      "max": "1",
      "id": "Flag.category.coding:alert.userSelected",
      "condition": [ "ele-1" ],
      "comment": "Amongst a set of alternatives, a directly chosen code is the most appropriate starting point for new translations. There is some ambiguity about what exactly 'directly chosen' implies, and trading partner agreement may be needed to clarify the use of this element and its consequences more completely.",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Coding.userSelected"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "http://hl7.org/fhir/StructureDefinition/Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Flag.category.text",
      "requirements": "The codes from the terminologies do not always capture the correct meaning with all the nuances of the human using them, or sometimes there is no appropriate code at all. In these cases, the text is used to capture the full meaning of the source.",
      "min": 0,
      "definition": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user.",
      "short": "Plain text representation of the concept",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "C*E.9. But note many systems use C*E.2 for this",
        "identity": "v2"
      }, {
        "map": "./originalText[mediaType/code=\"text/plain\"]/data",
        "identity": "rim"
      }, {
        "map": "fhir:CodeableConcept.text rdfs:subPropertyOf dt:CD.originalText",
        "identity": "orim"
      } ],
      "type": [ {
        "code": "string"
      } ],
      "extension": [ {
        "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-standards-status",
        "valueCode": "normative"
      }, {
        "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-normative-version",
        "valueCode": "4.0.0"
      }, {
        "url": "http://hl7.org/fhir/StructureDefinition/elementdefinition-translatable",
        "valueBoolean": true
      } ],
      "max": "1",
      "id": "Flag.category.text",
      "condition": [ "ele-1" ],
      "comment": "Very often the text is the same as a displayName of one of the codings.",
      "base": {
        "max": "1",
        "min": 0,
        "path": "CodeableConcept.text"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "http://hl7.org/fhir/StructureDefinition/Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Flag.code",
      "min": 1,
      "definition": "The coded value or textual component of the flag to display to the user.",
      "isModifier": false,
      "short": "Coded or textual message to display to user",
      "mapping": [ {
        "map": "FiveWs.what[x]",
        "identity": "w5"
      }, {
        "map": ".value",
        "identity": "rim"
      } ],
      "type": [ {
        "code": "CodeableConcept"
      } ],
      "binding": {
        "strength": "example",
        "valueSet": "http://hl7.org/fhir/ValueSet/flag-code",
        "extension": [ {
          "url": "http://hl7.org/fhir/StructureDefinition/elementdefinition-bindingName",
          "valueString": "FlagCode"
        } ],
        "description": "Detail codes identifying specific flagged issues."
      },
      "max": "1",
      "id": "Flag.code",
      "comment": "If non-coded, use CodeableConcept.text.  This element should always be included in the narrative.",
      "base": {
        "max": "1",
        "min": 1,
        "path": "Flag.code"
      },
      "isSummary": true
    }, {
      "path": "Flag.code.id",
      "min": 0,
      "definition": "Unique id for the element within a resource (for internal references). This may be any string value that does not contain spaces.",
      "short": "Unique id for inter-element referencing",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      } ],
      "type": [ {
        "code": "http://hl7.org/fhirpath/System.String",
        "extension": [ {
          "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-fhir-type",
          "valueUrl": "string"
        } ]
      } ],
      "representation": [ "xmlAttr" ],
      "max": "1",
      "id": "Flag.code.id",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Element.id"
      }
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "http://hl7.org/fhir/StructureDefinition/Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      }, {
        "key": "ext-1",
        "human": "Must have either extensions or value[x], not both",
        "xpath": "exists(f:extension)!=exists(f:*[starts-with(local-name(.), 'value')])",
        "source": "http://hl7.org/fhir/StructureDefinition/Element",
        "severity": "error",
        "expression": "extension.exists() != value.exists()"
      } ],
      "path": "Flag.code.extension",
      "min": 0,
      "definition": "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.",
      "short": "Additional content defined by implementations",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "N/A",
        "identity": "rim"
      } ],
      "slicing": {
        "rules": "open",
        "description": "Extensions are always sliced by (at least) url",
        "discriminator": [ {
          "path": "url",
          "type": "value"
        } ]
      },
      "type": [ {
        "code": "Extension"
      } ],
      "extension": [ {
        "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-standards-status",
        "valueCode": "normative"
      }, {
        "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-normative-version",
        "valueCode": "4.0.0"
      } ],
      "alias": [ "extensions", "user content" ],
      "max": "*",
      "id": "Flag.code.extension",
      "condition": [ "ele-1" ],
      "comment": "There can be no stigma associated with the use of extensions by any application, project, or standard - regardless of the institution or jurisdiction that uses or defines the extensions.  The use of extensions is what allows the FHIR specification to retain a core level of simplicity for everyone.",
      "base": {
        "max": "*",
        "min": 0,
        "path": "Element.extension"
      }
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "http://hl7.org/fhir/StructureDefinition/Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Flag.code.coding",
      "requirements": "Allows for alternative encodings within a code system, and translations to other code systems.",
      "min": 0,
      "definition": "A reference to a code defined by a terminology system.",
      "short": "Code defined by a terminology system",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "CE/CNE/CWE subset one of the sets of component 1-3 or 4-6",
        "identity": "v2"
      }, {
        "map": "CV",
        "identity": "rim"
      }, {
        "map": "fhir:Coding rdfs:subClassOf dt:CDCoding",
        "identity": "orim"
      }, {
        "map": "C*E.1-8, C*E.10-22",
        "identity": "v2"
      }, {
        "map": "union(., ./translation)",
        "identity": "rim"
      }, {
        "map": "fhir:CodeableConcept.coding rdfs:subPropertyOf dt:CD.coding",
        "identity": "orim"
      } ],
      "slicing": {
        "rules": "open",
        "discriminator": [ {
          "path": "system",
          "type": "value"
        } ]
      },
      "type": [ {
        "code": "Coding"
      } ],
      "extension": [ {
        "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-standards-status",
        "valueCode": "normative"
      }, {
        "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-normative-version",
        "valueCode": "4.0.0"
      } ],
      "max": "*",
      "id": "Flag.code.coding",
      "condition": [ "ele-1" ],
      "comment": "Codes may be defined very casually in enumerations, or code lists, up to very formal definitions such as SNOMED CT - see the HL7 v3 Core Principles for more information.  Ordering of codings is undefined and SHALL NOT be used to infer meaning. Generally, at most only one of the coding values will be labeled as UserSelected = true.",
      "base": {
        "max": "*",
        "min": 0,
        "path": "CodeableConcept.coding"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "http://hl7.org/fhir/StructureDefinition/Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Flag.code.coding",
      "requirements": "Allows for alternative encodings within a code system, and translations to other code systems.",
      "min": 0,
      "definition": "A reference to a code defined by a terminology system.",
      "short": "Code defined by a terminology system",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "CE/CNE/CWE subset one of the sets of component 1-3 or 4-6",
        "identity": "v2"
      }, {
        "map": "CV",
        "identity": "rim"
      }, {
        "map": "fhir:Coding rdfs:subClassOf dt:CDCoding",
        "identity": "orim"
      }, {
        "map": "C*E.1-8, C*E.10-22",
        "identity": "v2"
      }, {
        "map": "union(., ./translation)",
        "identity": "rim"
      }, {
        "map": "fhir:CodeableConcept.coding rdfs:subPropertyOf dt:CD.coding",
        "identity": "orim"
      } ],
      "type": [ {
        "code": "Coding"
      } ],
      "sliceName": "demogAlert",
      "extension": [ {
        "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-standards-status",
        "valueCode": "normative"
      }, {
        "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-normative-version",
        "valueCode": "4.0.0"
      } ],
      "binding": {
        "strength": "required",
        "valueSet": "http://fhir.laniado.org.il/ValueSet/k-demog-alert"
      },
      "max": "1",
      "id": "Flag.code.coding:demogAlert",
      "condition": [ "ele-1" ],
      "comment": "Codes may be defined very casually in enumerations, or code lists, up to very formal definitions such as SNOMED CT - see the HL7 v3 Core Principles for more information.  Ordering of codings is undefined and SHALL NOT be used to infer meaning. Generally, at most only one of the coding values will be labeled as UserSelected = true.",
      "base": {
        "max": "*",
        "min": 0,
        "path": "CodeableConcept.coding"
      },
      "isSummary": true
    }, {
      "path": "Flag.code.coding.id",
      "min": 0,
      "definition": "Unique id for the element within a resource (for internal references). This may be any string value that does not contain spaces.",
      "short": "Unique id for inter-element referencing",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      } ],
      "type": [ {
        "code": "http://hl7.org/fhirpath/System.String",
        "extension": [ {
          "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-fhir-type",
          "valueUrl": "string"
        } ]
      } ],
      "representation": [ "xmlAttr" ],
      "max": "1",
      "id": "Flag.code.coding:demogAlert.id",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Element.id"
      }
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "http://hl7.org/fhir/StructureDefinition/Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      }, {
        "key": "ext-1",
        "human": "Must have either extensions or value[x], not both",
        "xpath": "exists(f:extension)!=exists(f:*[starts-with(local-name(.), 'value')])",
        "source": "http://hl7.org/fhir/StructureDefinition/Element",
        "severity": "error",
        "expression": "extension.exists() != value.exists()"
      } ],
      "path": "Flag.code.coding.extension",
      "min": 0,
      "definition": "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.",
      "short": "Additional content defined by implementations",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "N/A",
        "identity": "rim"
      } ],
      "slicing": {
        "rules": "open",
        "description": "Extensions are always sliced by (at least) url",
        "discriminator": [ {
          "path": "url",
          "type": "value"
        } ]
      },
      "type": [ {
        "code": "Extension"
      } ],
      "extension": [ {
        "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-standards-status",
        "valueCode": "normative"
      }, {
        "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-normative-version",
        "valueCode": "4.0.0"
      } ],
      "alias": [ "extensions", "user content" ],
      "max": "*",
      "id": "Flag.code.coding:demogAlert.extension",
      "condition": [ "ele-1" ],
      "comment": "There can be no stigma associated with the use of extensions by any application, project, or standard - regardless of the institution or jurisdiction that uses or defines the extensions.  The use of extensions is what allows the FHIR specification to retain a core level of simplicity for everyone.",
      "base": {
        "max": "*",
        "min": 0,
        "path": "Element.extension"
      }
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "http://hl7.org/fhir/StructureDefinition/Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Flag.code.coding.system",
      "requirements": "Need to be unambiguous about the source of the definition of the symbol.",
      "min": 1,
      "definition": "The identification of the code system that defines the meaning of the symbol in the code.",
      "short": "Identity of the terminology system",
      "fixedUri": "http://fhir.laniado.org.il/CodeSystem/k-demog-alert",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "C*E.3",
        "identity": "v2"
      }, {
        "map": "./codeSystem",
        "identity": "rim"
      }, {
        "map": "fhir:Coding.system rdfs:subPropertyOf dt:CDCoding.codeSystem",
        "identity": "orim"
      } ],
      "type": [ {
        "code": "uri"
      } ],
      "extension": [ {
        "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-standards-status",
        "valueCode": "normative"
      }, {
        "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-normative-version",
        "valueCode": "4.0.0"
      } ],
      "max": "1",
      "id": "Flag.code.coding:demogAlert.system",
      "condition": [ "ele-1" ],
      "comment": "The URI may be an OID (urn:oid:...) or a UUID (urn:uuid:...).  OIDs and UUIDs SHALL be references to the HL7 OID registry. Otherwise, the URI should come from HL7's list of FHIR defined special URIs or it should reference to some definition that establishes the system clearly and unambiguously.",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Coding.system"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "http://hl7.org/fhir/StructureDefinition/Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Flag.code.coding.version",
      "min": 0,
      "definition": "The version of the code system which was used when choosing this code. Note that a well-maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged.",
      "short": "Version of the system - if relevant",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "C*E.7",
        "identity": "v2"
      }, {
        "map": "./codeSystemVersion",
        "identity": "rim"
      }, {
        "map": "fhir:Coding.version rdfs:subPropertyOf dt:CDCoding.codeSystemVersion",
        "identity": "orim"
      } ],
      "type": [ {
        "code": "string"
      } ],
      "extension": [ {
        "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-standards-status",
        "valueCode": "normative"
      }, {
        "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-normative-version",
        "valueCode": "4.0.0"
      } ],
      "max": "1",
      "id": "Flag.code.coding:demogAlert.version",
      "condition": [ "ele-1" ],
      "comment": "Where the terminology does not clearly define what string should be used to identify code system versions, the recommendation is to use the date (expressed in FHIR date format) on which that version was officially published as the version date.",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Coding.version"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "http://hl7.org/fhir/StructureDefinition/Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Flag.code.coding.code",
      "requirements": "Need to refer to a particular code in the system.",
      "min": 1,
      "definition": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post-coordination).",
      "short": "Symbol in syntax defined by the system",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "C*E.1",
        "identity": "v2"
      }, {
        "map": "./code",
        "identity": "rim"
      }, {
        "map": "fhir:Coding.code rdfs:subPropertyOf dt:CDCoding.code",
        "identity": "orim"
      } ],
      "type": [ {
        "code": "code"
      } ],
      "extension": [ {
        "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-standards-status",
        "valueCode": "normative"
      }, {
        "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-normative-version",
        "valueCode": "4.0.0"
      } ],
      "max": "1",
      "id": "Flag.code.coding:demogAlert.code",
      "condition": [ "ele-1" ],
      "comment": "Note that FHIR strings SHALL NOT exceed 1MB in size",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Coding.code"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "http://hl7.org/fhir/StructureDefinition/Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Flag.code.coding.display",
      "requirements": "Need to be able to carry a human-readable meaning of the code for readers that do not know  the system.",
      "min": 1,
      "definition": "A representation of the meaning of the code in the system, following the rules of the system.",
      "short": "Representation defined by the system",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "C*E.2 - but note this is not well followed",
        "identity": "v2"
      }, {
        "map": "CV.displayName",
        "identity": "rim"
      }, {
        "map": "fhir:Coding.display rdfs:subPropertyOf dt:CDCoding.displayName",
        "identity": "orim"
      } ],
      "type": [ {
        "code": "string"
      } ],
      "extension": [ {
        "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-standards-status",
        "valueCode": "normative"
      }, {
        "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-normative-version",
        "valueCode": "4.0.0"
      }, {
        "url": "http://hl7.org/fhir/StructureDefinition/elementdefinition-translatable",
        "valueBoolean": true
      } ],
      "max": "1",
      "id": "Flag.code.coding:demogAlert.display",
      "condition": [ "ele-1" ],
      "comment": "Note that FHIR strings SHALL NOT exceed 1MB in size",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Coding.display"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "http://hl7.org/fhir/StructureDefinition/Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Flag.code.coding.userSelected",
      "requirements": "This has been identified as a clinical safety criterium - that this exact system/code pair was chosen explicitly, rather than inferred by the system based on some rules or language processing.",
      "min": 0,
      "definition": "Indicates that this coding was chosen by a user directly - e.g. off a pick list of available items (codes or displays).",
      "short": "If this coding was chosen directly by the user",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "Sometimes implied by being first",
        "identity": "v2"
      }, {
        "map": "CD.codingRationale",
        "identity": "rim"
      }, {
        "map": "fhir:Coding.userSelected fhir:mapsTo dt:CDCoding.codingRationale. fhir:Coding.userSelected fhir:hasMap fhir:Coding.userSelected.map. fhir:Coding.userSelected.map a fhir:Map;   fhir:target dt:CDCoding.codingRationale. fhir:Coding.userSelected\\#true a [     fhir:source \"true\";     fhir:target dt:CDCoding.codingRationale\\#O   ]",
        "identity": "orim"
      } ],
      "type": [ {
        "code": "boolean"
      } ],
      "extension": [ {
        "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-standards-status",
        "valueCode": "normative"
      }, {
        "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-normative-version",
        "valueCode": "4.0.0"
      } ],
      "max": "1",
      "id": "Flag.code.coding:demogAlert.userSelected",
      "condition": [ "ele-1" ],
      "comment": "Amongst a set of alternatives, a directly chosen code is the most appropriate starting point for new translations. There is some ambiguity about what exactly 'directly chosen' implies, and trading partner agreement may be needed to clarify the use of this element and its consequences more completely.",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Coding.userSelected"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "http://hl7.org/fhir/StructureDefinition/Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Flag.code.coding",
      "requirements": "Allows for alternative encodings within a code system, and translations to other code systems.",
      "min": 0,
      "definition": "A reference to a code defined by a terminology system.",
      "short": "Code defined by a terminology system",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "CE/CNE/CWE subset one of the sets of component 1-3 or 4-6",
        "identity": "v2"
      }, {
        "map": "CV",
        "identity": "rim"
      }, {
        "map": "fhir:Coding rdfs:subClassOf dt:CDCoding",
        "identity": "orim"
      }, {
        "map": "C*E.1-8, C*E.10-22",
        "identity": "v2"
      }, {
        "map": "union(., ./translation)",
        "identity": "rim"
      }, {
        "map": "fhir:CodeableConcept.coding rdfs:subPropertyOf dt:CD.coding",
        "identity": "orim"
      } ],
      "type": [ {
        "code": "Coding"
      } ],
      "sliceName": "alertCode",
      "extension": [ {
        "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-standards-status",
        "valueCode": "normative"
      }, {
        "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-normative-version",
        "valueCode": "4.0.0"
      } ],
      "binding": {
        "strength": "required",
        "valueSet": "http://fhir.laniado.org.il/ValueSet/demog-alert-code"
      },
      "max": "1",
      "id": "Flag.code.coding:alertCode",
      "condition": [ "ele-1" ],
      "comment": "Codes may be defined very casually in enumerations, or code lists, up to very formal definitions such as SNOMED CT - see the HL7 v3 Core Principles for more information.  Ordering of codings is undefined and SHALL NOT be used to infer meaning. Generally, at most only one of the coding values will be labeled as UserSelected = true.",
      "base": {
        "max": "*",
        "min": 0,
        "path": "CodeableConcept.coding"
      },
      "isSummary": true
    }, {
      "path": "Flag.code.coding.id",
      "min": 0,
      "definition": "Unique id for the element within a resource (for internal references). This may be any string value that does not contain spaces.",
      "short": "Unique id for inter-element referencing",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      } ],
      "type": [ {
        "code": "http://hl7.org/fhirpath/System.String",
        "extension": [ {
          "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-fhir-type",
          "valueUrl": "string"
        } ]
      } ],
      "representation": [ "xmlAttr" ],
      "max": "1",
      "id": "Flag.code.coding:alertCode.id",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Element.id"
      }
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "http://hl7.org/fhir/StructureDefinition/Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      }, {
        "key": "ext-1",
        "human": "Must have either extensions or value[x], not both",
        "xpath": "exists(f:extension)!=exists(f:*[starts-with(local-name(.), 'value')])",
        "source": "http://hl7.org/fhir/StructureDefinition/Element",
        "severity": "error",
        "expression": "extension.exists() != value.exists()"
      } ],
      "path": "Flag.code.coding.extension",
      "min": 0,
      "definition": "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.",
      "short": "Additional content defined by implementations",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "N/A",
        "identity": "rim"
      } ],
      "slicing": {
        "rules": "open",
        "description": "Extensions are always sliced by (at least) url",
        "discriminator": [ {
          "path": "url",
          "type": "value"
        } ]
      },
      "type": [ {
        "code": "Extension"
      } ],
      "extension": [ {
        "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-standards-status",
        "valueCode": "normative"
      }, {
        "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-normative-version",
        "valueCode": "4.0.0"
      } ],
      "alias": [ "extensions", "user content" ],
      "max": "*",
      "id": "Flag.code.coding:alertCode.extension",
      "condition": [ "ele-1" ],
      "comment": "There can be no stigma associated with the use of extensions by any application, project, or standard - regardless of the institution or jurisdiction that uses or defines the extensions.  The use of extensions is what allows the FHIR specification to retain a core level of simplicity for everyone.",
      "base": {
        "max": "*",
        "min": 0,
        "path": "Element.extension"
      }
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "http://hl7.org/fhir/StructureDefinition/Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Flag.code.coding.system",
      "requirements": "Need to be unambiguous about the source of the definition of the symbol.",
      "min": 1,
      "definition": "The identification of the code system that defines the meaning of the symbol in the code.",
      "short": "Identity of the terminology system",
      "fixedUri": "http://snomed.info/sct",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "C*E.3",
        "identity": "v2"
      }, {
        "map": "./codeSystem",
        "identity": "rim"
      }, {
        "map": "fhir:Coding.system rdfs:subPropertyOf dt:CDCoding.codeSystem",
        "identity": "orim"
      } ],
      "type": [ {
        "code": "uri"
      } ],
      "extension": [ {
        "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-standards-status",
        "valueCode": "normative"
      }, {
        "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-normative-version",
        "valueCode": "4.0.0"
      } ],
      "max": "1",
      "id": "Flag.code.coding:alertCode.system",
      "condition": [ "ele-1" ],
      "comment": "The URI may be an OID (urn:oid:...) or a UUID (urn:uuid:...).  OIDs and UUIDs SHALL be references to the HL7 OID registry. Otherwise, the URI should come from HL7's list of FHIR defined special URIs or it should reference to some definition that establishes the system clearly and unambiguously.",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Coding.system"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "http://hl7.org/fhir/StructureDefinition/Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Flag.code.coding.version",
      "min": 0,
      "definition": "The version of the code system which was used when choosing this code. Note that a well-maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged.",
      "short": "Version of the system - if relevant",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "C*E.7",
        "identity": "v2"
      }, {
        "map": "./codeSystemVersion",
        "identity": "rim"
      }, {
        "map": "fhir:Coding.version rdfs:subPropertyOf dt:CDCoding.codeSystemVersion",
        "identity": "orim"
      } ],
      "type": [ {
        "code": "string"
      } ],
      "extension": [ {
        "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-standards-status",
        "valueCode": "normative"
      }, {
        "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-normative-version",
        "valueCode": "4.0.0"
      } ],
      "max": "1",
      "id": "Flag.code.coding:alertCode.version",
      "condition": [ "ele-1" ],
      "comment": "Where the terminology does not clearly define what string should be used to identify code system versions, the recommendation is to use the date (expressed in FHIR date format) on which that version was officially published as the version date.",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Coding.version"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "http://hl7.org/fhir/StructureDefinition/Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Flag.code.coding.code",
      "requirements": "Need to refer to a particular code in the system.",
      "min": 1,
      "definition": "A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post-coordination).",
      "short": "Symbol in syntax defined by the system",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "C*E.1",
        "identity": "v2"
      }, {
        "map": "./code",
        "identity": "rim"
      }, {
        "map": "fhir:Coding.code rdfs:subPropertyOf dt:CDCoding.code",
        "identity": "orim"
      } ],
      "type": [ {
        "code": "code"
      } ],
      "extension": [ {
        "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-standards-status",
        "valueCode": "normative"
      }, {
        "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-normative-version",
        "valueCode": "4.0.0"
      } ],
      "max": "1",
      "id": "Flag.code.coding:alertCode.code",
      "condition": [ "ele-1" ],
      "comment": "Note that FHIR strings SHALL NOT exceed 1MB in size",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Coding.code"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "http://hl7.org/fhir/StructureDefinition/Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Flag.code.coding.display",
      "requirements": "Need to be able to carry a human-readable meaning of the code for readers that do not know  the system.",
      "min": 0,
      "definition": "A representation of the meaning of the code in the system, following the rules of the system.",
      "short": "Representation defined by the system",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "C*E.2 - but note this is not well followed",
        "identity": "v2"
      }, {
        "map": "CV.displayName",
        "identity": "rim"
      }, {
        "map": "fhir:Coding.display rdfs:subPropertyOf dt:CDCoding.displayName",
        "identity": "orim"
      } ],
      "type": [ {
        "code": "string"
      } ],
      "extension": [ {
        "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-standards-status",
        "valueCode": "normative"
      }, {
        "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-normative-version",
        "valueCode": "4.0.0"
      }, {
        "url": "http://hl7.org/fhir/StructureDefinition/elementdefinition-translatable",
        "valueBoolean": true
      } ],
      "max": "1",
      "id": "Flag.code.coding:alertCode.display",
      "condition": [ "ele-1" ],
      "comment": "Note that FHIR strings SHALL NOT exceed 1MB in size",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Coding.display"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "http://hl7.org/fhir/StructureDefinition/Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Flag.code.coding.userSelected",
      "requirements": "This has been identified as a clinical safety criterium - that this exact system/code pair was chosen explicitly, rather than inferred by the system based on some rules or language processing.",
      "min": 0,
      "definition": "Indicates that this coding was chosen by a user directly - e.g. off a pick list of available items (codes or displays).",
      "short": "If this coding was chosen directly by the user",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "Sometimes implied by being first",
        "identity": "v2"
      }, {
        "map": "CD.codingRationale",
        "identity": "rim"
      }, {
        "map": "fhir:Coding.userSelected fhir:mapsTo dt:CDCoding.codingRationale. fhir:Coding.userSelected fhir:hasMap fhir:Coding.userSelected.map. fhir:Coding.userSelected.map a fhir:Map;   fhir:target dt:CDCoding.codingRationale. fhir:Coding.userSelected\\#true a [     fhir:source \"true\";     fhir:target dt:CDCoding.codingRationale\\#O   ]",
        "identity": "orim"
      } ],
      "type": [ {
        "code": "boolean"
      } ],
      "extension": [ {
        "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-standards-status",
        "valueCode": "normative"
      }, {
        "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-normative-version",
        "valueCode": "4.0.0"
      } ],
      "max": "1",
      "id": "Flag.code.coding:alertCode.userSelected",
      "condition": [ "ele-1" ],
      "comment": "Amongst a set of alternatives, a directly chosen code is the most appropriate starting point for new translations. There is some ambiguity about what exactly 'directly chosen' implies, and trading partner agreement may be needed to clarify the use of this element and its consequences more completely.",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Coding.userSelected"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "http://hl7.org/fhir/StructureDefinition/Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Flag.code.text",
      "requirements": "The codes from the terminologies do not always capture the correct meaning with all the nuances of the human using them, or sometimes there is no appropriate code at all. In these cases, the text is used to capture the full meaning of the source.",
      "min": 0,
      "definition": "A human language representation of the concept as seen/selected/uttered by the user who entered the data and/or which represents the intended meaning of the user.",
      "short": "Plain text representation of the concept",
      "mapping": [ {
        "map": "n/a",
        "identity": "rim"
      }, {
        "map": "C*E.9. But note many systems use C*E.2 for this",
        "identity": "v2"
      }, {
        "map": "./originalText[mediaType/code=\"text/plain\"]/data",
        "identity": "rim"
      }, {
        "map": "fhir:CodeableConcept.text rdfs:subPropertyOf dt:CD.originalText",
        "identity": "orim"
      } ],
      "type": [ {
        "code": "string"
      } ],
      "extension": [ {
        "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-standards-status",
        "valueCode": "normative"
      }, {
        "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-normative-version",
        "valueCode": "4.0.0"
      }, {
        "url": "http://hl7.org/fhir/StructureDefinition/elementdefinition-translatable",
        "valueBoolean": true
      } ],
      "max": "1",
      "id": "Flag.code.text",
      "condition": [ "ele-1" ],
      "comment": "Very often the text is the same as a displayName of one of the codings.",
      "base": {
        "max": "1",
        "min": 0,
        "path": "CodeableConcept.text"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "http://hl7.org/fhir/StructureDefinition/Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Flag.subject",
      "min": 1,
      "definition": "The patient, location, group, organization, or practitioner etc. this is about record this flag is associated with.",
      "isModifier": false,
      "short": "Who/What is flag about?",
      "mapping": [ {
        "map": "FiveWs.subject[x]",
        "identity": "w5"
      }, {
        "map": ".participation[typeCode=SBJ].role[classCode=PAT | LOCE | ASSIGNED]",
        "identity": "rim"
      }, {
        "map": "FiveWs.subject",
        "identity": "w5"
      } ],
      "type": [ {
        "code": "Reference",
        "targetProfile": [ "http://fhir.laniado.org.il/StructureDefinition/laniado-patient" ]
      } ],
      "max": "1",
      "id": "Flag.subject",
      "base": {
        "max": "1",
        "min": 1,
        "path": "Flag.subject"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "http://hl7.org/fhir/StructureDefinition/Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Flag.period",
      "min": 0,
      "definition": "The period of time from the activation of the flag to inactivation of the flag. If the flag is active, the end of the period should be unspecified.",
      "isModifier": false,
      "short": "Time period when flag is active",
      "mapping": [ {
        "map": "FiveWs.context",
        "identity": "w5"
      } ],
      "type": [ {
        "code": "Period"
      } ],
      "max": "1",
      "id": "Flag.period",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Flag.period"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "http://hl7.org/fhir/StructureDefinition/Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Flag.encounter",
      "min": 0,
      "definition": "This alert is only relevant during the encounter.",
      "isModifier": false,
      "short": "Alert relevant during encounter",
      "mapping": [ {
        "map": "FiveWs.context",
        "identity": "w5"
      } ],
      "type": [ {
        "code": "Reference",
        "targetProfile": [ "http://fhir.health.gov.il/StructureDefinition/il-core-encounter" ]
      } ],
      "max": "1",
      "id": "Flag.encounter",
      "comment": "If both Flag.encounter and Flag.period are valued, then Flag.period.start shall not be before Encounter.period.start and Flag.period.end shall not be after Encounter.period.end.",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Flag.encounter"
      },
      "isSummary": true
    }, {
      "constraint": [ {
        "key": "ele-1",
        "human": "All FHIR elements must have a @value or children",
        "xpath": "@value|f:*|h:div",
        "source": "http://hl7.org/fhir/StructureDefinition/Element",
        "severity": "error",
        "expression": "hasValue() or (children().count() > id.count())"
      } ],
      "path": "Flag.author",
      "min": 0,
      "definition": "The person, organization or device that created the flag.",
      "isModifier": false,
      "short": "Flag creator",
      "mapping": [ {
        "map": "FiveWs.author",
        "identity": "w5"
      }, {
        "map": ".participation[typeCode=AUT].role",
        "identity": "rim"
      } ],
      "type": [ {
        "code": "Reference",
        "targetProfile": [ "http://fhir.laniado.org.il/StructureDefinition/laniado-practitioner" ]
      } ],
      "max": "1",
      "id": "Flag.author",
      "base": {
        "max": "1",
        "min": 0,
        "path": "Flag.author"
      },
      "isSummary": true
    } ]
  },
  "status": "draft",
  "id": "1ae62e52-cef2-4401-9a6c-257ef07e169d",
  "kind": "resource",
  "url": "http://fhir.laniado.org.il/StructureDefinition/laniado-flag",
  "version": null,
  "differential": {
    "element": [ {
      "id": "Flag.extension",
      "path": "Flag.extension",
      "slicing": {
        "rules": "open",
        "ordered": false,
        "discriminator": [ {
          "path": "url",
          "type": "value"
        } ]
      }
    }, {
      "id": "Flag.extension:note",
      "max": "2",
      "min": 0,
      "path": "Flag.extension",
      "type": [ {
        "code": "Extension",
        "profile": [ "http://fhir.laniado.org.il/StructureDefinition/ext-flag-note" ]
      } ],
      "sliceName": "note"
    }, {
      "id": "Flag.identifier",
      "path": "Flag.identifier",
      "slicing": {
        "rules": "open",
        "discriminator": [ {
          "path": "system",
          "type": "value"
        } ]
      }
    }, {
      "id": "Flag.identifier.system",
      "min": 1,
      "path": "Flag.identifier.system"
    }, {
      "id": "Flag.identifier.value",
      "min": 1,
      "path": "Flag.identifier.value",
      "short": "The value that is unique within the system."
    }, {
      "id": "Flag.identifier:demogAlert",
      "max": "1",
      "min": 0,
      "path": "Flag.identifier",
      "sliceName": "demogAlert"
    }, {
      "id": "Flag.identifier:demogAlert.system",
      "path": "Flag.identifier.system",
      "fixedUri": "http://fhir.laniado.org.il/Identifier/demog-alert"
    }, {
      "id": "Flag.category",
      "min": 1,
      "path": "Flag.category"
    }, {
      "id": "Flag.category.coding",
      "path": "Flag.category.coding",
      "slicing": {
        "rules": "open",
        "discriminator": [ {
          "path": "code",
          "type": "value"
        } ]
      }
    }, {
      "id": "Flag.category.coding:alert",
      "max": "1",
      "min": 0,
      "path": "Flag.category.coding",
      "sliceName": "alert"
    }, {
      "id": "Flag.category.coding:alert.system",
      "path": "Flag.category.coding.system",
      "fixedUri": "http://loinc.org"
    }, {
      "id": "Flag.category.coding:alert.code",
      "min": 1,
      "path": "Flag.category.coding.code",
      "fixedCode": "74018-3"
    }, {
      "id": "Flag.category.coding:alert.display",
      "path": "Flag.category.coding.display",
      "fixedString": "Alert category"
    }, {
      "id": "Flag.code.coding",
      "path": "Flag.code.coding",
      "slicing": {
        "rules": "open",
        "discriminator": [ {
          "path": "system",
          "type": "value"
        } ]
      }
    }, {
      "id": "Flag.code.coding:demogAlert",
      "max": "1",
      "min": 0,
      "path": "Flag.code.coding",
      "binding": {
        "strength": "required",
        "valueSet": "http://fhir.laniado.org.il/ValueSet/k-demog-alert"
      },
      "sliceName": "demogAlert"
    }, {
      "id": "Flag.code.coding:demogAlert.system",
      "min": 1,
      "path": "Flag.code.coding.system",
      "fixedUri": "http://fhir.laniado.org.il/CodeSystem/k-demog-alert"
    }, {
      "id": "Flag.code.coding:demogAlert.code",
      "min": 1,
      "path": "Flag.code.coding.code"
    }, {
      "id": "Flag.code.coding:demogAlert.display",
      "min": 1,
      "path": "Flag.code.coding.display"
    }, {
      "id": "Flag.code.coding:alertCode",
      "max": "1",
      "min": 0,
      "path": "Flag.code.coding",
      "binding": {
        "strength": "required",
        "valueSet": "http://fhir.laniado.org.il/ValueSet/demog-alert-code"
      },
      "sliceName": "alertCode"
    }, {
      "id": "Flag.code.coding:alertCode.system",
      "min": 1,
      "path": "Flag.code.coding.system",
      "fixedUri": "http://snomed.info/sct"
    }, {
      "id": "Flag.code.coding:alertCode.code",
      "min": 1,
      "path": "Flag.code.coding.code"
    }, {
      "id": "Flag.subject",
      "path": "Flag.subject",
      "type": [ {
        "code": "Reference",
        "targetProfile": [ "http://fhir.laniado.org.il/StructureDefinition/laniado-patient" ]
      } ]
    }, {
      "id": "Flag.author",
      "path": "Flag.author",
      "type": [ {
        "code": "Reference",
        "targetProfile": [ "http://fhir.laniado.org.il/StructureDefinition/laniado-practitioner" ]
      } ]
    } ]
  },
  "baseDefinition": "http://fhir.health.gov.il/StructureDefinition/il-core-flag"
}