[#BloombergLP-balxml-NamespaceRegistry-lookup-0c] = xref:BloombergLP.adoc[BloombergLP]::xref:BloombergLP/balxml.adoc[balxml]::xref:BloombergLP/balxml/NamespaceRegistry.adoc[NamespaceRegistry]::lookup :relfileprefix: ../../../ :mrdocs: Return the integer ID for the specified `namespaceUri`, or ‐1 if it is unregistered. == Synopsis Declared in `<balxml_namespaceregistry.h>` [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- int lookup(std::string_view const& namespaceUri) const; ---- == Description Note that not all negative return values correspond to unregistered namespaces. Preregistered namespaces always have negative IDs. (See "Preregistered Namespaces" in the `balxml_namespaceregistry` component‐level documentation.) Note that a return value of ‐1 can mean either an unregistered namespace or an empty URI string. This dual‐use of ‐1 is deliberate and simplifies error handling in most clients. == Return Value the integer ID for `namespaceUri`, or ‐1 if unregistered == Parameters [cols="1,4"] |=== | Name| Description | *namespaceUri* | namespace URI to look up |=== [.small]#Created with https://www.mrdocs.com[MrDocs]#