CDC National Healthcare Safety Network (NHSN) Digital Quality Measures (dQM) Content Package IG
1.0.0 - Release 1

CDC National Healthcare Safety Network (NHSN) Digital Quality Measures (dQM) Content Package IG - Downloaded Version 1.0.0 See the Directory of published versions

## : Shared Resource Creation - TTL Representation

Page standards status: Trial-use | Maturity Level: 1

Raw ttl | Download

    @prefix fhir: <http://hl7.org/fhir/> .
    @prefix owl: <http://www.w3.org/2002/07/owl#> .
    @prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .
    @prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> .
    @prefix xsd: <http://www.w3.org/2001/XMLSchema#> .

    # - resource -------------------------------------------------------------------

     a fhir:Library ;
      fhir:nodeRole fhir:treeRoot ;
      fhir:id [ fhir:v "SharedResourceCreation"] ; #
      fhir:text [
    fhir:status [ fhir:v "extensions" ] ;
    fhir:div "<div xmlns=\"http://www.w3.org/1999/xhtml\">\n<div>\n    <table class=\"grid dict\">\n        \n        \n\n        \n        \n        <tr>\n            <th scope=\"row\"><b>Id: </b></th>\n            <td style=\"padding-left: 4px;\">SharedResourceCreation</td>\n        </tr>\n        \n\n        \n        \n        <tr>\n            <th scope=\"row\"><b>Version: </b></th>\n            <td style=\"padding-left: 4px;\">1.0.0</td>\n        </tr>\n        \n\n        \n        <tr>\n            <th scope=\"row\"><b>Url: </b></th>\n            <td style=\"padding-left: 4px;\"><a href=\"Library-SharedResourceCreation.html\">SharedResourceCreation</a></td>\n        </tr>\n        \n\n        \n\n        \n\n        \n        <tr>\n            <th scope=\"row\"><b>Status: </b></th>\n            <td style=\"padding-left: 4px;\">draft</td>\n        </tr>\n        \n\n        \n\n        \n        <tr>\n            <th scope=\"row\"><b>Type: </b></th>\n            <td style=\"padding-left: 4px;\">\n                \n                    \n                        \n                        <p style=\"margin-bottom: 5px;\">\n                            <b>system: </b> <span><a href=\"http://terminology.hl7.org/6.5.0/CodeSystem-library-type.html\">http://terminology.hl7.org/CodeSystem/library-type</a></span>\n                        </p>\n                        \n                        \n                        <p style=\"margin-bottom: 5px;\">\n                            <b>code: </b> <span>logic-library</span>\n                        </p>\n                        \n                        \n                    \n                \n                \n            </td>\n        </tr>\n        \n\n        \n\n        \n        <tr>\n            <th scope=\"row\"><b>Date: </b></th>\n            <td style=\"padding-left: 4px;\">2025-09-15 12:53:39-0400</td>\n        </tr>\n        \n\n        \n        <tr>\n            <th scope=\"row\"><b>Publisher: </b></th>\n            <td style=\"padding-left: 4px;\">CDC National Healthcare Safety Network (NHSN)</td>\n        </tr>\n        \n\n        \n\n        \n\n        \n\n        \n\n        \n        <tr>\n            <th scope=\"row\"><b>Jurisdiction: </b></th>\n            <td style=\"padding-left: 4px;\">US</td>\n        </tr>\n        \n\n        \n\n        \n\n        \n\n        \n\n        \n\n        \n\n        \n        <tr>\n            <th scope=\"row\"><b>Related Artifacts: </b></th>\n            <td style=\"padding-left: 4px;\">\n                \n                \n                \n                <p><b>Dependencies</b></p>\n                <ul>\n                  \n                    <li><a href=\"http://fhir.org/guides/cqf/common/4.0.1/4.0.1/Library-FHIR-ModelInfo.html\">http://fhir.org/guides/cqf/common/Library/FHIR-ModelInfo|4.0.1</a></li>\n                  \n                    <li><code>http://www.cdc.gov/nhsn/fhirportal/dqm/ig/Library/FHIRHelpers|4.0.2</code></li>\n                  \n                </ul>\n                \n                \n                \n                \n                \n            </td>\n        </tr>\n        \n\n        \n\n        \n\n        \n        \n        <tr>\n          <td colspan=\"2\">\n            <table>\n              <tr><th><a id=\"cql-content\"><b>Content: </b></a> text/cql</th></tr>\n              <tr><td><pre><code class=\"language-cql\">library SharedResourceCreation version '0.1.010'#xD;\n#xD;\ninclude FHIRHelpers version '4.0.2'#xD;\n#xD;\nusing FHIR version '4.0.1'#xD;\n#xD;\ndefine function \"GetIdExtensions\"(domainResource DomainResource):#xD;\n  domainResource.extension E#xD;\n  where E.url.value = 'http://www.cdc.gov/nhsn/fhirportal/dqm/ig/StructureDefinition/link-original-resource-id-extension'#xD;\n  return E#xD;\n#xD;\ndefine function \"GetPatientExtensions\"(domainResource DomainResource):#xD;\n  domainResource.extension E#xD;\n  where E.url.value = 'http://hl7.org/fhir/us/core/StructureDefinition/us-core-race'#xD;\n    or E.url.value = 'http://hl7.org/fhir/us/core/StructureDefinition/us-core-ethnicity'#xD;\n    or E.url.value = 'http://hl7.org/fhir/us/core/StructureDefinition/us-core-birthsex'#xD;\n    or E.url.value = 'http://www.cdc.gov/nhsn/fhirportal/dqm/ig/StructureDefinition/link-original-resource-id-extension'#xD;\n  return E#xD;\n#xD;\ndefine function \"MetaElement\"(resource Resource, profileURLs List&lt;FHIR.canonical&gt;):#xD;\n  resource r#xD;\n  return FHIR.Meta{#xD;\n    extension: r.meta.extension,#xD;\n    versionId: r.meta.versionId,#xD;\n    lastUpdated: r.meta.lastUpdated,#xD;\n    profile: profileURLs,#xD;\n    security: r.meta.security,#xD;\n    tag: r.meta.tag#xD;\n  }#xD;\n#xD;\ndefine function ConditionStage(stage List&lt;FHIR.Condition.Stage&gt;):#xD;\n  stage s#xD;\n  return FHIR.Condition.Stage{#xD;\n    summary: s.summary,#xD;\n    assessment: s.assessment,#xD;\n    type: s.type#xD;\n  }#xD;\n#xD;\ndefine function ConditionEvidence(evidence List&lt;FHIR.Condition.Evidence&gt;):#xD;\n  evidence e#xD;\n  return FHIR.Condition.Evidence{#xD;\n    code: e.code,#xD;\n    detail: e.detail#xD;\n  }#xD;\n#xD;\ndefine function ConditionResource(condition Condition, profileURLs List&lt;FHIR.canonical&gt;, acceptedCategories List&lt;System.Code&gt;):#xD;\n  condition c#xD;\n  return Condition{#xD;\n    id: FHIR.id {value: 'LCR-' + c.id},#xD;\n    meta: MetaElement(c, profileURLs),#xD;\n    extension: c.extension,#xD;\n    clinicalStatus: c.clinicalStatus,#xD;\n    verificationStatus: c.verificationStatus,#xD;\n    category: c.category,#xD;\n    severity: c.severity,#xD;\n    code: c.code,#xD;\n    bodySite: c.bodySite,#xD;\n    subject: c.subject,#xD;\n    encounter: c.encounter,#xD;\n    onset: c.onset,#xD;\n    abatement: c.abatement,#xD;\n    recordedDate: c.recordedDate,#xD;\n    stage: ConditionStage(c.stage),#xD;\n    evidence: ConditionEvidence(c.evidence),#xD;\n    note: c.note#xD;\n  }#xD;\n#xD;\ndefine function CoverageClass(class List&lt;FHIR.Coverage.Class&gt;):#xD;\n  class c#xD;\n  return FHIR.Coverage.Class{#xD;\n    value: c.value,#xD;\n    name: c.name#xD;\n  }#xD;\n#xD;\ndefine function CoverageResource(coverage Coverage, profileURLs List&lt;FHIR.canonical&gt;):#xD;\n  coverage c#xD;\n  return Coverage{#xD;\n    id: FHIR.id{value: 'LCR-' + c.id},#xD;\n    meta: MetaElement(c, profileURLs),#xD;\n    extension: c.extension,#xD;\n    status: c.status,#xD;\n    type: c.type,#xD;\n    policyHolder: c.policyHolder,#xD;\n    subscriber: c.subscriber,#xD;\n    subscriberId: c.subscriberId,#xD;\n    beneficiary: c.beneficiary,#xD;\n    dependent: c.dependent,#xD;\n    relationship: c.relationship,#xD;\n    period: c.period,#xD;\n    payor: c.payor,#xD;\n    class: CoverageClass(c.class),#xD;\n    order: c.order,#xD;\n    network: c.network,#xD;\n    subrogation: c.subrogation,#xD;\n    contract: c.contract#xD;\n  }#xD;\n#xD;\ndefine function DiagnosticReportCoding(coding List&lt;Coding&gt;):#xD;\n  coding c#xD;\n  return Coding{#xD;\n    system: c.system,#xD;\n    version: c.version,#xD;\n    code: c.code,#xD;\n    display: c.display,#xD;\n    userSelected: c.userSelected#xD;\n  }#xD;\n#xD;\ndefine function DiagnosticReportCategory(category List&lt;CodeableConcept&gt;):#xD;\n  category c#xD;\n  return CodeableConcept{#xD;\n    coding: DiagnosticReportCoding(c.coding)#xD;\n  }#xD;\n#xD;\ndefine function DiagnosticReportLabResource(diagnosticReport DiagnosticReport, profileURLs List&lt;FHIR.canonical&gt;):#xD;\n  diagnosticReport d#xD;\n  return DiagnosticReport{#xD;\n    id: FHIR.id{value: 'LCR-' + d.id},#xD;\n    meta: MetaElement(d, profileURLs),#xD;\n    extension: d.extension,#xD;\n    basedOn: d.basedOn,#xD;\n    status: d.status,#xD;\n    category: DiagnosticReportCategory(d.category),#xD;\n    code: d.code,#xD;\n    subject: d.subject,#xD;\n    encounter: d.encounter,#xD;\n    effective: d.effective,#xD;\n    issued: d.issued,#xD;\n    performer: d.performer,#xD;\n    resultsInterpreter: d.resultsInterpreter,#xD;\n    specimen: d.specimen,#xD;\n    result: d.result,#xD;\n    conclusion: d.conclusion,#xD;\n    conclusionCode: d.conclusionCode#xD;\n  }#xD;\n#xD;\ndefine function EncounterIdentifier(identifier List&lt;FHIR.Identifier&gt;):#xD;\n  identifier i#xD;\n  return FHIR.Identifier{#xD;\n    use: i.use,#xD;\n    type: i.type,#xD;\n    system: i.system,#xD;\n    value: i.value,#xD;\n    period: i.period#xD;\n  }#xD;\n#xD;\ndefine function EncounterStatusHistory(statusHistory List&lt;FHIR.Encounter.StatusHistory&gt;):#xD;\n  statusHistory sH#xD;\n  return FHIR.Encounter.StatusHistory{#xD;\n    status: sH.status,#xD;\n    period: sH.period#xD;\n  }#xD;\n#xD;\ndefine function EncounterClassHistory(classHistory List&lt;FHIR.Encounter.ClassHistory&gt;):#xD;\n  classHistory cH#xD;\n  return FHIR.Encounter.ClassHistory{#xD;\n    class: cH.class,#xD;\n    period: cH.period#xD;\n  }#xD;\n#xD;\n/*No longer needed but saving for potential future use#xD;\ndefine function EncounterParticipant(participant List&lt;FHIR.Encounter.Participant&gt;):#xD;\n  participant p#xD;\n  return FHIR.Encounter.Participant{#xD;\n    type: p.type,#xD;\n    period: p.period,#xD;\n    individual: p.individual#xD;\n  }*/#xD;\n#xD;\ndefine function EncounterDiagnosis(diagnosis List&lt;FHIR.Encounter.Diagnosis&gt;):#xD;\n  diagnosis d#xD;\n  return FHIR.Encounter.Diagnosis{#xD;\n    condition: d.condition,#xD;\n    use: d.use,#xD;\n    rank: d.rank#xD;\n  }#xD;\n#xD;\ndefine function EncounterHospitalization(hospitalization FHIR.Encounter.Hospitalization):#xD;\n  hospitalization h#xD;\n  return FHIR.Encounter.Hospitalization{#xD;\n    preAdmissionIdentifier: h.preAdmissionIdentifier,#xD;\n    origin: h.origin,#xD;\n    admitSource: h.admitSource,#xD;\n    reAdmission: h.reAdmission,#xD;\n    dietPreference: h.dietPreference,#xD;\n    specialCourtesy: h.specialCourtesy,#xD;\n    specialArrangement: h.specialArrangement,#xD;\n    destination: h.destination,#xD;\n    dischargeDisposition: h.dischargeDisposition#xD;\n  }#xD;\n#xD;\ndefine function EncounterLocation(location List&lt;FHIR.Encounter.Location&gt;):#xD;\n  location l#xD;\n  return FHIR.Encounter.Location{#xD;\n    location: l.location,#xD;\n    status: l.status,#xD;\n    physicalType: l.physicalType,#xD;\n    period: l.period#xD;\n  }#xD;\n#xD;\ndefine function EncounterResource(encounter Encounter, profileURLs List&lt;FHIR.canonical&gt;):#xD;\n  encounter e#xD;\n  return Encounter{#xD;\n    id: FHIR.id{value: 'LCR-' + e.id},#xD;\n    meta: MetaElement(e, profileURLs),#xD;\n    extension: e.extension,#xD;\n    identifier: EncounterIdentifier(e.identifier),#xD;\n    status: e.status,#xD;\n    statusHistory: EncounterStatusHistory(e.statusHistory),#xD;\n    class: e.class,#xD;\n    classHistory: EncounterClassHistory(e.classHistory),#xD;\n    type: e.type,#xD;\n    serviceType: e.serviceType,#xD;\n    priority: e.priority,#xD;\n    subject: e.subject,#xD;\n    period: e.period,#xD;\n    length: e.length,#xD;\n    reasonCode: e.reasonCode,#xD;\n    reasonReference: e.reasonReference,#xD;\n    diagnosis: EncounterDiagnosis(e.diagnosis),#xD;\n    account: e.account,#xD;\n    hospitalization: EncounterHospitalization(e.hospitalization),#xD;\n    location: EncounterLocation(e.location),#xD;\n    partOf: e.partOf#xD;\n  }#xD;\n#xD;\ndefine function ObservationLabCoding(coding List&lt;Coding&gt;):#xD;\n  coding c#xD;\n  return Coding{#xD;\n    id: c.id,#xD;\n    extension: c.extension,#xD;\n    system: c.system,#xD;\n    version: c.version,#xD;\n    code: c.code,#xD;\n    display: c.display,#xD;\n    userSelected: c.userSelected#xD;\n  }#xD;\n#xD;\ndefine function ObservationLabCategory(category List&lt;CodeableConcept&gt;):#xD;\n  category c#xD;\n  return CodeableConcept{#xD;\n    coding: ObservationLabCoding(c.coding),#xD;\n    text: c.text#xD;\n  }#xD;\n#xD;\ndefine function ObservationReferenceRange(referenceRange List&lt;FHIR.Observation.ReferenceRange&gt;):#xD;\n  referenceRange rR#xD;\n  return FHIR.Observation.ReferenceRange{#xD;\n    low: rR.low,#xD;\n    high: rR.high,#xD;\n    type: rR.type,#xD;\n    appliesTo: rR.appliesTo,#xD;\n    age: rR.age,#xD;\n    text: rR.text#xD;\n  }#xD;\n#xD;\ndefine function ObservationComponent(component List&lt;FHIR.Observation.Component&gt;):#xD;\n  component c#xD;\n  return FHIR.Observation.Component{#xD;\n    code: c.code,#xD;\n    value: c.value,#xD;\n    dataAbsentReason: c.dataAbsentReason,#xD;\n    interpretation: c.interpretation,#xD;\n    referenceRange: c.referenceRange#xD;\n  }#xD;\n#xD;\ndefine function ObservationLabResource(observation Observation, profileURLs List&lt;FHIR.canonical&gt;):#xD;\n  observation o#xD;\n  return Observation{#xD;\n    id: FHIR.id {value: 'LCR-' + o.id},#xD;\n    meta: MetaElement(o, profileURLs),#xD;\n    extension: o.extension,#xD;\n    basedOn: o.basedOn,#xD;\n    partOf: o.partOf,#xD;\n    status: o.status,#xD;\n    category: ObservationLabCategory(o.category),#xD;\n    code: o.code,#xD;\n    subject: o.subject,#xD;\n    focus: o.focus,#xD;\n    encounter: o.encounter,#xD;\n    effective: o.effective,#xD;\n    issued: o.issued,#xD;\n    performer: o.performer,#xD;\n    value: o.value,#xD;\n    dataAbsentReason: o.dataAbsentReason,#xD;\n    interpretation: o.interpretation,#xD;\n    note: o.note,#xD;\n    bodySite: o.bodySite,#xD;\n    method: o.method,#xD;\n    specimen: o.specimen,#xD;\n    device: o.device,#xD;\n    referenceRange: ObservationReferenceRange(o.referenceRange),#xD;\n    hasMember: o.hasMember,#xD;\n    derivedFrom: o.derivedFrom,#xD;\n    component: ObservationComponent(o.component)#xD;\n  }#xD;\n#xD;\ndefine function LocationAddress(address FHIR.Address):#xD;\n  address a#xD;\n  return FHIR.Address{#xD;\n    use: a.use,#xD;\n    type: a.type,#xD;\n    text: a.text,#xD;\n    line: a.line,#xD;\n    city: a.city,#xD;\n    district: a.district,#xD;\n    state: a.state,#xD;\n    postalCode: a.postalCode,#xD;\n    country: a.country,#xD;\n    period: a.period#xD;\n  }#xD;\n#xD;\ndefine function LocationPosition(position FHIR.Location.Position):#xD;\n  position p#xD;\n  return FHIR.Location.Position{#xD;\n    longitude: p.longitude,#xD;\n    latitude: p.latitude,#xD;\n    altitude: p.altitude#xD;\n  }#xD;\n#xD;\ndefine function LocationHoursOfOperation(hoursOfOperation List&lt;FHIR.Location.HoursOfOperation&gt;):#xD;\n  hoursOfOperation hOO#xD;\n  return FHIR.Location.HoursOfOperation{#xD;\n    daysOfWeek: hOO.daysOfWeek,#xD;\n    allDay: hOO.allDay,#xD;\n    openingTime: hOO.openingTime,#xD;\n    closingTime: hOO.closingTime#xD;\n  }#xD;\n#xD;\ndefine function LocationResource(location Location, profileURLs List&lt;FHIR.canonical&gt;):#xD;\n  location l#xD;\n  return Location{#xD;\n    id: FHIR.id {value: 'LCR-' + l.id},#xD;\n    meta: MetaElement(l, profileURLs),#xD;\n    extension: l.extension,#xD;\n    status: l.status,#xD;\n    operationalStatus: l.operationalStatus,#xD;\n    name: l.name,#xD;\n    alias: l.alias,#xD;\n    description: l.description,#xD;\n    mode: l.mode,#xD;\n    type: l.type,#xD;\n    telecom: l.telecom,#xD;\n    address: LocationAddress(l.address),#xD;\n    physicalType: l.physicalType,#xD;\n    position: LocationPosition(l.position),#xD;\n    managingOrganization: l.managingOrganization,#xD;\n    partOf: l.partOf,#xD;\n    hoursOfOperation: LocationHoursOfOperation(l.hoursOfOperation),#xD;\n    availabilityExceptions: l.availabilityExceptions,#xD;\n    endpoint: l.endpoint#xD;\n  }#xD;\n#xD;\ndefine function MedicationIngredient(ingredient List&lt;FHIR.Medication.Ingredient&gt;):#xD;\n  ingredient i#xD;\n  return FHIR.Medication.Ingredient{#xD;\n    item: i.item,#xD;\n    strength: i.strength#xD;\n  }#xD;\n#xD;\ndefine function MedicationBatch(batch FHIR.Medication.Batch):#xD;\n  batch b#xD;\n  return FHIR.Medication.Batch{#xD;\n    lotNumber: b.lotNumber,#xD;\n    expirationDate: b.expirationDate#xD;\n  }#xD;\n#xD;\ndefine function MedicationResource(medication Medication, profileURLs List&lt;FHIR.canonical&gt;):#xD;\n  medication m#xD;\n  return Medication{#xD;\n    id: FHIR.id {value: 'LCR-' + m.id},#xD;\n    meta: MetaElement(m, profileURLs),#xD;\n    extension: m.extension,#xD;\n    code: m.code,#xD;\n    status: m.status,#xD;\n    manufacturer: m.manufacturer,#xD;\n    form: m.form,#xD;\n    amount: m.amount,#xD;\n    ingredient: MedicationIngredient(m.ingredient),#xD;\n    batch: MedicationBatch(m.batch)#xD;\n  }#xD;\n#xD;\ndefine function MedicationAdministrationPerformer(performer List&lt;FHIR.MedicationAdministration.Performer&gt;):#xD;\n  performer p#xD;\n  return FHIR.MedicationAdministration.Performer{#xD;\n    function: p.function,#xD;\n    actor: p.actor#xD;\n  }#xD;\n#xD;\ndefine function MedicationAdministrationDosage(dosage FHIR.MedicationAdministration.Dosage):#xD;\n  dosage d#xD;\n  return FHIR.MedicationAdministration.Dosage{#xD;\n    text: d.text,#xD;\n    site: d.site,#xD;\n    route: d.route,#xD;\n    method: d.method,#xD;\n    dose: d.dose,#xD;\n    rate: d.rate#xD;\n  }#xD;\n#xD;\ndefine function MedicationAdministrationResource(medicationAdministration MedicationAdministration, profileURLs List&lt;FHIR.canonical&gt;):#xD;\n  medicationAdministration m#xD;\n  return MedicationAdministration{#xD;\n    id: FHIR.id {value: 'LCR-' + m.id},#xD;\n    meta: MetaElement(m, profileURLs),#xD;\n    extension: m.extension,#xD;\n    instantiates: m.instantiates,#xD;\n    partOf: m.partOf,#xD;\n    status: m.status,#xD;\n    statusReason: m.statusReason,#xD;\n    category: m.category,#xD;\n    medication: m.medication,#xD;\n    subject: m.subject,#xD;\n    context: m.context,#xD;\n    supportingInformation: m.supportingInformation,#xD;\n    effective: m.effective,#xD;\n    performer: MedicationAdministrationPerformer(m.performer),#xD;\n    reasonCode: m.reasonCode,#xD;\n    reasonReference: m.reasonReference,#xD;\n    request: m.request,#xD;\n    device: m.device,#xD;\n    note: m.note,#xD;\n    dosage: MedicationAdministrationDosage(m.dosage),#xD;\n    eventHistory: m.eventHistory#xD;\n  }#xD;\n#xD;\ndefine function MedicationRequestDoseAndRate(doseAndRate List&lt;FHIR.Dosage.DoseAndRate&gt;):#xD;\n  doseAndRate dR#xD;\n  return FHIR.Dosage.DoseAndRate{#xD;\n    type: dR.type,#xD;\n    dose: dR.dose,#xD;\n    rate: dR.rate#xD;\n  }#xD;\n#xD;\ndefine function MedicationRequestDosageInstruction(dosageInstruction List&lt;FHIR.Dosage&gt;):#xD;\n  dosageInstruction dI#xD;\n  return FHIR.Dosage{#xD;\n    text: dI.text,#xD;\n    patientInstruction: dI.patientInstruction,#xD;\n    timing: dI.timing,#xD;\n    asNeeded: dI.asNeeded,#xD;\n    site: dI.site,#xD;\n    route: dI.route,#xD;\n    method: dI.method,#xD;\n    doseAndRate: MedicationRequestDoseAndRate(dI.doseAndRate)#xD;\n  }#xD;\n#xD;\ndefine function MedicationRequestResource(medicationRequest MedicationRequest, profileURLs List&lt;FHIR.canonical&gt;):#xD;\n  medicationRequest m#xD;\n  return MedicationRequest{#xD;\n    id: FHIR.id {value: 'LCR-' + m.id},#xD;\n    meta: MetaElement(medicationRequest, profileURLs),#xD;\n    extension: m.extension,#xD;\n    status: m.status,#xD;\n    statusReason: m.statusReason,#xD;\n    intent: m.intent,#xD;\n    category: m.category,#xD;\n    priority: m.priority,#xD;\n    doNotPerform: m.doNotPerform,#xD;\n    reported: m.reported,#xD;\n    medication: m.medication,#xD;\n    subject: m.subject,#xD;\n    encounter: m.encounter,#xD;\n    authoredOn: m.authoredOn,#xD;\n    requester: m.requester,#xD;\n    recorder: m.recorder,#xD;\n    reasonCode: m.reasonCode,#xD;\n    reasonReference: m.reasonReference,#xD;\n    instantiatesCanonical: m.instantiatesCanonical,#xD;\n    instantiatesUri: m.instantiatesUri,#xD;\n    courseOfTherapyType: m.courseOfTherapyType,#xD;\n    dosageInstruction: MedicationRequestDosageInstruction(m.dosageInstruction)#xD;\n  }#xD;\n#xD;\n/* No longer needed but saving in case it's useful later#xD;\ndefine function PatientIdentifier(identifier List&lt;FHIR.Identifier&gt;):#xD;\n  identifier i#xD;\n  return FHIR.Identifier{#xD;\n    id: i.id,#xD;\n    extension: i.extension,#xD;\n    use: i.use,#xD;\n    type: i.type,#xD;\n    system: i.system,#xD;\n    value: i.value,#xD;\n    period: i.period,#xD;\n    assigner: i.assigner#xD;\n  }*/#xD;\n#xD;\ndefine function PatientName(name List&lt;FHIR.HumanName&gt;):#xD;\n  name n#xD;\n  return FHIR.HumanName{#xD;\n    id: n.id,#xD;\n    extension: n.extension,#xD;\n    use: n.use,#xD;\n    text: n.text,#xD;\n    family: n.family,#xD;\n    given: n.given,#xD;\n    prefix: n.prefix,#xD;\n    suffix: n.suffix,#xD;\n    period: n.period#xD;\n  }#xD;\n#xD;\ndefine function PatientTelecom(telecom List&lt;FHIR.ContactPoint&gt;):#xD;\n  telecom t#xD;\n  return FHIR.ContactPoint{#xD;\n    system: t.system,#xD;\n    value: t.value,#xD;\n    use: t.use,#xD;\n    rank: t.rank,#xD;\n    period: t.period#xD;\n  }#xD;\n#xD;\ndefine function PatientAddress(address List&lt;FHIR.Address&gt;):#xD;\n  address a#xD;\n  return FHIR.Address{#xD;\n    id: a.id,#xD;\n    extension: a.extension,#xD;\n    use: a.use,#xD;\n    type: a.type,#xD;\n    text: a.text,#xD;\n    line: a.line,#xD;\n    city: a.city,#xD;\n    district: a.district,#xD;\n    state: a.state,#xD;\n    postalCode: a.postalCode,#xD;\n    country: a.country,#xD;\n    period: a.period#xD;\n  }#xD;\n#xD;\ndefine function PatientContact(contact List&lt;FHIR.Patient.Contact&gt;):#xD;\n  contact c#xD;\n  return FHIR.Patient.Contact{#xD;\n    id: c.id,#xD;\n    extension: c.extension,#xD;\n    relationship: c.relationship,#xD;\n    name: c.name,#xD;\n    telecom: c.telecom,#xD;\n    address: c.address,#xD;\n    gender: c.gender,#xD;\n    organization: c.organization,#xD;\n    period: c.period#xD;\n  }#xD;\n#xD;\ndefine function PatientCommunication(communication List&lt;FHIR.Patient.Communication&gt;):#xD;\n  communication c#xD;\n  return FHIR.Patient.Communication{#xD;\n    id: c.id,#xD;\n    extension: c.extension,#xD;\n    language: c.language,#xD;\n    preferred: c.preferred#xD;\n  }#xD;\n#xD;\ndefine function PatientLink(link List&lt;FHIR.Patient.Link&gt;):#xD;\n  link l#xD;\n  return FHIR.Patient.Link{#xD;\n    id: l.id,#xD;\n    extension: l.extension,#xD;\n    modifierExtension: l.modifierExtension,#xD;\n    other: l.other,#xD;\n    type: l.type#xD;\n  }#xD;\n#xD;\ndefine function PatientResource(patient Patient, profileURLs List&lt;FHIR.canonical&gt;):#xD;\n  patient p#xD;\n  return Patient{#xD;\n    id: FHIR.id{value: 'LCR-' + p.id},#xD;\n    meta: MetaElement(p, profileURLs),#xD;\n    extension: GetPatientExtensions(p) union GetIdExtensions(p),#xD;\n    identifier: p.identifier,#xD;\n    active: p.active,#xD;\n    name: PatientName(p.name),#xD;\n    telecom: PatientTelecom(p.telecom),#xD;\n    gender: p.gender,#xD;\n    birthDate: p.birthDate,#xD;\n    deceased: p.deceased,#xD;\n    address: PatientAddress(p.address),#xD;\n    maritalStatus: p.maritalStatus,#xD;\n    multipleBirth: p.multipleBirth,#xD;\n    photo: p.photo,#xD;\n    contact: PatientContact(p.contact),#xD;\n    communication: PatientCommunication(p.communication),#xD;\n    generalPractitioner: p.generalPractitioner,#xD;\n    managingOrganization: p.managingOrganization,#xD;\n    link: PatientLink(p.link)#xD;\n  }#xD;\n#xD;\ndefine function ProcedurePerformer(performer List&lt;FHIR.Procedure.Performer&gt;):#xD;\n  performer p#xD;\n  return FHIR.Procedure.Performer{#xD;\n    function: p.function,#xD;\n    actor: p.actor,#xD;\n    onBehalfOf: p.onBehalfOf#xD;\n  }#xD;\n#xD;\ndefine function ProcedureFocalDevice(device List&lt;FHIR.Procedure.FocalDevice&gt;):#xD;\n  device d#xD;\n  return FHIR.Procedure.FocalDevice{#xD;\n    action: d.action,#xD;\n    manipulated: d.manipulated#xD;\n  }#xD;\n#xD;\ndefine function ProcedureResource(procedure Procedure, profileURLs List&lt;FHIR.canonical&gt;):#xD;\n  procedure p#xD;\n  return Procedure{#xD;\n    id: FHIR.id {value: 'LCR-' + p.id},#xD;\n    meta: MetaElement(p, profileURLs),#xD;\n    extension: p.extension,#xD;\n    instantiatesCanonical: p.instantiatesCanonical,#xD;\n    instantiatesUri: p.instantiatesUri,#xD;\n    basedOn: p.basedOn,#xD;\n    partOf: p.partOf,#xD;\n    status: p.status,#xD;\n    statusReason: p.statusReason,#xD;\n    category: p.category,#xD;\n    code: p.code,#xD;\n    subject: p.subject,#xD;\n    encounter: p.encounter,#xD;\n    performed: p.performed,#xD;\n    recorder: p.recorder,#xD;\n    asserter: p.asserter,#xD;\n    performer: ProcedurePerformer(p.performer),#xD;\n    location: p.location,#xD;\n    reasonCode: p.reasonCode,#xD;\n    reasonReference: p.reasonReference,#xD;\n    bodySite: p.bodySite,#xD;\n    outcome: p.outcome,#xD;\n    report: p.report,#xD;\n    complication: p.complication,#xD;\n    complicationDetail: p.complicationDetail,#xD;\n    followUp: p.followUp,#xD;\n    note: p.note,#xD;\n    focalDevice: ProcedureFocalDevice(p.focalDevice),#xD;\n    usedReference: p.usedReference,#xD;\n    usedCode: p.usedCode#xD;\n  }#xD;\n#xD;\ndefine function ServiceRequestResource(serviceRequest ServiceRequest, profileURLs List&lt;FHIR.canonical&gt;):#xD;\n  serviceRequest sR#xD;\n  return ServiceRequest{#xD;\n    id: FHIR.id {value: 'LCR-' + sR.id},#xD;\n    meta: MetaElement(sR, profileURLs),#xD;\n    extension: sR.extension,#xD;\n    instantiatesCanonical: sR.instantiatesCanonical,#xD;\n    instantiatesUri: sR.instantiatesUri,#xD;\n    basedOn: sR.basedOn,#xD;\n    replaces: sR.replaces,#xD;\n    requisition: sR.requisition,#xD;\n    status: sR.status,#xD;\n    intent: sR.intent,#xD;\n    category: sR.category,#xD;\n    priority: sR.priority,#xD;\n    doNotPerform: sR.doNotPerform,#xD;\n    code: sR.code,#xD;\n    orderDetail: sR.orderDetail,#xD;\n    quantity: sR.quantity,#xD;\n    subject: sR.subject,#xD;\n    encounter: sR.encounter,#xD;\n    occurrence: sR.occurrence,#xD;\n    asNeeded: sR.asNeeded,#xD;\n    authoredOn: sR.authoredOn,#xD;\n    requester: sR.requester,#xD;\n    performerType: sR.performerType,#xD;\n    performer: sR.performer,#xD;\n    locationCode: sR.locationCode,#xD;\n    locationReference: sR.locationReference,#xD;\n    reasonCode: sR.reasonCode,#xD;\n    reasonReference: sR.reasonReference,#xD;\n    insurance: sR.insurance,#xD;\n    supportingInfo: sR.supportingInfo,#xD;\n    specimen: sR.specimen,#xD;\n    bodySite: sR.bodySite,#xD;\n    note: sR.note,#xD;\n    patientInstruction: sR.patientInstruction,#xD;\n    relevantHistory: sR.relevantHistory#xD;\n  }#xD;\n#xD;\ndefine function SpecimenCollection(collection FHIR.Specimen.Collection):#xD;\n  collection c#xD;\n  return FHIR.Specimen.Collection{#xD;\n    collector: c.collector,#xD;\n    collected: c.collected,#xD;\n    \"duration\": c.\"duration\",#xD;\n    quantity: c.quantity,#xD;\n    method: c.method,#xD;\n    bodySite: c.bodySite,#xD;\n    fastingStatus: c.fastingStatus#xD;\n  }#xD;\n#xD;\ndefine function SpecimenProcessing(processing List&lt;FHIR.Specimen.Processing&gt;):#xD;\n  processing p#xD;\n  return FHIR.Specimen.Processing{#xD;\n    description: p.description,#xD;\n    procedure: p.procedure,#xD;\n    additive: p.additive,#xD;\n    time: p.time#xD;\n  }#xD;\n#xD;\ndefine function SpecimenContainer(container List&lt;FHIR.Specimen.Container&gt;):#xD;\n  container c#xD;\n  return FHIR.Specimen.Container{#xD;\n    description: c.description,#xD;\n    type: c.type,#xD;\n    capacity: c.capacity,#xD;\n    specimenQuantity: c.specimenQuantity,#xD;\n    additive: c.additive#xD;\n  }#xD;\n#xD;\ndefine function SpecimenResource(specimen Specimen, profileURLs List&lt;FHIR.canonical&gt;):#xD;\n  specimen s#xD;\n  return Specimen{#xD;\n    id: FHIR.id {value: 'LCR-' + s.id},#xD;\n    meta: MetaElement(s, profileURLs),#xD;\n    extension: s.extension,#xD;\n    identifier: s.identifier,#xD;\n    accessionIdentifier: s.accessionIdentifier,#xD;\n    status: s.status,#xD;\n    type: s.type,#xD;\n    subject: s.subject,#xD;\n    receivedTime: s.receivedTime,#xD;\n    parent: s.parent,#xD;\n    request: s.request,#xD;\n    collection: SpecimenCollection(s.collection),#xD;\n    processing: SpecimenProcessing(s.processing),#xD;\n    container: SpecimenContainer(s.container),#xD;\n    condition: s.condition,#xD;\n    note: s.note#xD;\n  }#xD;\n#xD;\ndefine function \"OperationOutcomeResource\"(errorId String, resourceId FHIR.id, message String):#xD;\n  OperationOutcome{#xD;\n      id: FHIR.id{value: errorId},#xD;\n      issue: {#xD;\n          FHIR.OperationOutcome.Issue{#xD;\n          severity: FHIR.IssueSeverity{value: 'error'},#xD;\n          code: FHIR.IssueType{value: 'exception'},#xD;\n          details: #xD;\n              FHIR.CodeableConcept{#xD;\n                  coding: {#xD;\n                      Coding{#xD;\n                      system: uri{value: 'https://lantanagroup.com/validation-error'},#xD;\n                      code: code{value: 'Error'},#xD;\n                      display: string{value: 'Resource ' + resourceId + ' failed validation: ' + message}#xD;\n                      }#xD;\n                  }#xD;\n              }#xD;\n          }#xD;\n      }#xD;\n  }</code></pre></td></tr>\n            </table>\n          </td>\n        </tr>\n        \n        \n        \n    </table>\n</div>\n</div>"^^rdf:XMLLiteral
      ] ; #
      fhir:contained ( [
    a fhir:Parameters ;
    fhir:id [ fhir:v "options" ] ;
        ( fhir:parameter [
    fhir:name [ fhir:v "translatorVersion" ] ;
    fhir:value [
    a fhir:string ;
    fhir:v "3.25.0"       ]     ] [
    fhir:name [ fhir:v "option" ] ;
    fhir:value [
    a fhir:string ;
    fhir:v "EnableDateRangeOptimization"       ]     ] [
    fhir:name [ fhir:v "option" ] ;
    fhir:value [
    a fhir:string ;
    fhir:v "EnableAnnotations"       ]     ] [
    fhir:name [ fhir:v "option" ] ;
    fhir:value [
    a fhir:string ;
    fhir:v "EnableLocators"       ]     ] [
    fhir:name [ fhir:v "option" ] ;
    fhir:value [
    a fhir:string ;
    fhir:v "DisableListDemotion"       ]     ] [
    fhir:name [ fhir:v "option" ] ;
    fhir:value [
    a fhir:string ;
    fhir:v "DisableListPromotion"       ]     ] [
    fhir:name [ fhir:v "analyzeDataRequirements" ] ;
    fhir:value [
    a fhir:boolean ;
    fhir:v false       ]     ] [
    fhir:name [ fhir:v "collapseDataRequirements" ] ;
    fhir:value [
    a fhir:boolean ;
    fhir:v true       ]     ] [
    fhir:name [ fhir:v "compatibilityLevel" ] ;
    fhir:value [
    a fhir:string ;
    fhir:v "1.5"       ]     ] [
    fhir:name [ fhir:v "enableCqlOnly" ] ;
    fhir:value [
    a fhir:boolean ;
    fhir:v false       ]     ] [
    fhir:name [ fhir:v "errorLevel" ] ;
    fhir:value [
    a fhir:string ;
    fhir:v "Info"       ]     ] [
    fhir:name [ fhir:v "signatureLevel" ] ;
    fhir:value [
    a fhir:string ;
    fhir:v "Overloads"       ]     ] [
    fhir:name [ fhir:v "validateUnits" ] ;
    fhir:value [
    a fhir:boolean ;
    fhir:v true       ]     ] [
    fhir:name [ fhir:v "verifyOnly" ] ;
    fhir:value [
    a fhir:boolean ;
    fhir:v false       ]     ] )
      ] ) ; #
      fhir:extension ( [
    fhir:url [ fhir:v "http://hl7.org/fhir/StructureDefinition/cqf-cqlOptions"^^xsd:anyURI ] ;
    fhir:value [
    a fhir:Reference ;
    fhir:reference [ fhir:v "#options" ]     ]
      ] ) ; #
      fhir:url [ fhir:v "http://www.cdc.gov/nhsn/fhirportal/dqm/ig/Library/SharedResourceCreation"^^xsd:anyURI] ; #
      fhir:version [ fhir:v "1.0.0"] ; #
      fhir:name [ fhir:v "SharedResourceCreation"] ; #
      fhir:status [ fhir:v "draft"] ; #
      fhir:type [
        ( fhir:coding [
    fhir:system [ fhir:v "http://terminology.hl7.org/CodeSystem/library-type"^^xsd:anyURI ] ;
    fhir:code [ fhir:v "logic-library" ]     ] )
      ] ; #
      fhir:date [ fhir:v "2025-09-15T12:53:39-04:00"^^xsd:dateTime] ; #
      fhir:publisher [ fhir:v "CDC National Healthcare Safety Network (NHSN)"] ; #
      fhir:contact ( [
    fhir:name [ fhir:v "CDC National Healthcare Safety Network (NHSN)" ] ;
        ( fhir:telecom [
    fhir:system [ fhir:v "url" ] ;
    fhir:value [ fhir:v "http://www.cdc.gov/nhsn" ]     ] [
    fhir:system [ fhir:v "email" ] ;
    fhir:value [ fhir:v "nhsn@cdc.gov" ]     ] )
      ] ) ; #
      fhir:jurisdiction ( [
        ( fhir:coding [
    fhir:system [ fhir:v "urn:iso:std:iso:3166"^^xsd:anyURI ] ;
    fhir:code [ fhir:v "US" ]     ] )
      ] ) ; #
      fhir:relatedArtifact ( [
    fhir:type [ fhir:v "depends-on" ] ;
    fhir:display [ fhir:v "FHIR model information" ] ;
    fhir:resource [
    fhir:v "http://fhir.org/guides/cqf/common/Library/FHIR-ModelInfo|4.0.1"^^xsd:anyURI ;
    fhir:link <http://fhir.org/guides/cqf/common/Library/FHIR-ModelInfo|4.0.1>     ]
      ] [
    fhir:type [ fhir:v "depends-on" ] ;
    fhir:display [ fhir:v "Library FHIRHelpers" ] ;
    fhir:resource [
    fhir:v "http://www.cdc.gov/nhsn/fhirportal/dqm/ig/Library/FHIRHelpers|4.0.2"^^xsd:anyURI ;
    fhir:link <http://www.cdc.gov/nhsn/fhirportal/dqm/ig/Library/FHIRHelpers|4.0.2>     ]
      ] ) ; #
      fhir:content ( [
    fhir:contentType [ fhir:v "text/cql" ] ;
    fhir:data [ fhir:v " "^^xsd:base64Binary ]
      ] ) . #