Expand description
XTypes 1.3 Annex A — XSD schema loader for <types> XML (C4.5).
Spec OMG XTypes 1.3 §7.3.2 + §7.3.3 + Annex A: an XML type document
(Annex-A schema) MUST be ingestible at runtime by a URI-capable loader.
This is a precondition for create_type_w_uri and
create_type_w_document (DynamicType API, comes with C4.1).
§Scope C4.5 (this stage)
- URI loader:
file://,data:(RFC 2397), inline bytes viaload_type_libraries_from_string. - Structural XSD-Annex-A validation: checks the element/ attribute names + required attributes per type construct. A full XSD 1.1 engine (XPath, Schematron) is not implemented.
- Spec namespace check:
http://www.omg.org/spec/DDS-XMLas thetargetNamespace. Strict mode rejects a missing namespace. - Reuse C7.D: returns
Vec<TypeLibrary>(XML data model fromxtypes_def); the TypeObject bridge is a future extension (C4.5-b after C4.1).
§Deliberately not in the crate
- A full XSD-1.1 validator (XPath, key/keyref, assertions).
- HTTP/HTTPS URI schemes — only
file://+data:. - XML catalog resolution.
Enums§
- Validation
Mode - Strict vs lax validation mode.
Constants§
- DDS_
XML_ NAMESPACE - Spec namespace for DDS-XML (XTypes Annex A + DDS-XML 1.0 §7.1.5).
- MAX_
DATA_ URI_ BODY - Maximum
data:body (DoS cap, 1 MiB). - MAX_
FILE_ BYTES - Maximum
file://file size (DoS cap, 16 MiB).
Functions§
- load_
type_ libraries_ from_ string - Loads XML type libraries directly from an inline string.
- load_
type_ libraries_ from_ uri - Loads XML type libraries from a URI.