Function: codingSystemOf()
codingSystemOf(
coded):CodingSystemInfo|undefined
Provenance of a coded element's primary coding system (CWE.3 / CE.3).
Returns undefined when the element claims no primary system.
Parameters
coded
Returns
CodingSystemInfo | undefined
Example
import { parseHL7, codingSystemOf } from "@cosyte/hl7";
const msg = parseHL7(raw);
for (const dg of msg.diagnoses()) {
const sys = dg.code && codingSystemOf(dg.code);
console.log(dg.code?.identifier, sys?.name ?? sys?.claimed ?? "(no system)");
}