mirror of
https://github.com/IfcOpenShell/IfcOpenShell.git
synced 2026-08-19 11:43:53 +00:00
For the love of god, add support for selected enumerations
This commit is contained in:
@@ -0,0 +1,10 @@
|
||||
ISO-10303-21;
|
||||
HEADER;
|
||||
FILE_DESCRIPTION(('ViewDefinition [CoordinationView]'),'2;1');
|
||||
FILE_NAME('','2023-04-13T10:27:43',(),(),'IfcOpenShell v0.7.0-198fa67cc','IfcOpenShell v0.7.0-198fa67cc','');
|
||||
FILE_SCHEMA(('IFC4'));
|
||||
ENDSEC;
|
||||
DATA;
|
||||
#1=IFCPROPERTYSINGLEVALUE('Test',$,IFCCOMPLEXNUMBER((0.,0.)),$);
|
||||
ENDSEC;
|
||||
END-ISO-10303-21;
|
||||
@@ -182,9 +182,13 @@ namespace {
|
||||
|
||||
IfcEntityInstanceData IfcParse::parse_context::construct(int name, unresolved_references& references_to_resolve, const IfcParse::declaration* decl, boost::optional<size_t> expected_size) {
|
||||
std::vector<const IfcParse::parameter_type*> parameter_types;
|
||||
std::unique_ptr<IfcParse::named_type> transient_named_type;
|
||||
|
||||
if ((decl != nullptr) && (decl->as_type_declaration() != nullptr)) {
|
||||
parameter_types = { decl->as_type_declaration()->declared_type() };
|
||||
} else if ((decl != nullptr) && (decl->as_enumeration_type() != nullptr)) {
|
||||
transient_named_type.reset(new IfcParse::named_type(const_cast<IfcParse::declaration*>(decl)));
|
||||
parameter_types = { &*transient_named_type };
|
||||
} else if ((decl != nullptr) && (decl->as_entity() != nullptr)) {
|
||||
auto entity_attrs = decl->as_entity()->all_attributes();
|
||||
std::transform(
|
||||
|
||||
Reference in New Issue
Block a user