{"name": "procedure-code-nullflavor-attribute", "comment": "A procedure whose code states no code, only the nullFlavor UNK: no cascade:procedureCode, and the version's #absent-procedureCode node names the v3 NullFlavor code UNK as its cascade:absentReasonCode.", "input": {"file": "fixtures/in/procedure-code-nullflavor-attribute.xml", "link": "https://github.com/the-cascade-protocol/cascade-bridge-adapter-ccda/blob/0c6ffe52b3c3d2dcd0dfaf3f0b9e00b69bf2ba96/fixtures/in/procedure-code-nullflavor-attribute.xml", "text": "<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n<ClinicalDocument xmlns=\"urn:hl7-org:v3\" xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\">\n  <realmCode code=\"US\"/>\n  <typeId root=\"2.16.840.1.113883.1.3\" extension=\"POCD_HD000040\"/>\n  <templateId root=\"2.16.840.1.113883.10.20.22.1.1\" extension=\"2015-08-01\"/>\n  <templateId root=\"2.16.840.1.113883.10.20.22.1.2\" extension=\"2015-08-01\"/>\n  <id root=\"2.16.840.1.113883.19.5.99999.1\" extension=\"CCD-2026-1029-R\"/>\n  <code code=\"34133-9\" displayName=\"Summarization of Episode Note\" codeSystem=\"2.16.840.1.113883.6.1\" codeSystemName=\"LOINC\"/>\n  <title>Continuity of Care Document</title>\n  <effectiveTime value=\"20261029090000-0500\"/>\n  <confidentialityCode code=\"N\" codeSystem=\"2.16.840.1.113883.5.25\"/>\n  <languageCode code=\"en-US\"/>\n  <recordTarget>\n    <patientRole>\n      <id root=\"2.16.840.1.113883.19.5.99999.2\" extension=\"MRN-552012\"/>\n      <patient>\n        <name use=\"L\">\n          <given>Ada</given>\n          <family>Okonjo</family>\n        </name>\n        <administrativeGenderCode code=\"F\" codeSystem=\"2.16.840.1.113883.5.1\"/>\n        <birthTime value=\"19480302\"/>\n      </patient>\n    </patientRole>\n  </recordTarget>\n  <author>\n    <time value=\"20261029090000-0500\"/>\n    <assignedAuthor>\n      <id root=\"2.16.840.1.113883.19.5.99999.3\"/>\n      <representedOrganization>\n        <name>Riverside Community Hospital</name>\n      </representedOrganization>\n    </assignedAuthor>\n  </author>\n  <custodian>\n    <assignedCustodian>\n      <representedCustodianOrganization>\n        <id root=\"2.16.840.1.113883.19.5.99999.3\"/>\n        <name>Riverside Community Hospital</name>\n      </representedCustodianOrganization>\n    </assignedCustodian>\n  </custodian>\n  <component>\n    <structuredBody>\n      <component>\n        <section>\n          <templateId root=\"2.16.840.1.113883.10.20.22.2.7.1\" extension=\"2015-08-01\"/>\n          <code code=\"47519-4\" displayName=\"History of Procedures Document\" codeSystem=\"2.16.840.1.113883.6.1\" codeSystemName=\"LOINC\"/>\n          <title>Procedures</title>\n          <entry typeCode=\"DRIV\">\n            <procedure classCode=\"PROC\" moodCode=\"EVN\">\n              <templateId root=\"2.16.840.1.113883.10.20.22.4.14\" extension=\"2014-06-09\"/>\n              <id root=\"2.16.840.1.113883.19.5.99999.5\" extension=\"PROC-2011\"/>\n              <code nullFlavor=\"UNK\"/>\n              <statusCode code=\"completed\"/>\n              <effectiveTime value=\"20240214\"/>\n            </procedure>\n          </entry>\n        </section>\n      </component>\n    </structuredBody>\n  </component>\n</ClinicalDocument>\n"}, "expectedGraph": {"file": "fixtures/expected/procedure-code-nullflavor-attribute.ttl", "link": "https://github.com/the-cascade-protocol/cascade-bridge-adapter-ccda/blob/0c6ffe52b3c3d2dcd0dfaf3f0b9e00b69bf2ba96/fixtures/expected/procedure-code-nullflavor-attribute.ttl", "text": "@prefix bridge: <https://ns.cascadeprotocol.org/bridge/v1-draft#> .\n@prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .\n@prefix cascade: <https://ns.cascadeprotocol.org/cascade#> .\n@prefix xsd: <http://www.w3.org/2001/XMLSchema#> .\n@prefix foaf: <http://xmlns.com/foaf/0.1/> .\n@prefix prov: <http://www.w3.org/ns/prov#> .\n@prefix org: <http://www.w3.org/ns/org#> .\n@prefix oa: <http://www.w3.org/ns/oa#> .\n<urn:uuid:5769da63-d46b-8c66-b381-d00b2f7ccadb> a cascade:Organization .\n<ni:///sha-256;HWUslDL762oNuBdJ51YHIB5aZYnsOsv0joC1DL6ZC_A> prov:wasGeneratedBy _:aa21b1e187934b33ffe9f90d9789d1ca ;\n\tprov:wasAttributedTo <urn:uuid:5769da63-d46b-8c66-b381-d00b2f7ccadb> .\n_:aa21b1e187934b33ffe9f90d9789d1ca prov:qualifiedAssociation _:d87d9a9ccdcb730228203b223d364c2a .\n_:d87d9a9ccdcb730228203b223d364c2a prov:agent <urn:uuid:5769da63-d46b-8c66-b381-d00b2f7ccadb> ;\n\tprov:hadRole cascade:CustodianRole .\n<ni:///sha-256;grKi0ms_W2WGoIJBSajj9WqQqFYdSHTIaehKWGv5yRg> prov:specializationOf <urn:uuid:5769da63-d46b-8c66-b381-d00b2f7ccadb> .\n_:b7f630de8656ce841e9687fdbba8bdf8 bridge:arrivedAs <ni:///sha-256;grKi0ms_W2WGoIJBSajj9WqQqFYdSHTIaehKWGv5yRg> ;\n\toa:hasSelector _:a909fcba354653df50cbc67149c83493 .\n_:a909fcba354653df50cbc67149c83493 a oa:XPathSelector ;\n\trdf:value \"/*[local-name()='ClinicalDocument' and namespace-uri()='urn:hl7-org:v3']/*[local-name()='custodian' and namespace-uri()='urn:hl7-org:v3'][1]/*[local-name()='assignedCustodian' and namespace-uri()='urn:hl7-org:v3'][1]/*[local-name()='representedCustodianOrganization' and namespace-uri()='urn:hl7-org:v3'][1]\" .\n<ni:///sha-256;grKi0ms_W2WGoIJBSajj9WqQqFYdSHTIaehKWGv5yRg> foaf:name \"Riverside Community Hospital\" ;\n\torg:identifier \"urn:oid:2.16.840.1.113883.19.5.99999.3\"^^<urn:ietf:rfc:3986> .\n<ni:///sha-256;EVwdxLuG51G60_9c_XpCwjPNK7H2ZQcLTj262S_EZA8> foaf:familyName \"Okonjo\" ;\n\tfoaf:givenName \"Ada\" ;\n\tcascade:dateOfBirth \"1948-03-02\"^^xsd:date ;\n\tcascade:administrativeGender \"female\" .\n<ni:///sha-256;Cy3na1Z9vHKxSUZ0LTRh4lpec64mjdTdfUAEIvDDheQ> cascade:procedureDate \"2024-02-14\"^^xsd:date ;\n\tcascade:workflowStatus \"completed\" ;\n\tcascade:valueAbsentForReason <ni:///sha-256;Cy3na1Z9vHKxSUZ0LTRh4lpec64mjdTdfUAEIvDDheQ#absent-procedureCode> .\n<ni:///sha-256;Cy3na1Z9vHKxSUZ0LTRh4lpec64mjdTdfUAEIvDDheQ#absent-procedureCode> cascade:absentValueProperty cascade:procedureCode ;\n\tcascade:absentReasonCode <https://ns.cascadeprotocol.org/codes/nullflavor/UNK> .\n<urn:uuid:794d1263-7742-8a95-850e-663e9a08ffe7> a cascade:PatientProfile ;\n\tcascade:sourceUrl <urn:hl7ii:2.16.840.1.113883.19.5.99999.2:MRN-552012> ;\n\tcascade:sourceRecordId \"2.16.840.1.113883.19.5.99999.2:MRN-552012\" .\n<ni:///sha-256;EVwdxLuG51G60_9c_XpCwjPNK7H2ZQcLTj262S_EZA8> prov:specializationOf <urn:uuid:794d1263-7742-8a95-850e-663e9a08ffe7> .\n_:daf098d5368429380934dedb5967edd6 a oa:XPathSelector ;\n\trdf:value \"/*[local-name()='ClinicalDocument' and namespace-uri()='urn:hl7-org:v3']/*[local-name()='recordTarget' and namespace-uri()='urn:hl7-org:v3'][1]/*[local-name()='patientRole' and namespace-uri()='urn:hl7-org:v3'][1]\" .\n_:6529dccb7161604e989942dffc07c5c5 bridge:arrivedAs <ni:///sha-256;EVwdxLuG51G60_9c_XpCwjPNK7H2ZQcLTj262S_EZA8> ;\n\toa:hasSelector _:daf098d5368429380934dedb5967edd6 .\n<urn:uuid:fc383492-aa4c-886b-b0bb-b81b02cace16> a cascade:MedicalProcedure ;\n\tcascade:sourceUrl <urn:hl7ii:2.16.840.1.113883.19.5.99999.5:PROC-2011> ;\n\tcascade:sourceRecordId \"2.16.840.1.113883.19.5.99999.5:PROC-2011\" .\n<ni:///sha-256;Cy3na1Z9vHKxSUZ0LTRh4lpec64mjdTdfUAEIvDDheQ> prov:specializationOf <urn:uuid:fc383492-aa4c-886b-b0bb-b81b02cace16> ;\n\tcascade:patient <urn:uuid:794d1263-7742-8a95-850e-663e9a08ffe7> .\n_:e3f1495f5594877e1a2dd7f479025d1b a oa:XPathSelector ;\n\trdf:value \"/*[local-name()='ClinicalDocument' and namespace-uri()='urn:hl7-org:v3']/*[local-name()='component' and namespace-uri()='urn:hl7-org:v3'][1]/*[local-name()='structuredBody' and namespace-uri()='urn:hl7-org:v3'][1]/*[local-name()='component' and namespace-uri()='urn:hl7-org:v3'][1]/*[local-name()='section' and namespace-uri()='urn:hl7-org:v3'][1]/*[local-name()='entry' and namespace-uri()='urn:hl7-org:v3'][1]/*[local-name()='procedure' and namespace-uri()='urn:hl7-org:v3'][1]\" .\n_:3971e3c8d3f621ecea2a369aea3edf98 bridge:arrivedAs <ni:///sha-256;Cy3na1Z9vHKxSUZ0LTRh4lpec64mjdTdfUAEIvDDheQ> ;\n\toa:hasSelector _:e3f1495f5594877e1a2dd7f479025d1b .\n_:b7f630de8656ce841e9687fdbba8bdf8 oa:hasSource <ni:///sha-256;HWUslDL762oNuBdJ51YHIB5aZYnsOsv0joC1DL6ZC_A> ;\n\tprov:wasDerivedFrom <ni:///sha-256;HWUslDL762oNuBdJ51YHIB5aZYnsOsv0joC1DL6ZC_A> ;\n\tprov:wasGeneratedBy _:af58d807dd5d173d1fbbdffbada81ee9 .\n_:6529dccb7161604e989942dffc07c5c5 oa:hasSource <ni:///sha-256;HWUslDL762oNuBdJ51YHIB5aZYnsOsv0joC1DL6ZC_A> ;\n\tprov:wasDerivedFrom <ni:///sha-256;HWUslDL762oNuBdJ51YHIB5aZYnsOsv0joC1DL6ZC_A> ;\n\tprov:wasGeneratedBy _:af58d807dd5d173d1fbbdffbada81ee9 .\n_:3971e3c8d3f621ecea2a369aea3edf98 oa:hasSource <ni:///sha-256;HWUslDL762oNuBdJ51YHIB5aZYnsOsv0joC1DL6ZC_A> ;\n\tprov:wasDerivedFrom <ni:///sha-256;HWUslDL762oNuBdJ51YHIB5aZYnsOsv0joC1DL6ZC_A> ;\n\tprov:wasGeneratedBy _:af58d807dd5d173d1fbbdffbada81ee9 .\n<ni:///sha-256;HWUslDL762oNuBdJ51YHIB5aZYnsOsv0joC1DL6ZC_A> <http://purl.org/pav/retrievedOn> \"2025-07-02T09:00:00Z\"^^xsd:dateTime ;\n\tprov:wasGeneratedBy _:84e8bd73d53984ef1c37ae7a3cfdde1f .\n_:9a385a6ae036ab1dafb4abbe3da66524 prov:agent _:faac360b4524c8c1c6744052c1be15f9 ;\n\tprov:hadRole cascade:TransmitterRole .\n_:84e8bd73d53984ef1c37ae7a3cfdde1f prov:qualifiedAssociation _:9a385a6ae036ab1dafb4abbe3da66524 .\n_:faac360b4524c8c1c6744052c1be15f9 <http://www.w3.org/2000/01/rdf-schema#label> \"Riverside patient portal\" .\n_:af58d807dd5d173d1fbbdffbada81ee9 <http://www.w3.org/2000/01/rdf-schema#label> \"C-CDA download\" ;\n\tprov:startedAtTime \"2025-07-02T09:00:04Z\"^^xsd:dateTime .\n<ni:///sha-256;HWUslDL762oNuBdJ51YHIB5aZYnsOsv0joC1DL6ZC_A> a prov:Entity .\n_:af58d807dd5d173d1fbbdffbada81ee9 a prov:Activity ;\n\tprov:used <ni:///sha-256;HWUslDL762oNuBdJ51YHIB5aZYnsOsv0joC1DL6ZC_A> ;\n\tprov:qualifiedAssociation _:1767421d05246931d7ad38bc13dc78f5 .\n_:1767421d05246931d7ad38bc13dc78f5 prov:hadPlan _:ad8e698d1d12af61e4481c35b78b59b0 .\n_:ad8e698d1d12af61e4481c35b78b59b0 a prov:Plan ;\n\t<http://www.w3.org/2000/01/rdf-schema#label> \"ccda\" ;\n\t<http://purl.org/pav/version> \"0.1.0\" .\n_:1767421d05246931d7ad38bc13dc78f5 prov:agent _:6bbd7a118374df386c52cee776dd19b3 .\n_:6bbd7a118374df386c52cee776dd19b3 a prov:SoftwareAgent ;\n\t<http://www.w3.org/2000/01/rdf-schema#label> \"Cascade Bridge for Rust\" ;\n\t<http://purl.org/pav/version> \"0.1.0\" .\n"}, "expectedFindings": {"file": "fixtures/findings/procedure-code-nullflavor-attribute.ttl", "link": "https://github.com/the-cascade-protocol/cascade-bridge-adapter-ccda/blob/0c6ffe52b3c3d2dcd0dfaf3f0b9e00b69bf2ba96/fixtures/findings/procedure-code-nullflavor-attribute.ttl", "text": "@prefix ccda: <https://ns.cascadeprotocol.org/adapter/ccda/v1-draft#> .\n@prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .\n@prefix sh: <http://www.w3.org/ns/shacl#> .\n@prefix oa: <http://www.w3.org/ns/oa#> .\n_:bf4da9b59c98e2b937423c65af81f20 a oa:XPathSelector ;\n\trdf:value \"/*[local-name()='ClinicalDocument' and namespace-uri()='urn:hl7-org:v3']\" .\n_:b87316e472359d4ef0858d58a75c300 a oa:XPathSelector ;\n\trdf:value \"*[local-name()='author' and namespace-uri()='urn:hl7-org:v3'][1]\" .\n_:bf4da9b59c98e2b937423c65af81f20 oa:refinedBy _:b87316e472359d4ef0858d58a75c300 .\n_:e44cce4beacdbe3f908d320c28cb21a1 a oa:Annotation ;\n\toa:hasTarget _:ccef4595dbea76f5528345963809d474 .\n_:ccef4595dbea76f5528345963809d474 oa:hasSource <../in/procedure-code-nullflavor-attribute.xml> ;\n\toa:hasSelector _:bf4da9b59c98e2b937423c65af81f20 .\n_:e44cce4beacdbe3f908d320c28cb21a1 oa:hasBody ccda:documentAuthor ;\n\toa:motivatedBy oa:classifying ;\n\tsh:value \"/*[local-name()='ClinicalDocument' and namespace-uri()='urn:hl7-org:v3']/*[local-name()='author' and namespace-uri()='urn:hl7-org:v3']\" ;\n\tsh:resultSeverity sh:Info .\n_:ca549da047466969e9e027f37bfaeeff a oa:XPathSelector ;\n\trdf:value \"/*[local-name()='ClinicalDocument' and namespace-uri()='urn:hl7-org:v3']\" .\n_:e173adcab5acd32551efe339a787f4db oa:hasSource <../in/procedure-code-nullflavor-attribute.xml> .\n_:ca549da047466969e9e027f37bfaeeff oa:refinedBy _:fb1b05c7ca3af755957b8515c9d88ba8 .\n_:fb1b05c7ca3af755957b8515c9d88ba8 a oa:XPathSelector ;\n\trdf:value \"*[local-name()='id' and namespace-uri()='urn:hl7-org:v3'][1]\" .\n_:e173adcab5acd32551efe339a787f4db oa:hasSelector _:ca549da047466969e9e027f37bfaeeff .\n_:da0cfa6699bbe6aab6230388811ec71d oa:hasTarget _:e173adcab5acd32551efe339a787f4db .\n_:a7291aed63307a643f947897c74b3d8c a oa:XPathSelector ;\n\trdf:value \"/*[local-name()='ClinicalDocument' and namespace-uri()='urn:hl7-org:v3']\" .\n_:e8f545627b97b4376945101bbfe4b838 oa:hasSource <../in/procedure-code-nullflavor-attribute.xml> .\n_:a7291aed63307a643f947897c74b3d8c oa:refinedBy _:a382af2dad1c6ffcf044dabacf9903ea .\n_:a382af2dad1c6ffcf044dabacf9903ea a oa:XPathSelector ;\n\trdf:value \"*[local-name()='code' and namespace-uri()='urn:hl7-org:v3'][1]\" .\n_:e8f545627b97b4376945101bbfe4b838 oa:hasSelector _:a7291aed63307a643f947897c74b3d8c .\n_:a5a7c52c22420a0a3109f90ba1092208 oa:hasTarget _:e8f545627b97b4376945101bbfe4b838 .\n_:ef76db158de120dceb17d62c5d12356d a oa:XPathSelector ;\n\trdf:value \"/*[local-name()='ClinicalDocument' and namespace-uri()='urn:hl7-org:v3']\" .\n_:a6c73558340e4167e3e24f843c5888b3 oa:hasSource <../in/procedure-code-nullflavor-attribute.xml> .\n_:ef76db158de120dceb17d62c5d12356d oa:refinedBy _:f75cf3ae938a2df0e481fc6890f8aa1 .\n_:f75cf3ae938a2df0e481fc6890f8aa1 a oa:XPathSelector ;\n\trdf:value \"*[local-name()='effectiveTime' and namespace-uri()='urn:hl7-org:v3'][1]\" .\n_:a6c73558340e4167e3e24f843c5888b3 oa:hasSelector _:ef76db158de120dceb17d62c5d12356d .\n_:f7fb99b3f4f9df94f0ca309f99ab2e02 oa:hasTarget _:a6c73558340e4167e3e24f843c5888b3 .\n_:da0cfa6699bbe6aab6230388811ec71d sh:resultSeverity sh:Info .\n_:a5a7c52c22420a0a3109f90ba1092208 sh:resultSeverity sh:Info .\n_:f7fb99b3f4f9df94f0ca309f99ab2e02 sh:resultSeverity sh:Info .\n_:da0cfa6699bbe6aab6230388811ec71d a oa:Annotation ;\n\toa:hasBody ccda:documentId ;\n\toa:motivatedBy oa:classifying ;\n\tsh:value \"2.16.840.1.113883.19.5.99999.1|CCD-2026-1029-R\" .\n_:a5a7c52c22420a0a3109f90ba1092208 a oa:Annotation ;\n\toa:hasBody ccda:documentType ;\n\toa:motivatedBy oa:classifying ;\n\tsh:value \"34133-9\" .\n_:f7fb99b3f4f9df94f0ca309f99ab2e02 a oa:Annotation ;\n\toa:hasBody ccda:documentTime ;\n\toa:motivatedBy oa:classifying ;\n\tsh:value \"20261029090000-0500\" .\n", "empty": false}}