MCPcopy Create free account
hub / github.com/IfcOpenShell/IfcOpenShell / follow_named

Function follow_named

src/ifcparse/parse_ifcxml.cpp:74–82  ·  view source on GitHub ↗

"Dereferences" a named_attribute. For example: IfcCompoundPlaneAngleMeasure -> LIST [3:4] OF INTEGER

Source from the content-addressed store, hash-verified

72// "Dereferences" a named_attribute. For example:
73// IfcCompoundPlaneAngleMeasure -> LIST [3:4] OF INTEGER
74void follow_named(const IfcParse::parameter_type*& pt) {
75 while (pt->as_named_type() != nullptr) {
76 if (pt->as_named_type()->declared_type()->as_type_declaration() != nullptr) {
77 pt = pt->as_named_type()->declared_type()->as_type_declaration()->declared_type();
78 } else {
79 break;
80 }
81 }
82}
83
84// The ifcXML parser uses SAX so we need to keep a stack of where we are in
85// the file. These different kinds of nodes could be subclasses but aren't

Callers 1

start_elementFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected