Skip to main content
Version: v0.0.3

Function: isRecognizedNamespace()

isRecognizedNamespace(namespaceUri): boolean

Return true when a namespace URI is one the parser recognizes (urn:hl7-org:v3, the XSI namespace, or urn:hl7-org:sdtc). A null URI, an element with no namespace at all, counts as unrecognized.

Parameters

namespaceUri

string | null

Returns

boolean

Example

import { isRecognizedNamespace, V3_NS } from "@cosyte/ccda";
isRecognizedNamespace(V3_NS); // true
isRecognizedNamespace("urn:vendor"); // false
isRecognizedNamespace(null); // false