FHIR © HL7.org  |  Server Home  |  XIG Home  |  XIG Stats  |  Server Source  |  FHIR  

FHIR IG Statistics: StructureMap/AllergyIntolerance2to3

Packagehl7.fhir.uv.xver
Resource TypeStructureMap
IdAllergyIntolerance2to3
FHIR VersionR5
Sourcehttp://hl7.org/fhir/extensions/https://build.fhir.org/ig/HL7/fhir-cross-version/StructureMap-AllergyIntolerance2to3.html
URLhttp://hl7.org/fhir/StructureMap/AllergyIntolerance2to3
Version0.1.0
Statusactive
Date2024-02-22T03:16:50+00:00
NameAllergyIntolerance2to3
TitleAllergyIntolerance Transforms: R2 to R3
Realmuv
Authorityhl7
DescriptionAllergyIntoleranceTransformsR2toR3

Resources that use this resource

No resources found


Resources that this resource uses

No resources found


Narrative

Note: links and images are rebased to the (stated) source

/// url = 'http://hl7.org/fhir/StructureMap/AllergyIntolerance2to3'
/// name = 'AllergyIntolerance2to3'
/// title = 'AllergyIntolerance Transforms: R2 to R3'
/// status = 'active'

uses "http://hl7.org/fhir/1.0/AllergyIntolerance" alias AllergyIntoleranceR2 as source
uses "http://hl7.org/fhir/3.0/AllergyIntolerance" alias AllergyIntolerance as target

imports "http://hl7.org/fhir/StructureMap/*to3"

group AllergyIntolerance(source src : AllergyIntoleranceR2, target tgt : AllergyIntolerance) extends DomainResource <<type+>> {
  src.identifier -> tgt.identifier "AllergyIntolerance-identifier";
  src.onset -> tgt.onset "AllergyIntolerance-onset";
  src.recordedDate -> tgt.assertedDate "AllergyIntolerance-recordedDate";
  src.recorder -> tgt.recorder "AllergyIntolerance-recorder";
  src.patient -> tgt.patient "AllergyIntolerance-patient";
  src.reporter -> tgt.asserter "AllergyIntolerance-reporter";
  src.substance -> tgt.code "AllergyIntolerance-substance";
  src.status as v where ($this != 'refuted') and ($this != 'entered-in-error') -> tgt.clinicalStatus = translate(v, 'http://hl7.org/fhir/ConceptMap/AllergyIntolerance.status-R2toR3', 'code') "AllergyIntolerance-status-clinical";
  src.status as v where ($this != 'active') and ($this != 'resolved') -> tgt.verificationStatus = translate(v, 'http://hl7.org/fhir/ConceptMap/AllergyIntolerance.status-R2toR3', 'code') "AllergyIntolerance-Status-verification";
  src.criticality as v -> tgt.criticality = translate(v, 'http://hl7.org/fhir/ConceptMap/AllergyIntolerance.criticality-R2toR3', 'code') "AllergyIntolerance-criticality";
  src.type -> tgt.type "AllergyIntolerance-type";
  src.category -> tgt.category "AllergyIntolerance-category";
  src.lastOccurence -> tgt.lastOccurrence "AllergyIntolerance-lastOccurrence";
  src.note -> tgt.note "AllergyIntolerance-note";
  src.reaction as vs0 -> tgt.reaction as vt0 then algReaction(vs0, vt0) "AllergyIntolerance-reaction";
}

group algReaction(source src, target tgt) extends BackboneElement {
  src.substance -> tgt.substance "reaction-substance";
  src.certainty as v ->  tgt.extension as t,  t.url = 'http://hl7.org/fhir/AllergyIntolerance-r2-certainty',  t.value = v "reaction-certainty";
  src.manifestation -> tgt.manifestation "reaction-manifestation";
  src.description -> tgt.description "reaction-description";
  src.onset -> tgt.onset "reaction-onset";
  src.severity -> tgt.severity "reaction-severity";
  src.exposureRoute -> tgt.exposureRoute "reaction-exposureRoute";
  src.note -> tgt.note "reaction-note";
}


