Expand description
XML → TypeObject Bridge (Cluster C4.5-b).
Converts the internal XML data model from [xtypes_def] into the
XTypes-1.3 TypeObject format from zerodds-types. Wire-/hash-compatible
with the IDL lowering from zerodds-idl::semantics::to_typeobject.
§Spec sources
- OMG XTypes 1.3 §7.3.4.x — TypeObject + Minimal/Complete variants.
- OMG XTypes 1.3 §7.3.4.5 — MinimalStructType / EnumType / UnionType.
- OMG XTypes 1.3 Annex A — XML mapping.
§Scope C4.5-b (this stage)
MinimalTypeObjectonly.CompleteTypeObjectnot implemented.- Top-level mapping (struct, enum, union, typedef, bitmask, bitset).
- Member types via
TypeRef::Primitive(direct) orTypeRef::Named(lookup inTypeLibrarywith hash precomputation). - The modifiers
arrayDimensions/sequenceMaxLength/stringMaxLengthwrap the member TypeIdentifier in PlainArray-/PlainSequence-/ string-bound variants. - Member IDs:
@idfrom XSD if set, otherwise sequential from 1 (AUTOID_SEQUENTIAL, Spec §7.3.1.2.1.1). - Extensibility: map
final/appendable/mutablefromExtensibilityontoStructTypeFlag/UnionTypeFlag.
§Deliberately not in the crate
CompleteTypeObject(comes in phase 6).- Forward declarations / cross-library refs.
- Inheritance via
baseType— the bridge does setbase_typeasEquivalenceHashMinimal, but cycle detection remains the task of the existingcrate::inheritancemodule. @autoid(HASH)— XML schema has no corresponding annotation.
Enums§
- Bridge
Error - Error during the XML→TypeObject mapping.
Functions§
- bridge_
library - Converts a whole
TypeLibraryinto a mapName → MinimalTypeObject. Named refs between types within the library are resolved in a two-stage pass: - xml_
type_ to_ minimal_ typeobject - Like
xml_type_to_typeobject, but directly as aMinimalTypeObject(without the discriminator wrapper). - xml_
type_ to_ typeobject - Converts a single XmlType-
TypeDefinto aTypeObject(minimal variant).