Module: OpenEHR::Parser::XMLConstraintParsing

Included in:
OPTParser, XMLArchetypeParser
Defined in:
lib/openehr/parser/xml_constraint_parsing.rb

Overview

Structural/constraint-tree node builders (C_COMPLEX_OBJECT, C_ATTRIBUTE, C_PRIMITIVE_OBJECT, ARCHETYPE_SLOT, ARCHETYPE_INTERNAL_REF, CONSTRAINT_REF, ASSERTION) shared between OPTParser and XMLArchetypeParser - both read the same canonical shape (see lib/openehr/serializer/xml_serializer.rb's header comment for how that shape was established as ground truth against real .opt fixtures). Extracted from opt_parser.rb without behavior changes, except: expr_unary_operator support and tag reading in assertions() were both added here since XMLSerializer already emits them, and occurrences()/numeric bounds are now real-aware where the caller asks for it (C_REAL ranges were silently truncated to Integer via String#to_i before this).