Source

{
  "resourceType": "StructureMap",
  "id": "AllergyIntolerance2to3",
  "text": {
    "status": "generated",
    "div": "<!-- snip (see above) -->"
  },
  "extension": [
    {
      "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-wg",
      "valueCode": "fhir"
    },
    {
      "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-fmm",
      "valueInteger": 1,
      "_valueInteger": {
        "extension": [
          {
            "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-conformance-derivedFrom",
            "valueCanonical": "http://hl7.org/fhir/extensions/ImplementationGuide/hl7.fhir.uv.xver"
          }
        ]
      }
    },
    {
      "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-standards-status",
      "valueCode": "draft",
      "_valueCode": {
        "extension": [
          {
            "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-conformance-derivedFrom",
            "valueCanonical": "http://hl7.org/fhir/extensions/ImplementationGuide/hl7.fhir.uv.xver"
          }
        ]
      }
    }
  ],
  "url": "http://hl7.org/fhir/StructureMap/AllergyIntolerance2to3",
  "version": "0.1.0",
  "name": "AllergyIntolerance2to3",
  "title": "AllergyIntolerance Transforms: R2 to R3",
  "status": "active",
  "date": "2024-02-22T03:16:50+00:00",
  "publisher": "HL7 International / FHIR Infrastructure",
  "contact": [
    {
      "telecom": [
        {
          "system": "url",
          "value": "http://www.hl7.org/Special/committees/fiwg"
        }
      ]
    }
  ],
  "description": "AllergyIntoleranceTransformsR2toR3",
  "jurisdiction": [
    {
      "coding": [
        {
          "system": "http://unstats.un.org/unsd/methods/m49/m49.htm",
          "code": "001"
        }
      ]
    }
  ],
  "structure": [
    {
      "url": "http://hl7.org/fhir/1.0/AllergyIntolerance",
      "mode": "source",
      "alias": "AllergyIntoleranceR2"
    },
    {
      "url": "http://hl7.org/fhir/3.0/AllergyIntolerance",
      "mode": "target",
      "alias": "AllergyIntolerance"
    }
  ],
  "import": [
    "http://hl7.org/fhir/StructureMap/*to3"
  ],
  "group": [
    {
      "name": "AllergyIntolerance",
      "extends": "DomainResource",
      "typeMode": "type-and-types",
      "input": [
        {
          "name": "src",
          "type": "AllergyIntoleranceR2",
          "mode": "source"
        },
        {
          "name": "tgt",
          "type": "AllergyIntolerance",
          "mode": "target"
        }
      ],
      "rule": [
        {
          "name": "AllergyIntolerance-identifier",
          "source": [
            {
              "context": "src",
              "element": "identifier",
              "variable": "vvv"
            }
          ],
          "target": [
            {
              "context": "tgt",
              "element": "identifier",
              "variable": "vvv",
              "transform": "create"
            }
          ],
          "dependent": [
            {
              "name": "DefaultMappingGroupAnonymousAlias",
              "parameter": [
                {
                  "valueId": "vvv"
                },
                {
                  "valueId": "vvv"
                }
              ]
            }
          ]
        },
        {
          "name": "AllergyIntolerance-onset",
          "source": [
            {
              "context": "src",
              "element": "onset",
              "variable": "vvv"
            }
          ],
          "target": [
            {
              "context": "tgt",
              "element": "onset",
              "variable": "vvv",
              "transform": "create"
            }
          ],
          "dependent": [
            {
              "name": "DefaultMappingGroupAnonymousAlias",
              "parameter": [
                {
                  "valueId": "vvv"
                },
                {
                  "valueId": "vvv"
                }
              ]
            }
          ]
        },
        {
          "name": "AllergyIntolerance-recordedDate",
          "source": [
            {
              "context": "src",
              "element": "recordedDate",
              "variable": "vvv"
            }
          ],
          "target": [
            {
              "context": "tgt",
              "element": "assertedDate",
              "variable": "vvv",
              "transform": "create"
            }
          ],
          "dependent": [
            {
              "name": "DefaultMappingGroupAnonymousAlias",
              "parameter": [
                {
                  "valueId": "vvv"
                },
                {
                  "valueId": "vvv"
                }
              ]
            }
          ]
        },
        {
          "name": "AllergyIntolerance-recorder",
          "source": [
            {
              "context": "src",
              "element": "recorder",
              "variable": "vvv"
            }
          ],
          "target": [
            {
              "context": "tgt",
              "element": "recorder",
              "variable": "vvv",
              "transform": "create"
            }
          ],
          "dependent": [
            {
              "name": "DefaultMappingGroupAnonymousAlias",
              "parameter": [
                {
                  "valueId": "vvv"
                },
                {
                  "valueId": "vvv"
                }
              ]
            }
          ]
        },
        {
          "name": "AllergyIntolerance-patient",
          "source": [
            {
              "context": "src",
              "element": "patient",
              "variable": "vvv"
            }
          ],
          "target": [
            {
              "context": "tgt",
              "element": "patient",
              "variable": "vvv",
              "transform": "create"
            }
          ],
          "dependent": [
            {
              "name": "DefaultMappingGroupAnonymousAlias",
              "parameter": [
                {
                  "valueId": "vvv"
                },
                {
                  "valueId": "vvv"
                }
              ]
            }
          ]
        },
        {
          "name": "AllergyIntolerance-reporter",
          "source": [
            {
              "context": "src",
              "element": "reporter",
              "variable": "vvv"
            }
          ],
          "target": [
            {
              "context": "tgt",
              "element": "asserter",
              "variable": "vvv",
              "transform": "create"
            }
          ],
          "dependent": [
            {
              "name": "DefaultMappingGroupAnonymousAlias",
              "parameter": [
                {
                  "valueId": "vvv"
                },
                {
                  "valueId": "vvv"
                }
              ]
            }
          ]
        },
        {
          "name": "AllergyIntolerance-substance",
          "source": [
            {
              "context": "src",
              "element": "substance",
              "variable": "vvv"
            }
          ],
          "target": [
            {
              "context": "tgt",
              "element": "code",
              "variable": "vvv",
              "transform": "create"
            }
          ],
          "dependent": [
            {
              "name": "DefaultMappingGroupAnonymousAlias",
              "parameter": [
                {
                  "valueId": "vvv"
                },
                {
                  "valueId": "vvv"
                }
              ]
            }
          ]
        },
        {
          "name": "AllergyIntolerance-status-clinical",
          "source": [
            {
              "context": "src",
              "element": "status",
              "variable": "v",
              "condition": "($this != 'refuted') and ($this != 'entered-in-error')"
            }
          ],
          "target": [
            {
              "context": "tgt",
              "element": "clinicalStatus",
              "transform": "translate",
              "parameter": [
                {
                  "valueId": "v"
                },
                {
                  "valueString": "http://hl7.org/fhir/ConceptMap/AllergyIntolerance.status-R2toR3"
                },
                {
                  "valueString": "code"
                }
              ]
            }
          ]
        },
        {
          "name": "AllergyIntolerance-Status-verification",
          "source": [
            {
              "context": "src",
              "element": "status",
              "variable": "v",
              "condition": "($this != 'active') and ($this != 'resolved')"
            }
          ],
          "target": [
            {
              "context": "tgt",
              "element": "verificationStatus",
              "transform": "translate",
              "parameter": [
                {
                  "valueId": "v"
                },
                {
                  "valueString": "http://hl7.org/fhir/ConceptMap/AllergyIntolerance.status-R2toR3"
                },
                {
                  "valueString": "code"
                }
              ]
            }
          ]
        },
        {
          "name": "AllergyIntolerance-criticality",
          "source": [
            {
              "context": "src",
              "element": "criticality",
              "variable": "v"
            }
          ],
          "target": [
            {
              "context": "tgt",
              "element": "criticality",
              "transform": "translate",
              "parameter": [
                {
                  "valueId": "v"
                },
                {
                  "valueString": "http://hl7.org/fhir/ConceptMap/AllergyIntolerance.criticality-R2toR3"
                },
                {
                  "valueString": "code"
                }
              ]
            }
          ]
        },
        {
          "name": "AllergyIntolerance-type",
          "source": [
            {
              "context": "src",
              "element": "type",
              "variable": "vvv"
            }
          ],
          "target": [
            {
              "context": "tgt",
              "element": "type",
              "variable": "vvv",
              "transform": "create"
            }
          ],
          "dependent": [
            {
              "name": "DefaultMappingGroupAnonymousAlias",
              "parameter": [
                {
                  "valueId": "vvv"
                },
                {
                  "valueId": "vvv"
                }
              ]
            }
          ]
        },
        {
          "name": "AllergyIntolerance-category",
          "source": [
            {
              "context": "src",
              "element": "category",
              "variable": "vvv"
            }
          ],
          "target": [
            {
              "context": "tgt",
              "element": "category",
              "variable": "vvv",
              "transform": "create"
            }
          ],
          "dependent": [
            {
              "name": "DefaultMappingGroupAnonymousAlias",
              "parameter": [
                {
                  "valueId": "vvv"
                },
                {
                  "valueId": "vvv"
                }
              ]
            }
          ]
        },
        {
          "name": "AllergyIntolerance-lastOccurrence",
          "source": [
            {
              "context": "src",
              "element": "lastOccurence",
              "variable": "vvv"
            }
          ],
          "target": [
            {
              "context": "tgt",
              "element": "lastOccurrence",
              "variable": "vvv",
              "transform": "create"
            }
          ],
          "dependent": [
            {
              "name": "DefaultMappingGroupAnonymousAlias",
              "parameter": [
                {
                  "valueId": "vvv"
                },
                {
                  "valueId": "vvv"
                }
              ]
            }
          ]
        },
        {
          "name": "AllergyIntolerance-note",
          "source": [
            {
              "context": "src",
              "element": "note",
              "variable": "vvv"
            }
          ],
          "target": [
            {
              "context": "tgt",
              "element": "note",
              "variable": "vvv",
              "transform": "create"
            }
          ],
          "dependent": [
            {
              "name": "DefaultMappingGroupAnonymousAlias",
              "parameter": [
                {
                  "valueId": "vvv"
                },
                {
                  "valueId": "vvv"
                }
              ]
            }
          ]
        },
        {
          "name": "AllergyIntolerance-reaction",
          "source": [
            {
              "context": "src",
              "element": "reaction",
              "variable": "vs0"
            }
          ],
          "target": [
            {
              "context": "tgt",
              "element": "reaction",
              "variable": "vt0"
            }
          ],
          "dependent": [
            {
              "name": "algReaction",
              "parameter": [
                {
                  "valueId": "vs0"
                },
                {
                  "valueId": "vt0"
                }
              ]
            }
          ]
        }
      ]
    },
    {
      "name": "algReaction",
      "extends": "BackboneElement",
      "input": [
        {
          "name": "src",
          "mode": "source"
        },
        {
          "name": "tgt",
          "mode": "target"
        }
      ],
      "rule": [
        {
          "name": "reaction-substance",
          "source": [
            {
              "context": "src",
              "element": "substance",
              "variable": "vvv"
            }
          ],
          "target": [
            {
              "context": "tgt",
              "element": "substance",
              "variable": "vvv",
              "transform": "create"
            }
          ],
          "dependent": [
            {
              "name": "DefaultMappingGroupAnonymousAlias",
              "parameter": [
                {
                  "valueId": "vvv"
                },
                {
                  "valueId": "vvv"
                }
              ]
            }
          ]
        },
        {
          "name": "reaction-certainty",
          "source": [
            {
              "context": "src",
              "element": "certainty",
              "variable": "v"
            }
          ],
          "target": [
            {
              "context": "tgt",
              "element": "extension",
              "variable": "t"
            },
            {
              "context": "t",
              "element": "url",
              "transform": "copy",
              "parameter": [
                {
                  "valueString": "http://hl7.org/fhir/AllergyIntolerance-r2-certainty"
                }
              ]
            },
            {
              "context": "t",
              "element": "value",
              "transform": "copy",
              "parameter": [
                {
                  "valueId": "v"
                }
              ]
            }
          ]
        },
        {
          "name": "reaction-manifestation",
          "source": [
            {
              "context": "src",
              "element": "manifestation",
              "variable": "vvv"
            }
          ],
          "target": [
            {
              "context": "tgt",
              "element": "manifestation",
              "variable": "vvv",
              "transform": "create"
            }
          ],
          "dependent": [
            {
              "name": "DefaultMappingGroupAnonymousAlias",
              "parameter": [
                {
                  "valueId": "vvv"
                },
                {
                  "valueId": "vvv"
                }
              ]
            }
          ]
        },
        {
          "name": "reaction-description",
          "source": [
            {
              "context": "src",
              "element": "description",
              "variable": "vvv"
            }
          ],
          "target": [
            {
              "context": "tgt",
              "element": "description",
              "variable": "vvv",
              "transform": "create"
            }
          ],
          "dependent": [
            {
              "name": "DefaultMappingGroupAnonymousAlias",
              "parameter": [
                {
                  "valueId": "vvv"
                },
                {
                  "valueId": "vvv"
                }
              ]
            }
          ]
        },
        {
          "name": "reaction-onset",
          "source": [
            {
              "context": "src",
              "element": "onset",
              "variable": "vvv"
            }
          ],
          "target": [
            {
              "context": "tgt",
              "element": "onset",
              "variable": "vvv",
              "transform": "create"
            }
          ],
          "dependent": [
            {
              "name": "DefaultMappingGroupAnonymousAlias",
              "parameter": [
                {
                  "valueId": "vvv"
                },
                {
                  "valueId": "vvv"
                }
              ]
            }
          ]
        },
        {
          "name": "reaction-severity",
          "source": [
            {
              "context": "src",
              "element": "severity",
              "variable": "vvv"
            }
          ],
          "target": [
            {
              "context": "tgt",
              "element": "severity",
              "variable": "vvv",
              "transform": "create"
            }
          ],
          "dependent": [
            {
              "name": "DefaultMappingGroupAnonymousAlias",
              "parameter": [
                {
                  "valueId": "vvv"
                },
                {
                  "valueId": "vvv"
                }
              ]
            }
          ]
        },
        {
          "name": "reaction-exposureRoute",
          "source": [
            {
              "context": "src",
              "element": "exposureRoute",
              "variable": "vvv"
            }
          ],
          "target": [
            {
              "context": "tgt",
              "element": "exposureRoute",
              "variable": "vvv",
              "transform": "create"
            }
          ],
          "dependent": [
            {
              "name": "DefaultMappingGroupAnonymousAlias",
              "parameter": [
                {
                  "valueId": "vvv"
                },
                {
                  "valueId": "vvv"
                }
              ]
            }
          ]
        },
        {
          "name": "reaction-note",
          "source": [
            {
              "context": "src",
              "element": "note",
              "variable": "vvv"
            }
          ],
          "target": [
            {
              "context": "tgt",
              "element": "note",
              "variable": "vvv",
              "transform": "create"
            }
          ],
          "dependent": [
            {
              "name": "DefaultMappingGroupAnonymousAlias",
              "parameter": [
                {
                  "valueId": "vvv"
                },
                {
                  "valueId": "vvv"
                }
              ]
            }
          ]
        }
      ]
    }
  ]
}