pub struct QNameAtom {
pub local_name: NameId,
pub namespace_uri: NameId,
pub prefix: NameId,
pub local_name_hash: u32,
pub qualified_name_idx: u32,
}Expand description
Atomized qualified name — 20 bytes, Copy.
Equality compares local_name, namespace_uri, prefix, and
local_name_hash. The qualified_name_idx field is excluded from
equality because it is a per-document StringStore index whose value
may differ across occurrences even though the string content is identical
(StringStore does not deduplicate). Since the qualified name is fully
determined by prefix + local_name, comparing those is sufficient.
The Hash trait implementation hashes only local_name and
namespace_uri because XML namespace identity ignores the prefix.
This means two atoms that differ only in prefix will hash to the same
bucket but will not compare as equal, so QNameTable::atomize will
store them as separate entries — which is the desired semantics (the
navigator needs to report the original prefix).
Fields§
§local_name: NameId§namespace_uri: NameId§prefix: NameId§local_name_hash: u32§qualified_name_idx: u32Index into the per-document StringStore (not NameTable).
Excluded from PartialEq / hash_atom — see struct doc.