Merge branch 'master' into performance_improvements

# Conflicts:
#	src/ifcexpressparser/implementation.py
#	src/ifcgeom/IfcGeomFunctions.cpp
#	src/ifcparse/Ifc4.cpp
This commit is contained in:
Thomas Krijnen
2016-04-24 15:22:10 +02:00
32 changed files with 1271 additions and 371 deletions
+2 -2
View File
@@ -59,7 +59,7 @@ IF(MSVC)
SET(Boost_USE_STATIC_RUNTIME ON) SET(Boost_USE_STATIC_RUNTIME ON)
SET(Boost_USE_MULTITHREADED ON) SET(Boost_USE_MULTITHREADED ON)
ENDIF() ENDIF()
FIND_PACKAGE(Boost REQUIRED COMPONENTS program_options) FIND_PACKAGE(Boost REQUIRED COMPONENTS system program_options regex thread date_time)
MESSAGE(STATUS "Boost include files found in ${Boost_INCLUDE_DIRS}") MESSAGE(STATUS "Boost include files found in ${Boost_INCLUDE_DIRS}")
MESSAGE(STATUS "Boost libraries found in ${Boost_LIBRARY_DIRS}") MESSAGE(STATUS "Boost libraries found in ${Boost_LIBRARY_DIRS}")
@@ -378,7 +378,7 @@ set(IFCPARSE_FILES ${IFCPARSE_CPP_FILES} ${IFCPARSE_H_FILES})
ADD_LIBRARY(IfcParse STATIC ${IFCPARSE_FILES}) ADD_LIBRARY(IfcParse STATIC ${IFCPARSE_FILES})
IF(UNICODE_SUPPORT) IF(UNICODE_SUPPORT)
TARGET_LINK_LIBRARIES(IfcParse ${ICU_LIBRARIES}) TARGET_LINK_LIBRARIES(IfcParse ${ICU_LIBRARIES} ${Boost_LIBRARIES})
ENDIF() ENDIF()
# IfcGeom # IfcGeom
+4 -4
View File
@@ -37,7 +37,7 @@ set -e
PROJECT_NAME=IfcOpenShell PROJECT_NAME=IfcOpenShell
OCE_VERSION=0.16 OCE_VERSION=0.16
PYTHON_VERSIONS=(2.7.10 3.2.6 3.3.6 3.4.4 3.5.1) PYTHON_VERSIONS=(2.7.10 3.2.6 3.3.6 3.4.4 3.5.1)
BOOST_VERSION=1.55.0 BOOST_VERSION=1.59.0
PCRE_VERSION=8.38 PCRE_VERSION=8.38
LIBXML_VERSION=2.9.3 LIBXML_VERSION=2.9.3
CMAKE_VERSION=3.4.1 CMAKE_VERSION=3.4.1
@@ -277,14 +277,14 @@ build_dependency pcre-$PCRE_VERSION autoconf "--disable-shared" ftp://ftp.csx.ca
build_dependency swig autoconf "--with-pcre-prefix=$DEPS_DIR/install/pcre-$PCRE_VERSION" https://github.com/swig/swig.git swig git_clone rel-3.0.8 build_dependency swig autoconf "--with-pcre-prefix=$DEPS_DIR/install/pcre-$PCRE_VERSION" https://github.com/swig/swig.git swig git_clone rel-3.0.8
build_dependency oce-$OCE_VERSION cmake "-DOCE_DISABLE_TKSERVICE_FONT=ON -DOCE_TESTING=OFF -DOCE_BUILD_SHARED_LIB=OFF -DOCE_DISABLE_X11=ON -DOCE_VISUALISATION=OFF -DOCE_OCAF=OFF -DOCE_INSTALL_PREFIX=$DEPS_DIR/install/oce-$OCE_VERSION/" https://github.com/tpaviot/oce/archive/ OCE-$OCE_VERSION.tar.gz download build_dependency oce-$OCE_VERSION cmake "-DOCE_DISABLE_TKSERVICE_FONT=ON -DOCE_TESTING=OFF -DOCE_BUILD_SHARED_LIB=OFF -DOCE_DISABLE_X11=ON -DOCE_VISUALISATION=OFF -DOCE_OCAF=OFF -DOCE_INSTALL_PREFIX=$DEPS_DIR/install/oce-$OCE_VERSION/" https://github.com/tpaviot/oce/archive/ OCE-$OCE_VERSION.tar.gz download
build_dependency libxml2-$LIBXML_VERSION autoconf "--without-python --disable-shared --without-zlib --without-iconv" ftp://xmlsoft.org/libxml2/ libxml2-$LIBXML_VERSION.tar.gz download build_dependency libxml2-$LIBXML_VERSION autoconf "--without-python --disable-shared --without-zlib --without-iconv --without-lzma" ftp://xmlsoft.org/libxml2/ libxml2-$LIBXML_VERSION.tar.gz download
build_dependency OpenCOLLADA cmake " build_dependency OpenCOLLADA cmake "
-DLIBXML2_INCLUDE_DIR=$DEPS_DIR/install/libxml2-$LIBXML_VERSION/include/libxml2 -DLIBXML2_INCLUDE_DIR=$DEPS_DIR/install/libxml2-$LIBXML_VERSION/include/libxml2
-DLIBXML2_LIBRARIES=$DEPS_DIR/install/libxml2-$LIBXML_VERSION/lib/libxml2.a -DLIBXML2_LIBRARIES=$DEPS_DIR/install/libxml2-$LIBXML_VERSION/lib/libxml2.a
-DPCRE_INCLUDE_DIR=$DEPS_DIR/install/pcre-$PCRE_VERSION/include -DPCRE_INCLUDE_DIR=$DEPS_DIR/install/pcre-$PCRE_VERSION/include
-DPCRE_PCREPOSIX_LIBRARY=$DEPS_DIR/install/pcre-$PCRE_VERSION/lib/libpcreposix.a -DPCRE_PCREPOSIX_LIBRARY=$DEPS_DIR/install/pcre-$PCRE_VERSION/lib/libpcreposix.a
-DPCRE_PCRE_LIBRARY=$DEPS_DIR/install/pcre-$PCRE_VERSION/lib/libpcre.a -DPCRE_PCRE_LIBRARY=$DEPS_DIR/install/pcre-$PCRE_VERSION/lib/libpcre.a
-DCMAKE_INSTALL_PREFIX=$DEPS_DIR/install/OpenCOLLADA/" https://github.com/KhronosGroup/OpenCOLLADA.git OpenCOLLADA git_clone -DCMAKE_INSTALL_PREFIX=$DEPS_DIR/install/OpenCOLLADA/" https://github.com/KhronosGroup/OpenCOLLADA.git OpenCOLLADA git_clone $OPENCOLLADA_COMMIT
# Python should not be built with -fvisibility=hidden, from experience that introduces segfaults # Python should not be built with -fvisibility=hidden, from experience that introduces segfaults
@@ -306,7 +306,7 @@ done
export CXXFLAGS=$OLD_CXX_FLAGS export CXXFLAGS=$OLD_CXX_FLAGS
export CFLAGS=$OLD_C_FLAGS export CFLAGS=$OLD_C_FLAGS
build_dependency boost-$BOOST_VERSION bjam "--stagedir=$DEPS_DIR/install/boost-$BOOST_VERSION --with-program_options link=static $BOOST_ADDRESS_MODEL cxxflags=\"$CXXFLAGS\" linkflags=\"$LDFLAGS\" stage" http://downloads.sourceforge.net/project/boost/boost/$BOOST_VERSION/ boost_$BOOST_VERSION_UNDERSCORE.tar.bz2 download build_dependency boost-$BOOST_VERSION bjam "--stagedir=$DEPS_DIR/install/boost-$BOOST_VERSION --with-system --with-program_options --with-regex --with-thread --with-date_time link=static $BOOST_ADDRESS_MODEL cxxflags=\"$CXXFLAGS\" linkflags=\"$LDFLAGS\" stage" http://downloads.sourceforge.net/project/boost/boost/$BOOST_VERSION/ boost_$BOOST_VERSION_UNDERSCORE.tar.bz2 download
build_dependency icu-$ICU_VERSION icu "--enable-static --disable-shared" http://download.icu-project.org/files/icu4c/$ICU_VERSION/ icu4c-${ICU_VERSION_UNDERSCORE}-src.tgz download build_dependency icu-$ICU_VERSION icu "--enable-static --disable-shared" http://download.icu-project.org/files/icu4c/$ICU_VERSION/ icu4c-${ICU_VERSION_UNDERSCORE}-src.tgz download
+9 -9
View File
@@ -378,12 +378,13 @@ int main(int argc, char** argv) {
GeometrySerializer* serializer; GeometrySerializer* serializer;
if (output_extension == ".obj") { if (output_extension == ".obj") {
const std::string mtl_temp_filename = change_extension(output_filename, "mtl") + TEMP_FILE_EXTENSION; // Do not use temp file for MTL as it's such a small file.
const std::string mtl_filename = change_extension(output_filename, "mtl");
if (!use_world_coords) { if (!use_world_coords) {
Logger::Message(Logger::LOG_NOTICE, "Using world coords when writing WaveFront OBJ files"); Logger::Message(Logger::LOG_NOTICE, "Using world coords when writing WaveFront OBJ files");
settings.set(IfcGeom::IteratorSettings::USE_WORLD_COORDS, true); settings.set(IfcGeom::IteratorSettings::USE_WORLD_COORDS, true);
} }
serializer = new WaveFrontOBJSerializer(output_temp_filename, mtl_temp_filename, settings); serializer = new WaveFrontOBJSerializer(output_temp_filename, mtl_filename, settings);
#ifdef WITH_OPENCOLLADA #ifdef WITH_OPENCOLLADA
} else if (output_extension == ".dae") { } else if (output_extension == ".dae") {
serializer = new ColladaSerializer(output_temp_filename, settings); serializer = new ColladaSerializer(output_temp_filename, settings);
@@ -506,12 +507,11 @@ int main(int argc, char** argv) {
serializer->finalize(); serializer->finalize();
delete serializer; delete serializer;
rename_file(output_temp_filename, output_filename); // Renaming might fail (e.g. maybe the existing file was open in a viewer application)
// Do not remove the temp file as user can salvage the conversion result from it.
if (output_extension == ".obj") { bool successful = rename_file(output_temp_filename, output_filename);
std::string mtl_filename = change_extension(output_filename, "mtl"); if (!successful) {
std::string mtl_tmp_filename = mtl_filename + TEMP_FILE_EXTENSION; Logger::Message(Logger::LOG_ERROR, "Unable to write output file '" + output_filename + "");
rename_file(mtl_tmp_filename, mtl_filename);
} }
write_log(); write_log();
@@ -535,7 +535,7 @@ int main(int argc, char** argv) {
} }
Logger::Status(msg.str()); Logger::Status(msg.str());
return 0; return successful ? 0 : 1;
} }
void write_log() { void write_log() {
+23 -11
View File
@@ -19,8 +19,14 @@
import sys import sys
import string import string
import operator
import itertools
from pyparsing import * from pyparsing import *
try: from functools import reduce
except: pass
class Expression: class Expression:
def __init__(self, contents): def __init__(self, contents):
self.contents = contents[0] self.contents = contents[0]
@@ -56,12 +62,12 @@ class Keyword:
class Terminal: class Terminal:
def __init__(self, contents): def __init__(self, contents):
self.contents = contents[0] self.contents = contents[0]
def __repr__(self):
s = self.contents s = self.contents
is_keyword = len(s) >= 4 and s[0::len(s)-1] == '""' and \ self.is_keyword = len(s) >= 4 and s[0::len(s)-1] == '""' and \
all(c in alphanums+"_" for c in s[1:-1]) all(c in alphanums+"_" for c in s[1:-1])
ty = "CaselessKeyword" if is_keyword else "CaselessLiteral" def __repr__(self):
return "%s(%s)" % (ty, s) ty = "CaselessKeyword" if self.is_keyword else "CaselessLiteral"
return "%s(%s)" % (ty, self.contents)
LPAREN = Suppress("(") LPAREN = Suppress("(")
@@ -94,16 +100,16 @@ grammar.ignore(HASH + restOfLine)
express = grammar.parseFile(sys.argv[1]) express = grammar.parseFile(sys.argv[1])
def find_keywords(expr, li = None): def find_bytype(expr, ty, li = None):
if li is None: li = [] if li is None: li = []
if isinstance(expr, Term): if isinstance(expr, Term):
expr = expr.contents expr = expr.contents
if isinstance(expr, Keyword): if isinstance(expr, ty):
li.append(repr(expr)) li.append(expr)
return li return set(li)
elif isinstance(expr, Expression): elif isinstance(expr, Expression):
for term in expr: for term in expr:
find_keywords(term, li) find_bytype(term, ty, li)
return set(li) return set(li)
actions = { actions = {
@@ -122,6 +128,8 @@ actions = {
'inverse_attr' : "lambda t: InverseAttribute(t)", 'inverse_attr' : "lambda t: InverseAttribute(t)",
'bound_spec' : "lambda t: BoundSpecification(t)", 'bound_spec' : "lambda t: BoundSpecification(t)",
'explicit_attr' : "lambda t: ExplicitAttribute(t)", 'explicit_attr' : "lambda t: ExplicitAttribute(t)",
'width_spec' : "lambda t: WidthSpec(t)",
'string_type' : "lambda t: StringType(t)",
} }
to_emit = set(id for id, expr in express) to_emit = set(id for id, expr in express)
@@ -130,17 +138,21 @@ to_combine = set(["simple_id"])
to_ignore = set(["where_clause", "supertype_constraint", "unique_clause"]) to_ignore = set(["where_clause", "supertype_constraint", "unique_clause"])
statements = [] statements = []
terminals = reduce(lambda x,y: x | y, (find_bytype(e, Terminal) for id, e in express))
keywords = list(filter(operator.attrgetter('is_keyword'), terminals))
negated_keywords = map(lambda s: "~%s" % s, keywords)
while True: while True:
emitted_in_loop = set() emitted_in_loop = set()
for id, expr in express: for id, expr in express:
kws = find_keywords(expr) kws = map(repr, find_bytype(expr, Keyword))
found = [k in emitted for k in kws] found = [k in emitted for k in kws]
if id in to_emit and all(found): if id in to_emit and all(found):
emitted_in_loop.add(id) emitted_in_loop.add(id)
emitted.add(id) emitted.add(id)
stmt = "(%s)" % expr stmt = "(%s)" % expr
if id in to_combine: if id in to_combine:
stmt = "originalTextFor(Combine%s)" % stmt stmt = " + ".join(itertools.chain(negated_keywords, ("originalTextFor(Combine%s)" % stmt,)))
if id in actions: if id in actions:
stmt = "%s.setParseAction(%s)" % (stmt, actions[id]) stmt = "%s.setParseAction(%s)" % (stmt, actions[id])
statements.append("%s = %s" % (id, stmt)) statements.append("%s = %s" % (id, stmt))
+4 -2
View File
@@ -31,12 +31,14 @@ import re
import os import os
import csv import csv
from schema import OrderedCaseInsensitiveDict
try: from html.entities import entitydefs try: from html.entities import entitydefs
except: from htmlentitydefs import entitydefs except: from htmlentitydefs import entitydefs
make_absolute = lambda fn: os.path.join(os.path.dirname(os.path.realpath(__file__)), fn) make_absolute = lambda fn: os.path.join(os.path.dirname(os.path.realpath(__file__)), fn)
name_to_oid = {} name_to_oid = OrderedCaseInsensitiveDict()
oid_to_desc = {} oid_to_desc = {}
oid_to_name = {} oid_to_name = {}
oid_to_pid = {} oid_to_pid = {}
@@ -59,7 +61,7 @@ with open(make_absolute('DocAttribute.csv')) as f:
for oid, name, desc in csv.reader(f, delimiter=';', quotechar='"'): for oid, name, desc in csv.reader(f, delimiter=';', quotechar='"'):
pid = oid_to_pid[oid] pid = oid_to_pid[oid]
pname = oid_to_name[pid] pname = oid_to_name[pid]
name_to_oid[(pname, name)] = oid name_to_oid[".".join((pname, name))] = oid
oid_to_desc[oid] = desc oid_to_desc[oid] = desc
def description(item): def description(item):
+2 -4
View File
@@ -1,5 +1,3 @@
# Taken from http://sourceforge.net/p/exp-engine/expresso/ci/master/tree/docs/iso-10303-11--2004.bnf
ABS = "abs" . ABS = "abs" .
ABSTRACT = "abstract" . ABSTRACT = "abstract" .
ACOS = "acos" . ACOS = "acos" .
@@ -202,7 +200,7 @@ constructed_types = enumeration_type | select_type .
declaration = entity_decl | function_decl | procedure_decl | subtype_constraint_decl | type_decl . declaration = entity_decl | function_decl | procedure_decl | subtype_constraint_decl | type_decl .
derived_attr = attribute_decl ":" parameter_type ":=" expression ";" . derived_attr = attribute_decl ":" parameter_type ":=" expression ";" .
derive_clause = DERIVE derived_attr { derived_attr } . derive_clause = DERIVE derived_attr { derived_attr } .
domain_rule = rule_label_id ":" expression . domain_rule = [ rule_label_id ":" ] expression .
element = expression [ ":" repetition ] . element = expression [ ":" repetition ] .
entity_body = { explicit_attr } [ derive_clause ] [ inverse_clause ] [ unique_clause ] [ where_clause ] . entity_body = { explicit_attr } [ derive_clause ] [ inverse_clause ] [ unique_clause ] [ where_clause ] .
entity_constructor = entity_ref "(" [ expression { "," expression } ] ")" . entity_constructor = entity_ref "(" [ expression { "," expression } ] ")" .
@@ -334,7 +332,7 @@ type_label_id = simple_id .
unary_op = "+" | "-" | NOT . unary_op = "+" | "-" | NOT .
underlying_type = constructed_types | concrete_types . underlying_type = constructed_types | concrete_types .
unique_clause = UNIQUE unique_rule ";" { unique_rule ";" } . unique_clause = UNIQUE unique_rule ";" { unique_rule ";" } .
unique_rule = rule_label_id ":" referenced_attribute { "," referenced_attribute } . unique_rule = [ rule_label_id ":" ] referenced_attribute { "," referenced_attribute } .
until_control = UNTIL logical_expression . until_control = UNTIL logical_expression .
use_clause = USE FROM schema_ref [ "(" named_type_or_rename { "," named_type_or_rename } ")" ] ";" . use_clause = USE FROM schema_ref [ "(" named_type_or_rename { "," named_type_or_rename } ")" ] ";" .
variable_id = simple_id . variable_id = simple_id .
+14 -7
View File
@@ -41,15 +41,18 @@ class Header(codegen.Base):
emitted_simpletypes = set() emitted_simpletypes = set()
while len(emitted_simpletypes) < len(mapping.schema.simpletypes): while len(emitted_simpletypes) < len(mapping.schema.simpletypes):
for name, type in mapping.schema.simpletypes.items(): for name, type in mapping.schema.simpletypes.items():
if name in emitted_simpletypes: continue if name.lower() in emitted_simpletypes: continue
type_str = mapping.make_type_string(mapping.flatten_type_string(type)) type_str = mapping.make_type_string(mapping.flatten_type_string(type))
attr_type = mapping.make_argument_type(type) attr_type = mapping.make_argument_type(type)
superclass = mapping.simple_type_parent(name) superclass = mapping.simple_type_parent(name)
if superclass is None: if superclass is None:
superclass = "IfcUtil::IfcBaseType" superclass = "IfcUtil::IfcBaseType"
elif superclass not in emitted_simpletypes: elif superclass.lower() not in emitted_simpletypes:
continue continue
emitted_simpletypes.add(name) else:
# Case normalize
superclass = [k for k in mapping.schema.simpletypes.keys() if k.lower() == superclass.lower()][0]
emitted_simpletypes.add(name.lower())
write(templates.simpletype, name=name, type=type_str, attr_type=attr_type, superclass=superclass) write(templates.simpletype, name=name, type=type_str, attr_type=attr_type, superclass=superclass)
class_definitions = [] class_definitions = []
@@ -60,14 +63,14 @@ class Header(codegen.Base):
emitted_entities = set() emitted_entities = set()
while len(emitted_entities) < len(mapping.schema.entities): while len(emitted_entities) < len(mapping.schema.entities):
for name, type in mapping.schema.entities.items(): for name, type in mapping.schema.entities.items():
if name in emitted_entities: continue if name.lower() in emitted_entities: continue
if len(type.supertypes) == 0 or set(type.supertypes) < emitted_entities: if len(type.supertypes) == 0 or set(map(str.lower, type.supertypes)) <= emitted_entities:
attr_lines = [] attr_lines = []
def write_method(attr): def write_method(attr):
if attr.optional: if attr.optional:
attr_lines.append(templates.optional_attribute_description % (attr.name, name)) attr_lines.append(templates.optional_attribute_description % (attr.name, name))
attr_lines.append("bool has%s() const;"%(attr.name)) attr_lines.append("bool has%s() const;"%(attr.name))
attr_lines.extend(["/// %s"%d for d in documentation.description((name, attr.name))]) attr_lines.extend(["/// %s"%d for d in documentation.description(".".join((name, attr.name)))])
type_str = mapping.get_parameter_type(attr, allow_optional=False, allow_entities=False) type_str = mapping.get_parameter_type(attr, allow_optional=False, allow_entities=False)
if mapping.make_argument_type(attr) != "IfcUtil::Argument_UNKNOWN": if mapping.make_argument_type(attr) != "IfcUtil::Argument_UNKNOWN":
attr_lines.append("%s %s() const;"%(type_str, attr.name)) attr_lines.append("%s %s() const;"%(type_str, attr.name))
@@ -88,7 +91,11 @@ class Header(codegen.Base):
inverse = "\n".join(["%s%s"%(' '*4, a) for a in inv_lines]) inverse = "\n".join(["%s%s"%(' '*4, a) for a in inv_lines])
if len(inverse): inverse += '\n' if len(inverse): inverse += '\n'
supertypes = type.supertypes if len(type.supertypes) else ['IfcUtil::IfcBaseEntity'] def case_norm(n):
n = n.lower()
return [k for k in mapping.schema.entities.keys() if k.lower() == n][0]
supertypes = map(case_norm, type.supertypes) if len(type.supertypes) else ['IfcUtil::IfcBaseEntity']
superclass = ": %s "%(", ".join(["public %s"%c for c in supertypes])) superclass = ": %s "%(", ".join(["public %s"%c for c in supertypes]))
argument_count = mapping.argument_count(type) argument_count = mapping.argument_count(type)
+5 -3
View File
@@ -20,6 +20,8 @@
import codegen import codegen
import templates import templates
from schema import OrderedCaseInsensitiveDict
class Implementation(codegen.Base): class Implementation(codegen.Base):
def __init__(self, mapping): def __init__(self, mapping):
enumeration_functions = [] enumeration_functions = []
@@ -132,7 +134,7 @@ class Implementation(codegen.Base):
def get_attribute_index(entity, attr_name): def get_attribute_index(entity, attr_name):
related_entity = mapping.schema.entities[entity] related_entity = mapping.schema.entities[entity]
return [a['name'] for a in mapping.get_assignable_arguments(related_entity, include_derived=True)].index(attr_name) return [a['name'].lower() for a in mapping.get_assignable_arguments(related_entity, include_derived=True)].index(attr_name.lower())
inverse = [templates.const_function % { inverse = [templates.const_function % {
'class_name' : name, 'class_name' : name,
@@ -155,7 +157,7 @@ class Implementation(codegen.Base):
superclass = superclass superclass = superclass
) )
selectable_simple_types = sorted(set(sum([b.values for a,b in mapping.schema.selects.items()], [])) & set(mapping.schema.types.keys())) selectable_simple_types = sorted(set(sum([b.values for a,b in mapping.schema.selects.items()], [])) & set(map(str, mapping.schema.types.keys())))
schema_entity_statements += [templates.schema_entity_stmt%locals() for name, type in mapping.schema.simpletypes.items()] schema_entity_statements += [templates.schema_entity_stmt%locals() for name, type in mapping.schema.simpletypes.items()]
schema_entity_statements += [templates.schema_entity_stmt%locals() for name, type in mapping.schema.entities.items()] schema_entity_statements += [templates.schema_entity_stmt%locals() for name, type in mapping.schema.entities.items()]
@@ -168,7 +170,7 @@ class Implementation(codegen.Base):
'padding' : ' ' * (max_len - len(name)) 'padding' : ' ' * (max_len - len(name))
} for name in enumerable_types] } for name in enumerable_types]
enumeration_index_by_str = dict((j,i) for i,j in enumerate(enumerable_types)) enumeration_index_by_str = OrderedCaseInsensitiveDict((j,i) for i,j in enumerate(enumerable_types))
def get_parent_id(s): def get_parent_id(s):
e = mapping.schema.entities.get(s) e = mapping.schema.entities.get(s)
if e and e.supertypes: if e and e.supertypes:
@@ -41,11 +41,10 @@ class LateBoundImplementation(codegen.Base):
}) })
emitted_entities = set() emitted_entities = set()
entities_to_emit = mapping.schema.entities.keys()
while len(emitted_entities) < len(mapping.schema.entities): while len(emitted_entities) < len(mapping.schema.entities):
for name, type in mapping.schema.entities.items(): for name, type in mapping.schema.entities.items():
if name in emitted_entities: continue if name.lower() in emitted_entities: continue
if len(type.supertypes) == 0 or set(type.supertypes) < emitted_entities: if len(type.supertypes) == 0 or set(map(str.lower, type.supertypes)) <= emitted_entities:
constructor_arguments = mapping.get_assignable_arguments(type, include_derived = True) constructor_arguments = mapping.get_assignable_arguments(type, include_derived = True)
entity_descriptor_attributes = [] entity_descriptor_attributes = []
for arg in constructor_arguments: for arg in constructor_arguments:
@@ -61,8 +60,9 @@ class LateBoundImplementation(codegen.Base):
}) })
emitted_entities.add(name) emitted_entities.add(name)
parent_statement = '0' if len(type.supertypes) != 1 else templates.entity_descriptor_parent % { parent_statement = '0' if len(type.supertypes) != 1 else templates.entity_descriptor_parent % {
'type' : type.supertypes[0] 'type' : [k for k in mapping.schema.entities.keys() if k.lower() == type.supertypes[0].lower()][0]
} }
entity_descriptors.append(templates.entity_descriptor % { entity_descriptors.append(templates.entity_descriptor % {
'type' : name, 'type' : name,
@@ -92,13 +92,13 @@ class LateBoundImplementation(codegen.Base):
if type.inverse: if type.inverse:
for attr in type.inverse.elements: for attr in type.inverse.elements:
related_entity = mapping.schema.entities[attr.entity] related_entity = mapping.schema.entities[attr.entity]
related_attrs = [a['name'] for a in mapping.get_assignable_arguments(related_entity, include_derived=True)] related_attrs = [a['name'].lower() for a in mapping.get_assignable_arguments(related_entity, include_derived=True)]
inverse_implementations.append(templates.inverse_implementation % { inverse_implementations.append(templates.inverse_implementation % {
'type' : name, 'type' : name,
'name' : attr.name, 'name' : attr.name,
'related_type' : attr.entity, 'related_type' : attr.entity,
'index' : related_attrs.index(attr.attribute) 'index' : related_attrs.index(attr.attribute.lower())
}) })
self.str = templates.lb_implementation % { self.str = templates.lb_implementation % {
+6 -3
View File
@@ -57,7 +57,7 @@ class Mapping:
return None if str(parent) in self.express_to_cpp_typemapping else parent return None if str(parent) in self.express_to_cpp_typemapping else parent
def make_type_string(self, type): def make_type_string(self, type):
if isinstance(type, (str, nodes.BinaryType)): if isinstance(type, (str, nodes.BinaryType, nodes.StringType)):
return self.express_to_cpp_typemapping.get(str(type), type) return self.express_to_cpp_typemapping.get(str(type), type)
else: else:
is_list = self.schema.is_entity(type.type) is_list = self.schema.is_entity(type.type)
@@ -89,6 +89,8 @@ class Mapping:
return "ENTITY_INSTANCE" return "ENTITY_INSTANCE"
elif isinstance(type, nodes.BinaryType): elif isinstance(type, nodes.BinaryType):
return "BINARY" return "BINARY"
elif isinstance(type, nodes.StringType):
return "STRING"
elif isinstance(type, nodes.EnumerationType): elif isinstance(type, nodes.EnumerationType):
return "ENUMERATION" return "ENUMERATION"
elif isinstance(type, nodes.AggregationType): elif isinstance(type, nodes.AggregationType):
@@ -128,10 +130,11 @@ class Mapping:
type_str = templates.untyped_list type_str = templates.untyped_list
elif self.schema.is_simpletype(ty) or str(ty) in self.express_to_cpp_typemapping.values(): elif self.schema.is_simpletype(ty) or str(ty) in self.express_to_cpp_typemapping.values():
tmpl = templates.nested_array_type if is_nested_list else templates.array_type tmpl = templates.nested_array_type if is_nested_list else templates.array_type
bounds = (attr_type.bounds.lower, attr_type.bounds.upper) if attr_type.bounds else (-1, -1)
type_str = tmpl % { type_str = tmpl % {
'instance_type' : ty, 'instance_type' : ty,
'lower' : attr_type.bounds.lower, 'lower' : bounds[0],
'upper' : attr_type.bounds.upper 'upper' : bounds[1]
} }
else: else:
tmpl = templates.list_list_type if is_nested_list else templates.list_type tmpl = templates.list_list_type if is_nested_list else templates.list_type
+20 -3
View File
@@ -21,8 +21,8 @@ import string
import collections import collections
class Node: class Node:
def __init__(self, tokens): def __init__(self, tokens = None):
self.tokens = tokens self.tokens = tokens or []
self.init() self.init()
def tokens_of_type(self, cls): def tokens_of_type(self, cls):
return [t for t in self.tokens if isinstance(t, cls)] return [t for t in self.tokens if isinstance(t, cls)]
@@ -128,7 +128,7 @@ class AttributeList(Node):
class InverseAttribute(Node): class InverseAttribute(Node):
name = property(lambda self: self.tokens[0]) name = property(lambda self: self.tokens[0])
type = property(lambda self: self.tokens[2]) type = property(lambda self: self.tokens[2])
bounds = property(lambda self: None if len(self.tokens) == 6 else self.tokens[3]) bounds = property(lambda self: None if len(self.tokens) != 9 else self.tokens[3])
entity = property(lambda self: self.tokens[-4]) entity = property(lambda self: self.tokens[-4])
attribute = property(lambda self: self.tokens[-2]) attribute = property(lambda self: self.tokens[-2])
def init(self): def init(self):
@@ -170,6 +170,23 @@ class ExplicitAttribute(Node):
def init(self): def init(self):
# NB: This assumes a single name per attribute # NB: This assumes a single name per attribute
# definition, which is not necessarily the case. # definition, which is not necessarily the case.
if self.tokens[0] == "self":
i = list(self.tokens).index(":")
self.tokens = self.tokens[i-1:]
assert self.tokens[1] == ':' assert self.tokens[1] == ':'
def __repr__(self): def __repr__(self):
return "%s : %s%s" % (self.name, self.type, " ?" if self.optional else "") return "%s : %s%s" % (self.name, self.type, " ?" if self.optional else "")
class WidthSpec(Node):
def init(self):
if self.tokens[-1] == "fixed":
self.tokens[-1:] = []
assert (self.tokens[0], self.tokens[-1]) == ("(", ")")
self.width = int("".join(self.tokens[1:-1]))
class StringType(Node):
def init(self):
pass
def __repr__(self):
return "string"
+24 -2
View File
@@ -25,6 +25,28 @@ if tuple(map(int, platform.python_version_tuple())) < (2, 7):
import ordereddict import ordereddict
collections.OrderedDict = ordereddict.OrderedDict collections.OrderedDict = ordereddict.OrderedDict
# According to ISO 10303-11 7.1.2: Letters: "... The case of
# letters is significant only within explicit string literals."
class OrderedCaseInsensitiveDict(collections.OrderedDict):
class KeyObject(str):
def __eq__(self, other):
return self.lower() == other.lower()
def __hash__(self):
return hash(self.lower())
def __init__(self, *args, **kwargs):
collections.OrderedDict.__init__(self)
for key, value in collections.OrderedDict(*args, **kwargs).items():
self[OrderedCaseInsensitiveDict.KeyObject(key)] = value
def __setitem__(self, key, value):
return collections.OrderedDict.__setitem__(self, OrderedCaseInsensitiveDict.KeyObject(key), value)
def __getitem__(self, key):
return collections.OrderedDict.__getitem__(self, OrderedCaseInsensitiveDict.KeyObject(key))
def get(self, key, *args, **kwargs):
return collections.OrderedDict.get(self, OrderedCaseInsensitiveDict.KeyObject(key), *args, **kwargs)
def __contains__(self, key):
return collections.OrderedDict.__contains__(self, OrderedCaseInsensitiveDict.KeyObject(key))
class Schema: class Schema:
def is_enumeration(self, v): def is_enumeration(self, v):
return str(v) in self.enumerations return str(v) in self.enumerations
@@ -39,7 +61,7 @@ class Schema:
def __init__(self, parsetree): def __init__(self, parsetree):
self.name = parsetree[1] self.name = parsetree[1]
sort = lambda d: collections.OrderedDict(sorted(d)) sort = lambda d: OrderedCaseInsensitiveDict(sorted(d))
self.types = sort([(t.name,t) for t in parsetree if isinstance(t, nodes.TypeDeclaration)]) self.types = sort([(t.name,t) for t in parsetree if isinstance(t, nodes.TypeDeclaration)])
self.entities = sort([(t.name,t) for t in parsetree if isinstance(t, nodes.EntityDeclaration)]) self.entities = sort([(t.name,t) for t in parsetree if isinstance(t, nodes.EntityDeclaration)])
@@ -48,4 +70,4 @@ class Schema:
self.enumerations = of_type(nodes.EnumerationType) self.enumerations = of_type(nodes.EnumerationType)
self.selects = of_type(nodes.SelectType) self.selects = of_type(nodes.SelectType)
self.simpletypes = of_type(str, nodes.AggregationType, nodes.BinaryType) self.simpletypes = of_type(str, nodes.AggregationType, nodes.BinaryType, nodes.StringType)
+2
View File
@@ -141,6 +141,8 @@ public:
void remove_collinear_points_from_loop(TColgp_SequenceOfPnt& polygon, bool closed, double tol=-1.); void remove_collinear_points_from_loop(TColgp_SequenceOfPnt& polygon, bool closed, double tol=-1.);
bool wire_to_sequence_of_point(const TopoDS_Wire&, TColgp_SequenceOfPnt&); bool wire_to_sequence_of_point(const TopoDS_Wire&, TColgp_SequenceOfPnt&);
void sequence_of_point_to_wire(const TColgp_SequenceOfPnt&, TopoDS_Wire&, bool closed); void sequence_of_point_to_wire(const TColgp_SequenceOfPnt&, TopoDS_Wire&, bool closed);
bool approximate_plane_through_wire(const TopoDS_Wire&, gp_Pln&);
bool flatten_wire(TopoDS_Wire&);
bool is_identity_transform(IfcUtil::IfcBaseClass*); bool is_identity_transform(IfcUtil::IfcBaseClass*);
+13 -2
View File
@@ -202,7 +202,11 @@ bool IfcGeom::Kernel::convert(const IfcSchema::IfcFace* l, TopoDS_Shape& face) {
ShapeFix_ShapeTolerance FTol; ShapeFix_ShapeTolerance FTol;
FTol.SetTolerance(wire, getValue(GV_PRECISION), TopAbs_WIRE); FTol.SetTolerance(wire, getValue(GV_PRECISION), TopAbs_WIRE);
bool flattened_wire = false;
if (!mf) { if (!mf) {
process_wire:
if (face_surface.IsNull()) { if (face_surface.IsNull()) {
mf = new BRepBuilderAPI_MakeFace(wire); mf = new BRepBuilderAPI_MakeFace(wire);
} else { } else {
@@ -264,9 +268,16 @@ bool IfcGeom::Kernel::convert(const IfcSchema::IfcFace* l, TopoDS_Shape& face) {
success = true; success = true;
} }
} else { } else {
Logger::Message(Logger::LOG_ERROR, "Failed to process face boundary", bound->entity); const bool non_planar = mf->Error() == BRepBuilderAPI_NotPlanar;
delete mf; delete mf;
return false; if (!non_planar || flattened_wire || !flatten_wire(wire)) {
Logger::Message(Logger::LOG_ERROR, "Failed to process face boundary", bound->entity);
return false;
} else {
Logger::Message(Logger::LOG_ERROR, "Flattening face boundary", bound->entity);
flattened_wire = true;
goto process_wire;
}
} }
} else { } else {
+73
View File
@@ -75,6 +75,8 @@
#include <BRepAlgoAPI_Cut.hxx> #include <BRepAlgoAPI_Cut.hxx>
#include <BRepAlgoAPI_Fuse.hxx> #include <BRepAlgoAPI_Fuse.hxx>
#include <BRepAlgo_NormalProjection.hxx>
#include <ShapeFix_Shape.hxx> #include <ShapeFix_Shape.hxx>
#include <ShapeFix_ShapeTolerance.hxx> #include <ShapeFix_ShapeTolerance.hxx>
#include <ShapeFix_Solid.hxx> #include <ShapeFix_Solid.hxx>
@@ -94,6 +96,7 @@
#include <BRepMesh_IncrementalMesh.hxx> #include <BRepMesh_IncrementalMesh.hxx>
#include <BRepTools.hxx> #include <BRepTools.hxx>
#include <BRepTools_WireExplorer.hxx>
#include <Poly_Triangulation.hxx> #include <Poly_Triangulation.hxx>
#include <Poly_Array1OfTriangle.hxx> #include <Poly_Array1OfTriangle.hxx>
@@ -1396,3 +1399,73 @@ bool IfcGeom::Kernel::is_identity_transform(IfcUtil::IfcBaseClass* l) {
} }
} }
bool IfcGeom::Kernel::approximate_plane_through_wire(const TopoDS_Wire& wire, gp_Pln& plane) {
// Newell's Method is used for the normal calculation
// as a simple edge cross product can give opposite results
// for a concave face boundary.
// Reference: Graphics Gems III p. 231
double x = 0, y = 0, z = 0;
gp_Pnt current, previous, first;
gp_XYZ center;
int n = 0;
BRepTools_WireExplorer exp(wire);
for (;; exp.Next()) {
const bool has_more = exp.More();
if (has_more) {
const TopoDS_Vertex& v = exp.CurrentVertex();
current = BRep_Tool::Pnt(v);
center += current.XYZ();
} else {
current = first;
}
if (n) {
const double& xn = previous.X();
const double& yn = previous.Y();
const double& zn = previous.Z();
const double& xn1 = current.X();
const double& yn1 = current.Y();
const double& zn1 = current.Z();
x += (yn - yn1)*(zn + zn1);
y += (xn + xn1)*(zn - zn1);
z += (xn - xn1)*(yn + yn1);
} else {
first = current;
}
if (!has_more) {
break;
}
previous = current;
++n;
}
if (n < 3) {
return false;
}
plane = gp_Pln(center / n, gp_Dir(x, y, z));
return true;
}
bool IfcGeom::Kernel::flatten_wire(TopoDS_Wire& wire) {
gp_Pln pln;
if (!approximate_plane_through_wire(wire, pln)) {
return false;
}
TopoDS_Face face = BRepBuilderAPI_MakeFace(pln).Face();
BRepAlgo_NormalProjection proj(face);
proj.Add(wire);
proj.Build();
if (!proj.IsDone()) {
return false;
}
TopTools_ListOfShape list;
proj.BuildWire(list);
if (list.Extent() != 1) {
return false;
}
wire = TopoDS::Wire(list.First());
return true;
}
+17
View File
@@ -38,6 +38,23 @@ IfcGeom::Representation::Serialization::Serialization(const BRep& brep)
for (IfcGeom::IfcRepresentationShapeItems::const_iterator it = brep.begin(); it != brep.end(); ++ it) { for (IfcGeom::IfcRepresentationShapeItems::const_iterator it = brep.begin(); it != brep.end(); ++ it) {
const TopoDS_Shape& s = it->Shape(); const TopoDS_Shape& s = it->Shape();
gp_GTrsf trsf = it->Placement(); gp_GTrsf trsf = it->Placement();
if (it->hasStyle() && it->Style().Diffuse()) {
const IfcGeom::SurfaceStyle::ColorComponent& clr = *it->Style().Diffuse();
_surface_styles.push_back(clr.R());
_surface_styles.push_back(clr.G());
_surface_styles.push_back(clr.B());
} else {
_surface_styles.push_back(-1.);
_surface_styles.push_back(-1.);
_surface_styles.push_back(-1.);
}
if (it->hasStyle() && it->Style().Transparency()) {
_surface_styles.push_back(1. - *it->Style().Transparency());
} else {
_surface_styles.push_back(1.);
}
if (settings().get(IteratorSettings::CONVERT_BACK_UNITS)) { if (settings().get(IteratorSettings::CONVERT_BACK_UNITS)) {
gp_Trsf scale; gp_Trsf scale;
scale.SetScaleFactor(1.0 / settings().unit_magnitude()); scale.SetScaleFactor(1.0 / settings().unit_magnitude());
+2
View File
@@ -77,9 +77,11 @@ namespace IfcGeom {
private: private:
int _id; int _id;
std::string _brep_data; std::string _brep_data;
std::vector<double> _surface_styles;
public: public:
int id() const { return _id; } int id() const { return _id; }
const std::string& brep_data() const { return _brep_data; } const std::string& brep_data() const { return _brep_data; }
const std::vector<double>& surface_styles() const { return _surface_styles; }
Serialization(const BRep& brep); Serialization(const BRep& brep);
virtual ~Serialization() {} virtual ~Serialization() {}
private: private:
+30 -29
View File
@@ -98,6 +98,8 @@
#include <Standard_Version.hxx> #include <Standard_Version.hxx>
#include <TopTools_ListIteratorOfListOfShape.hxx>
#include "../ifcgeom/IfcGeom.h" #include "../ifcgeom/IfcGeom.h"
bool IfcGeom::Kernel::convert(const IfcSchema::IfcExtrudedAreaSolid* l, TopoDS_Shape& shape) { bool IfcGeom::Kernel::convert(const IfcSchema::IfcExtrudedAreaSolid* l, TopoDS_Shape& shape) {
@@ -442,28 +444,38 @@ bool IfcGeom::Kernel::convert(const IfcSchema::IfcBooleanResult* l, TopoDS_Shape
bool IfcGeom::Kernel::convert(const IfcSchema::IfcConnectedFaceSet* l, TopoDS_Shape& shape) { bool IfcGeom::Kernel::convert(const IfcSchema::IfcConnectedFaceSet* l, TopoDS_Shape& shape) {
IfcSchema::IfcFace::list::ptr faces = l->CfsFaces(); IfcSchema::IfcFace::list::ptr faces = l->CfsFaces();
bool facesAdded = false;
const unsigned int num_faces = (unsigned)faces->size(); TopTools_ListOfShape face_list;
for (IfcSchema::IfcFace::list::it it = faces->begin(); it != faces->end(); ++it) {
TopoDS_Face face;
try {
convert_face(*it, face);
} catch (...) {
continue;
}
if (face_area(face) > getValue(GV_MINIMAL_FACE_AREA)) {
face_list.Append(face);
} else {
Logger::Message(Logger::LOG_WARNING, "Invalid face:", (*it)->entity);
}
}
if (face_list.Extent() == 0) {
return false;
}
bool valid_shell = false; bool valid_shell = false;
if ( num_faces < getValue(GV_MAX_FACES_TO_SEW) ) {
TopTools_ListIteratorOfListOfShape face_iterator;
if ( face_list.Extent() < getValue(GV_MAX_FACES_TO_SEW) ) {
BRepOffsetAPI_Sewing builder; BRepOffsetAPI_Sewing builder;
builder.SetTolerance(getValue(GV_POINT_EQUALITY_TOLERANCE)); builder.SetTolerance(getValue(GV_POINT_EQUALITY_TOLERANCE));
builder.SetMaxTolerance(getValue(GV_POINT_EQUALITY_TOLERANCE)); builder.SetMaxTolerance(getValue(GV_POINT_EQUALITY_TOLERANCE));
builder.SetMinTolerance(getValue(GV_POINT_EQUALITY_TOLERANCE)); builder.SetMinTolerance(getValue(GV_POINT_EQUALITY_TOLERANCE));
for( IfcSchema::IfcFace::list::it it = faces->begin(); it != faces->end(); ++ it ) { for (face_iterator.Initialize(face_list); face_iterator.More(); face_iterator.Next()) {
TopoDS_Face face; builder.Add(face_iterator.Value());
bool converted_face = false;
try {
converted_face = convert_face(*it,face);
} catch (...) {}
if ( converted_face && face_area(face) > getValue(GV_MINIMAL_FACE_AREA) ) {
builder.Add(face);
facesAdded = true;
} else {
Logger::Message(Logger::LOG_WARNING,"Invalid face:",(*it)->entity);
}
} }
if ( ! facesAdded ) return false;
try { try {
builder.Perform(); builder.Perform();
shape = builder.SewedShape(); shape = builder.SewedShape();
@@ -489,20 +501,9 @@ bool IfcGeom::Kernel::convert(const IfcSchema::IfcConnectedFaceSet* l, TopoDS_Sh
TopoDS_Compound compound; TopoDS_Compound compound;
BRep_Builder builder; BRep_Builder builder;
builder.MakeCompound(compound); builder.MakeCompound(compound);
for( IfcSchema::IfcFace::list::it it = faces->begin(); it != faces->end(); ++ it ) { for (face_iterator.Initialize(face_list); face_iterator.More(); face_iterator.Next()) {
TopoDS_Face face; builder.Add(compound, face_iterator.Value());
bool converted_face = false;
try {
converted_face = convert_face(*it,face);
} catch (...) {}
if ( converted_face && face_area(face) > getValue(GV_MINIMAL_FACE_AREA) ) {
builder.Add(compound,face);
facesAdded = true;
} else {
Logger::Message(Logger::LOG_WARNING,"Invalid face:",(*it)->entity);
}
} }
if ( ! facesAdded ) return false;
shape = compound; shape = compound;
} }
return true; return true;
@@ -91,6 +91,11 @@ class entity_instance(object):
def __repr__(self): return repr(self.wrapped_data) def __repr__(self): return repr(self.wrapped_data)
def is_a(self, *args): return self.wrapped_data.is_a(*args) def is_a(self, *args): return self.wrapped_data.is_a(*args)
def id(self): return self.wrapped_data.id() def id(self): return self.wrapped_data.id()
def __eq__(self, other):
if type(self) != type(other): return False
return self.wrapped_data == other.wrapped_data
def __hash__(self):
return hash((self.id(), self.wrapped_data.file_pointer()))
def __dir__(self): def __dir__(self):
return sorted(set(itertools.chain( return sorted(set(itertools.chain(
dir(type(self)), dir(type(self)),
@@ -147,3 +152,4 @@ def create_entity(type,*args,**kwargs):
version = ifcopenshell_wrapper.version() version = ifcopenshell_wrapper.version()
schema_identifier = ifcopenshell_wrapper.schema_identifier() schema_identifier = ifcopenshell_wrapper.schema_identifier()
get_supertype = ifcopenshell_wrapper.get_supertype
@@ -1,88 +1,2 @@
############################################################################### from . import occ_utils as utils
# # from .main import *
# This file is part of IfcOpenShell. #
# #
# IfcOpenShell is free software: you can redistribute it and/or modify #
# it under the terms of the Lesser GNU General Public License as published by #
# the Free Software Foundation, either version 3.0 of the License, or #
# (at your option) any later version. #
# #
# IfcOpenShell is distributed in the hope that it will be useful, #
# but WITHOUT ANY WARRANTY; without even the implied warranty of #
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the #
# Lesser GNU General Public License for more details. #
# #
# You should have received a copy of the Lesser GNU General Public License #
# along with this program. If not, see <http://www.gnu.org/licenses/>. #
# #
###############################################################################
import os
import sys
from .. import ifcopenshell_wrapper
def has_occ():
try: import OCC.BRepTools
except: return False
return True
has_occ = has_occ()
wrap_shape_creation = lambda settings, shape: shape
if has_occ:
from . import occ_utils as utils
wrap_shape_creation = lambda settings, shape: utils.create_shape_from_serialization(shape) if getattr(settings, 'use_python_opencascade', False) else shape
# Subclass the settings module to provide an additional
# setting to enable pythonOCC when available
class settings(ifcopenshell_wrapper.settings):
if has_occ:
USE_PYTHON_OPENCASCADE = -1
def set(self, *args):
setting, value = args
if setting == settings.USE_PYTHON_OPENCASCADE:
self.set(settings.USE_BREP_DATA, value)
self.set(settings.USE_WORLD_COORDS, value)
self.set(settings.DISABLE_TRIANGULATION, value)
self.use_python_opencascade = value
else:
ifcopenshell_wrapper.settings.set(self, *args)
# Hide templating precision to the user by choosing based on Python's
# internal float type. This is probably always going to be a double.
for ty in (ifcopenshell_wrapper.iterator_single_precision, ifcopenshell_wrapper.iterator_double_precision):
if ty.mantissa_size() == sys.float_info.mant_dig:
_iterator = ty
# Make sure people are able to use python's platform agnostic paths
class iterator(_iterator):
def __init__(self, settings, filename):
self.settings = settings
_iterator.__init__(self, settings, os.path.abspath(filename))
if has_occ:
def get(self):
return wrap_shape_creation(self.settings, _iterator.get(self))
def create_shape(settings, inst, repr=None):
return wrap_shape_creation(
settings,
ifcopenshell_wrapper.create_shape(
settings,
inst.wrapped_data,
repr.wrapped_data if repr is not None else None
))
def iterate(settings, filename):
it = iterator(settings, filename)
if it.initialize():
while True:
yield it.get()
if not it.next(): break
@@ -0,0 +1,370 @@
import sys
import time
import operator
import functools
import OCC.AIS
import ifcopenshell
from collections import defaultdict, Iterable
from PyQt4 import QtGui, QtCore
try: from OCC.Display.pyqt4Display import qtViewer3d
except:
import OCC.Display
OCC.Display.backend.get_backend("qt-pyqt4")
from OCC.Display.qtDisplay import qtViewer3d
from .main import create_shape, settings
from .occ_utils import display_shape
# Depending on Python version and what not there may or may not be a QString
try:
from PyQt4.QtCore import QString
except ImportError:
QString = str
class application(QtGui.QApplication):
"""A pythonOCC, PyQt based IfcOpenShell application
with two tree views and a graphical 3d view"""
class abstract_treeview(QtGui.QTreeWidget):
"""Base class for the two treeview controls"""
instanceSelected = QtCore.pyqtSignal([object])
instanceVisibilityChanged = QtCore.pyqtSignal([object, int])
instanceDisplayModeChanged = QtCore.pyqtSignal([object, int])
def __init__(self):
QtGui.QTreeView.__init__(self)
self.setColumnCount(len(self.ATTRIBUTES))
self.setHeaderLabels(self.ATTRIBUTES)
self.children = defaultdict(list)
def get_children(self, inst):
c = [inst]
i = 0
while i < len(c):
c.extend(self.children[c[i]])
i += 1
return c
def contextMenuEvent(self, event):
menu = QtGui.QMenu(self)
visibility = [menu.addAction("Show"), menu.addAction("Hide")]
displaymode = [menu.addAction("Solid"), menu.addAction("Wireframe")]
action = menu.exec_(self.mapToGlobal(event.pos()))
index = self.selectionModel().currentIndex()
inst = index.data(QtCore.Qt.UserRole)
if hasattr(inst, 'toPyObject'):
inst = inst.toPyObject()
if action in visibility:
self.instanceVisibilityChanged.emit(inst, visibility.index(action))
elif action in displaymode:
self.instanceDisplayModeChanged.emit(inst, displaymode.index(action))
def clicked(self, index):
inst = index.data(QtCore.Qt.UserRole)
if hasattr(inst, 'toPyObject'):
inst = inst.toPyObject()
if inst:
self.instanceSelected.emit(inst)
def select(self, product):
itm = self.product_to_item.get(product)
if itm is None: return
self.selectionModel().setCurrentIndex(itm, QtGui.QItemSelectionModel.SelectCurrent | QtGui.QItemSelectionModel.Rows);
class decomposition_treeview(abstract_treeview):
"""Treeview with typical IFC decomposition relationships"""
ATTRIBUTES = ['Entity', 'GlobalId', 'Name']
def parent(self, instance):
if instance.is_a("IfcOpeningElement"):
return instance.VoidsElements[0].RelatingBuildingElement
if instance.is_a("IfcElement"):
fills = instance.FillsVoids
if len(fills):
return fills[0].RelatingOpeningElement
containments = instance.ContainedInStructure
if len(containments):
return containments[0].RelatingStructure
if instance.is_a("IfcObjectDefinition"):
decompositions = instance.Decomposes
if len(decompositions):
return decompositions[0].RelatingObject
def load_file(self, f):
products = list(f.by_type("IfcProduct")) + list(f.by_type("IfcProject"))
parents = list(map(self.parent, products))
items = {}
skipped = 0
ATTRS = self.ATTRIBUTES
while len(items) + skipped < len(products):
for product, parent in zip(products, parents):
if parent is None and not product.is_a("IfcProject"):
skipped += 1
continue
if (parent is None or parent in items) and product not in items:
sl = []
for attr in ATTRS:
if attr == 'Entity':
sl.append(product.is_a())
else:
sl.append(getattr(product, attr) or '')
itm = items[product] = QtGui.QTreeWidgetItem(items.get(parent, self), sl)
itm.setData(0, QtCore.Qt.UserRole, product)
self.children[parent].append(product)
self.product_to_item = dict(zip(items.keys(), map(self.indexFromItem, items.values())))
self.connect(self, QtCore.SIGNAL("clicked(const QModelIndex &)"), self.clicked)
self.expandAll()
class type_treeview(abstract_treeview):
"""Treeview with typical IFC decomposition relationships"""
ATTRIBUTES = ['Name']
def load_file(self, f):
products = list(f.by_type("IfcProduct"))
types = set(map(lambda i: i.is_a(), products))
items = {}
for t in types:
def add(t):
s = ifcopenshell.get_supertype(t)
if s: add(s)
s2, t2 = map(QString, (s,t))
if t2 not in items:
itm = items[t2] = QtGui.QTreeWidgetItem(items.get(s2, self), [t2])
itm.setData(0, QtCore.Qt.UserRole, t2)
self.children[s2].append(t2)
add(t)
for p in products:
t = QString(p.is_a())
itm = items[p] = QtGui.QTreeWidgetItem(items.get(t, self), [p.Name or '<no name>'])
itm.setData(0, QtCore.Qt.UserRole, t)
self.children[t].append(p)
self.product_to_item = dict(zip(items.keys(), map(self.indexFromItem, items.values())))
self.connect(self, QtCore.SIGNAL("clicked(const QModelIndex &)"), self.clicked)
self.expandAll()
class viewer(qtViewer3d):
instanceSelected = QtCore.pyqtSignal([object])
@staticmethod
def ais_to_key(ais_handle):
def yield_shapes():
ais = ais_handle.GetObject()
if hasattr(ais, 'Shape'):
yield ais.Shape()
return
shp = OCC.AIS.Handle_AIS_Shape.DownCast(ais_handle)
if not shp.IsNull(): yield shp.Shape()
return
mult = ais_handle
if mult.IsNull():
shp = OCC.AIS.Handle_AIS_Shape.DownCast(ais_handle)
if not shp.IsNull(): yield shp
else:
li = mult.GetObject().ConnectedTo()
for i in range(li.Length()):
shp = OCC.AIS.Handle_AIS_Shape.DownCast(li.Value(i+1))
if not shp.IsNull(): yield shp
return tuple(shp.HashCode(1 << 24) for shp in yield_shapes())
def __init__(self, widget):
qtViewer3d.__init__(self, widget)
self.ais_to_product = {}
self.product_to_ais = {}
self.counter = 0
self.window = widget
def initialize(self):
self.InitDriver()
self._display.Select = self.HandleSelection
def load_file(self, f):
s = settings()
s.set(s.USE_PYTHON_OPENCASCADE, True)
v = self._display
t = {0: time.time()}
def update(dt = None):
t1 = time.time()
if t1 - t[0] > (dt or -1):
v.FitAll()
v.Repaint()
t[0] = t1
terminate = [False]
self.window.window_closed.connect(lambda *args: operator.setitem(terminate, 0, True))
for p in f.by_type("IfcProduct"):
if terminate[0]: break
if p.Representation is None: continue
shape = create_shape(s, p)
ais = display_shape(shape, viewer_handle=v)
ais.GetObject().SetSelectionPriority(self.counter)
self.ais_to_product[self.counter] = p
self.product_to_ais[p] = ais
self.counter += 1
QtGui.QApplication.processEvents()
if p.is_a() in {'IfcSpace', 'IfcOpeningElement'}:
v.Context.Erase(ais, True)
update(0.1)
update()
def select(self, product):
ais = self.product_to_ais.get(product)
if ais is None: return
v = self._display.Context
v.ClearSelected(False)
v.SetSelected(ais, True)
def toggle(self, product_or_products, fn):
if not isinstance(product_or_products, Iterable):
product_or_products = [product_or_products]
aiss = list(filter(None, map(self.product_to_ais.get, product_or_products)))
last = len(aiss) - 1
for i, ais in enumerate(aiss):
fn(ais, i == last)
def toggle_visibility(self, product_or_products, flag):
v = self._display.Context
if flag:
def visibility(ais, last):
v.Erase(ais, last)
else:
def visibility(ais, last):
v.Display(ais, last)
self.toggle(product_or_products, visibility)
def toggle_wireframe(self, product_or_products, flag):
v = self._display.Context
if flag:
def wireframe(ais, last):
if v.IsDisplayed(ais):
v.SetDisplayMode(ais, 0, last)
else:
def wireframe(ais, last):
if v.IsDisplayed(ais):
v.SetDisplayMode(ais, 1, last)
self.toggle(product_or_products, wireframe)
def HandleSelection(self, X, Y):
v = self._display.Context
v.Select()
v.InitSelected()
if v.MoreSelected():
ais = v.SelectedInteractive()
inst = self.ais_to_product[ais.GetObject().SelectionPriority()]
self.instanceSelected.emit(inst)
class window(QtGui.QMainWindow):
TITLE = "IfcOpenShell IFC viewer"
window_closed = QtCore.pyqtSignal([])
def __init__(self):
QtGui.QMainWindow.__init__(self)
self.setWindowTitle(self.TITLE)
self.menu = self.menuBar()
self.menus = {}
def closeEvent(self, *args):
self.window_closed.emit()
def add_menu_item(self, menu, label, callback, icon=None, shortcut=None):
m = self.menus.get(menu)
if m is None:
m = self.menu.addMenu(menu)
self.menus[menu] = m
if icon:
a = QtGui.QAction(QtGui.QIcon(icon), label, self)
else:
a = QtGui.QAction(label, self)
if shortcut:
a.setShortcut(shortcut)
a.triggered.connect(callback)
m.addAction(a)
def makeSelectionHandler(self, component):
def handler(inst):
for c in self.components:
if c != component:
c.select(inst)
return handler
def __init__(self):
QtGui.QApplication.__init__(self, sys.argv)
self.window = application.window()
self.tree = application.decomposition_treeview()
self.tree2 = application.type_treeview()
self.canvas = application.viewer(self.window)
self.tabs = QtGui.QTabWidget()
self.window.resize(800, 600)
splitter = QtGui.QSplitter(QtCore.Qt.Horizontal)
splitter.addWidget(self.tabs)
self.tabs.addTab(self.tree, 'Decomposition')
self.tabs.addTab(self.tree2, 'Types')
splitter.addWidget(self.canvas)
splitter.setSizes([200,600])
self.window.setCentralWidget(splitter)
self.canvas.initialize()
self.components = [self.tree, self.tree2, self.canvas]
self.files = {}
self.window.add_menu_item('File', '&Open', self.browse, shortcut='CTRL+O')
self.window.add_menu_item('File', '&Close', self.clear, shortcut='CTRL+W')
self.window.add_menu_item('File', '&Exit', self.window.close, shortcut='ALT+F4')
self.tree.instanceSelected.connect(self.makeSelectionHandler(self.tree))
self.tree2.instanceSelected.connect(self.makeSelectionHandler(self.tree2))
self.canvas.instanceSelected.connect(self.makeSelectionHandler(self.canvas))
for t in [self.tree, self.tree2]:
t.instanceVisibilityChanged.connect(functools.partial(self.change_visibility, t))
t.instanceDisplayModeChanged.connect(functools.partial(self.change_displaymode, t))
def change_visibility(self, tree, inst, flag):
insts = tree.get_children(inst)
self.canvas.toggle_visibility(insts, flag)
def change_displaymode(self, tree, inst, flag):
insts = tree.get_children(inst)
self.canvas.toggle_wireframe(insts, flag)
def start(self):
self.window.show()
sys.exit(self.exec_())
def browse(self):
filename = QtGui.QFileDialog.getOpenFileName(self.window, 'Open file',".","Industry Foundation Classes (*.ifc)")
self.load(filename)
def clear(self):
self.canvas._display.Context.RemoveAll()
self.tree.clear()
self.files.clear()
def load(self, fn):
if fn in self.files: return
f = ifcopenshell.open(fn)
self.files[fn] = f
for c in self.components:
c.load_file(f)
@@ -0,0 +1,86 @@
###############################################################################
# #
# This file is part of IfcOpenShell. #
# #
# IfcOpenShell is free software: you can redistribute it and/or modify #
# it under the terms of the Lesser GNU General Public License as published by #
# the Free Software Foundation, either version 3.0 of the License, or #
# (at your option) any later version. #
# #
# IfcOpenShell is distributed in the hope that it will be useful, #
# but WITHOUT ANY WARRANTY; without even the implied warranty of #
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the #
# Lesser GNU General Public License for more details. #
# #
# You should have received a copy of the Lesser GNU General Public License #
# along with this program. If not, see <http://www.gnu.org/licenses/>. #
# #
###############################################################################
import os
import sys
from .. import ifcopenshell_wrapper
def has_occ():
try: import OCC.BRepTools
except: return False
return True
has_occ = has_occ()
wrap_shape_creation = lambda settings, shape: shape
if has_occ:
from . import occ_utils as utils
wrap_shape_creation = lambda settings, shape: utils.create_shape_from_serialization(shape) if getattr(settings, 'use_python_opencascade', False) else shape
# Subclass the settings module to provide an additional
# setting to enable pythonOCC when available
class settings(ifcopenshell_wrapper.settings):
if has_occ:
USE_PYTHON_OPENCASCADE = -1
def set(self, *args):
setting, value = args
if setting == settings.USE_PYTHON_OPENCASCADE:
self.set(settings.USE_BREP_DATA, value)
self.set(settings.USE_WORLD_COORDS, value)
self.set(settings.DISABLE_TRIANGULATION, value)
self.use_python_opencascade = value
else:
ifcopenshell_wrapper.settings.set(self, *args)
# Hide templating precision to the user by choosing based on Python's
# internal float type. This is probably always going to be a double.
for ty in (ifcopenshell_wrapper.iterator_single_precision, ifcopenshell_wrapper.iterator_double_precision):
if ty.mantissa_size() == sys.float_info.mant_dig:
_iterator = ty
# Make sure people are able to use python's platform agnostic paths
class iterator(_iterator):
def __init__(self, settings, filename):
self.settings = settings
_iterator.__init__(self, settings, os.path.abspath(filename))
if has_occ:
def get(self):
return wrap_shape_creation(self.settings, _iterator.get(self))
def create_shape(settings, inst, repr=None):
return wrap_shape_creation(
settings,
ifcopenshell_wrapper.create_shape(
settings,
inst.wrapped_data,
repr.wrapped_data if repr is not None else None
))
def iterate(settings, filename):
it = iterator(settings, filename)
if it.initialize():
while True:
yield it.get()
if not it.next(): break
@@ -18,18 +18,35 @@
############################################################################### ###############################################################################
import random import random
from collections import namedtuple import operator
from collections import namedtuple, Iterable
import OCC.gp import OCC.gp
import OCC.V3d import OCC.V3d
import OCC.AIS
import OCC.Quantity import OCC.Quantity
import OCC.BRepTools import OCC.BRepTools
import OCC.Display.SimpleGui import OCC.Display.SimpleGui
tuple = namedtuple('shape', ('data', 'geometry')) shape_tuple = namedtuple('shape_tuple', ('data', 'geometry', 'styles'))
handle, main_loop, add_menu, add_function_to_menu = None, None, None, None handle, main_loop, add_menu, add_function_to_menu = None, None, None, None
DEFAULT_STYLES = {
"DEFAULT" : (.7 , .7, .7 ),
"IfcWall" : (.8 , .8, .8 ),
"IfcSite" : (.75, .8, .65 ),
"IfcSlab" : (.4 , .4, .4 ),
"IfcWallStandardCase": (.9 , .9, .9 ),
"IfcWall" : (.9 , .9, .9 ),
"IfcWindow" : (.75, .8, .75, .3),
"IfcDoor" : (.55, .3, .15 ),
"IfcBeam" : (.75, .7, .7 ),
"IfcRailing" : (.65, .6, .6 ),
"IfcMember" : (.65, .6, .6 ),
"IfcPlate" : (.8 , .8, .8 )
}
def initialize_display(): def initialize_display():
global handle, main_loop, add_menu, add_function_to_menu global handle, main_loop, add_menu, add_function_to_menu
handle, main_loop, add_menu, add_function_to_menu = OCC.Display.SimpleGui.init_display() handle, main_loop, add_menu, add_function_to_menu = OCC.Display.SimpleGui.init_display()
@@ -37,25 +54,117 @@ def initialize_display():
def setup(): def setup():
viewer_handle = handle.GetViewer() viewer_handle = handle.GetViewer()
viewer = viewer_handle.GetObject() viewer = viewer_handle.GetObject()
while True:
def lights():
viewer.InitActiveLights() viewer.InitActiveLights()
try: active_light = viewer.ActiveLight() while True:
except: break try: active_light = viewer.ActiveLight()
viewer.DelLight(active_light) except: break
viewer.NextActiveLights() yield active_light
for dir in [(1,2,-3), (-2,-1,1)]: viewer.NextActiveLights()
lights = list(lights())
for l in lights:
viewer.DelLight(l)
for dir in [(3,2,1), (-1,-2,-3)]:
light = OCC.V3d.V3d_DirectionalLight(viewer_handle) light = OCC.V3d.V3d_DirectionalLight(viewer_handle)
light.SetDirection(*dir) light.SetDirection(*dir)
viewer.SetLightOn(light.GetHandle()) viewer.SetLightOn(light.GetHandle())
setup() setup()
return handle return handle
def yield_subshapes(shape):
it = OCC.TopoDS.TopoDS_Iterator(shape)
while it.More():
yield it.Value()
it.Next()
def display_shape(shape, clr=None, viewer_handle=None):
if viewer_handle is None: viewer_handle = handle
if isinstance(shape, shape_tuple):
shape, representation = shape.geometry, shape
else: representation = None
material = OCC.Graphic3d.Graphic3d_MaterialAspect(OCC.Graphic3d.Graphic3d_NOM_PLASTER)
material.SetDiffuse(1)
if representation and not clr:
if len(set(representation.styles)) == 1:
clr = representation.styles[0]
if min(clr) < 0. or max(clr) > 1.:
clr = DEFAULT_STYLES.get(representation.data.type, DEFAULT_STYLES["DEFAULT"])
if clr:
ais = OCC.AIS.AIS_Shape(shape)
ais.SetMaterial(material)
if isinstance(clr, str):
qclr = getattr(OCC.Quantity, "Quantity_NOC_%s" % clr.upper(), getattr(OCC.Quantity, "Quantity_NOC_%s1" % clr.upper(), None))
if qclr is None:
raise Exception("No color named '%s'" % clr.upper())
elif isinstance(clr, Iterable):
clr = tuple(clr)
if len(clr) < 3 and len(clr) > 4:
raise Exception("Need 3 or 4 colour components. Got '%r'." % clr)
qclr = OCC.Quantity.Quantity_Color(clr[0], clr[1], clr[2], OCC.Quantity.Quantity_TOC_RGB)
elif isinstance(clr, OCC.Quantity.Quantity_Color):
qclr = clr
else:
raise Exception("Object of type %r cannot be used as a color." % type(clr))
ais.SetColor(qclr)
if isinstance(clr, tuple) and len(clr) == 4 and clr[3] < 1.:
ais.SetTransparency(1. - clr[3])
elif representation:
default_style_applied = None
ais = OCC.AIS.AIS_MultipleConnectedShape(shape)
subshapes = list(yield_subshapes(shape))
lens = len(representation.styles), len(subshapes)
if lens[0] != lens[1]:
import warnings
warnings.warn("Unable to assign styles to subshapes. Encountered %d styles for %d shapes." % lens)
else:
for shp, stl in zip(subshapes, representation.styles):
subshape = OCC.AIS.AIS_Shape(shp)
if min(stl) < 0. or max(stl) > 1.:
default_style_applied = stl = DEFAULT_STYLES.get(representation.data.type, DEFAULT_STYLES["DEFAULT"])
subshape.SetColor(OCC.Quantity.Quantity_Color(stl[0], stl[1], stl[2], OCC.Quantity.Quantity_TOC_RGB))
subshape.SetMaterial(material)
if len(stl) == 4 and stl[3] < 1.:
subshape.SetTransparency(1. - stl[3])
ais.Connect(subshape.GetHandle())
# For some reason it is necessary to set transparency here again
# in order for transparency to be rendered on the subshape.
applied_styles = representation.styles
if default_style_applied:
if len(default_style_applied) == 3: default_style_applied += (1.,)
applied_styles += (default_style_applied,)
if len(applied_styles):
# The only way for this not to be true if is the entire shape is NULL
min_transp = min(map(operator.itemgetter(3), applied_styles))
if min_transp < 1.:
ais.SetTransparency(1.)
else:
ais = OCC.AIS.AIS_Shape(shape)
ais.SetMaterial(material)
def display_shape(shape, clr=None):
if not clr:
r = lambda: random.random() * 0.3 + 0.7 r = lambda: random.random() * 0.3 + 0.7
clr = OCC.Quantity.Quantity_Color(r(), r(), r(), OCC.Quantity.Quantity_TOC_RGB) clr = OCC.Quantity.Quantity_Color(r(), r(), r(), OCC.Quantity.Quantity_TOC_RGB)
return handle.DisplayShape(shape, color=clr, update=True) ais.SetColor(clr)
ais_handle = ais.GetHandle()
viewer_handle.Context.Display(ais_handle, False)
return ais_handle
def set_shape_transparency(ais, t): def set_shape_transparency(ais, t):
@@ -69,17 +178,22 @@ def get_bounding_box_center(bbox):
def create_shape_from_serialization(brep_object): def create_shape_from_serialization(brep_object):
brep_data, occ_shape = None, None brep_data, occ_shape, styles = None, None, ()
is_product_shape = True is_product_shape = True
try: try:
brep_data = brep_object.geometry.brep_data brep_data = brep_object.geometry.brep_data
styles = brep_object.geometry.surface_styles
except: except:
try: try:
brep_data = brep_object.brep_data brep_data = brep_object.brep_data
styles = brep_object.surface_styles
is_product_shape = False is_product_shape = False
except: pass except: pass
if not brep_data: return tuple(brep_object, None)
styles = tuple(styles[i:i+4] for i in range(0, len(styles), 4))
if not brep_data: return shape_tuple(brep_object, None, styles)
try: try:
ss = OCC.BRepTools.BRepTools_ShapeSet() ss = OCC.BRepTools.BRepTools_ShapeSet()
@@ -88,7 +202,7 @@ def create_shape_from_serialization(brep_object):
except: pass except: pass
if is_product_shape: if is_product_shape:
return tuple(brep_object, occ_shape) return shape_tuple(brep_object, occ_shape, styles)
else: else:
return occ_shape return occ_shape
+1
View File
@@ -14464,6 +14464,7 @@ public:
/// HISTORY  New entity in Release IFC2x2. /// HISTORY  New entity in Release IFC2x2.
class IfcImageTexture : public IfcSurfaceTexture { class IfcImageTexture : public IfcSurfaceTexture {
public: public:
/// Location, provided as an URI, at which the image texture is electronically published.
std::string UrlReference() const; std::string UrlReference() const;
void setUrlReference(std::string v); void setUrlReference(std::string v);
virtual unsigned int getArgumentCount() const { return 5; } virtual unsigned int getArgumentCount() const { return 5; }
+93 -72
View File
@@ -66,10 +66,14 @@ void InitDescriptorMap() {
current->add("wrappedValue",false,IfcUtil::Argument_DOUBLE); current->add("wrappedValue",false,IfcUtil::Argument_DOUBLE);
current = entity_descriptor_map[Type::IfcAngularVelocityMeasure] = new IfcEntityDescriptor(Type::IfcAngularVelocityMeasure,0); current = entity_descriptor_map[Type::IfcAngularVelocityMeasure] = new IfcEntityDescriptor(Type::IfcAngularVelocityMeasure,0);
current->add("wrappedValue",false,IfcUtil::Argument_DOUBLE); current->add("wrappedValue",false,IfcUtil::Argument_DOUBLE);
current = entity_descriptor_map[Type::IfcArcIndex] = new IfcEntityDescriptor(Type::IfcArcIndex,0);
current->add("wrappedValue",false,IfcUtil::Argument_AGGREGATE_OF_INT);
current = entity_descriptor_map[Type::IfcAreaDensityMeasure] = new IfcEntityDescriptor(Type::IfcAreaDensityMeasure,0); current = entity_descriptor_map[Type::IfcAreaDensityMeasure] = new IfcEntityDescriptor(Type::IfcAreaDensityMeasure,0);
current->add("wrappedValue",false,IfcUtil::Argument_DOUBLE); current->add("wrappedValue",false,IfcUtil::Argument_DOUBLE);
current = entity_descriptor_map[Type::IfcAreaMeasure] = new IfcEntityDescriptor(Type::IfcAreaMeasure,0); current = entity_descriptor_map[Type::IfcAreaMeasure] = new IfcEntityDescriptor(Type::IfcAreaMeasure,0);
current->add("wrappedValue",false,IfcUtil::Argument_DOUBLE); current->add("wrappedValue",false,IfcUtil::Argument_DOUBLE);
current = entity_descriptor_map[Type::IfcBinary] = new IfcEntityDescriptor(Type::IfcBinary,0);
current->add("wrappedValue",false,IfcUtil::Argument_BINARY);
current = entity_descriptor_map[Type::IfcBoolean] = new IfcEntityDescriptor(Type::IfcBoolean,0); current = entity_descriptor_map[Type::IfcBoolean] = new IfcEntityDescriptor(Type::IfcBoolean,0);
current->add("wrappedValue",false,IfcUtil::Argument_BOOL); current->add("wrappedValue",false,IfcUtil::Argument_BOOL);
current = entity_descriptor_map[Type::IfcBoxAlignment] = new IfcEntityDescriptor(Type::IfcBoxAlignment,0); current = entity_descriptor_map[Type::IfcBoxAlignment] = new IfcEntityDescriptor(Type::IfcBoxAlignment,0);
@@ -156,6 +160,8 @@ void InitDescriptorMap() {
current->add("wrappedValue",false,IfcUtil::Argument_STRING); current->add("wrappedValue",false,IfcUtil::Argument_STRING);
current = entity_descriptor_map[Type::IfcLengthMeasure] = new IfcEntityDescriptor(Type::IfcLengthMeasure,0); current = entity_descriptor_map[Type::IfcLengthMeasure] = new IfcEntityDescriptor(Type::IfcLengthMeasure,0);
current->add("wrappedValue",false,IfcUtil::Argument_DOUBLE); current->add("wrappedValue",false,IfcUtil::Argument_DOUBLE);
current = entity_descriptor_map[Type::IfcLineIndex] = new IfcEntityDescriptor(Type::IfcLineIndex,0);
current->add("wrappedValue",false,IfcUtil::Argument_AGGREGATE_OF_INT);
current = entity_descriptor_map[Type::IfcLinearForceMeasure] = new IfcEntityDescriptor(Type::IfcLinearForceMeasure,0); current = entity_descriptor_map[Type::IfcLinearForceMeasure] = new IfcEntityDescriptor(Type::IfcLinearForceMeasure,0);
current->add("wrappedValue",false,IfcUtil::Argument_DOUBLE); current->add("wrappedValue",false,IfcUtil::Argument_DOUBLE);
current = entity_descriptor_map[Type::IfcLinearMomentMeasure] = new IfcEntityDescriptor(Type::IfcLinearMomentMeasure,0); current = entity_descriptor_map[Type::IfcLinearMomentMeasure] = new IfcEntityDescriptor(Type::IfcLinearMomentMeasure,0);
@@ -216,6 +222,8 @@ void InitDescriptorMap() {
current->add("wrappedValue",false,IfcUtil::Argument_DOUBLE); current->add("wrappedValue",false,IfcUtil::Argument_DOUBLE);
current = entity_descriptor_map[Type::IfcPlaneAngleMeasure] = new IfcEntityDescriptor(Type::IfcPlaneAngleMeasure,0); current = entity_descriptor_map[Type::IfcPlaneAngleMeasure] = new IfcEntityDescriptor(Type::IfcPlaneAngleMeasure,0);
current->add("wrappedValue",false,IfcUtil::Argument_DOUBLE); current->add("wrappedValue",false,IfcUtil::Argument_DOUBLE);
current = entity_descriptor_map[Type::IfcPositiveInteger] = new IfcEntityDescriptor(Type::IfcPositiveInteger,0);
current->add("wrappedValue",false,IfcUtil::Argument_INT);
current = entity_descriptor_map[Type::IfcPositiveLengthMeasure] = new IfcEntityDescriptor(Type::IfcPositiveLengthMeasure,0); current = entity_descriptor_map[Type::IfcPositiveLengthMeasure] = new IfcEntityDescriptor(Type::IfcPositiveLengthMeasure,0);
current->add("wrappedValue",false,IfcUtil::Argument_DOUBLE); current->add("wrappedValue",false,IfcUtil::Argument_DOUBLE);
current = entity_descriptor_map[Type::IfcPositivePlaneAngleMeasure] = new IfcEntityDescriptor(Type::IfcPositivePlaneAngleMeasure,0); current = entity_descriptor_map[Type::IfcPositivePlaneAngleMeasure] = new IfcEntityDescriptor(Type::IfcPositivePlaneAngleMeasure,0);
@@ -389,9 +397,9 @@ void InitDescriptorMap() {
current->add("SourceCRS",false,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcCoordinateReferenceSystemSelect); current->add("SourceCRS",false,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcCoordinateReferenceSystemSelect);
current->add("TargetCRS",false,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcCoordinateReferenceSystem); current->add("TargetCRS",false,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcCoordinateReferenceSystem);
current = entity_descriptor_map[Type::IfcCoordinateReferenceSystem] = new IfcEntityDescriptor(Type::IfcCoordinateReferenceSystem,0); current = entity_descriptor_map[Type::IfcCoordinateReferenceSystem] = new IfcEntityDescriptor(Type::IfcCoordinateReferenceSystem,0);
current->add("Name",true,IfcUtil::Argument_STRING,Type::IfcLabel); current->add("Name",false,IfcUtil::Argument_STRING,Type::IfcLabel);
current->add("Description",true,IfcUtil::Argument_STRING,Type::IfcText); current->add("Description",true,IfcUtil::Argument_STRING,Type::IfcText);
current->add("GeodeticDatum",false,IfcUtil::Argument_STRING,Type::IfcIdentifier); current->add("GeodeticDatum",true,IfcUtil::Argument_STRING,Type::IfcIdentifier);
current->add("VerticalDatum",true,IfcUtil::Argument_STRING,Type::IfcIdentifier); current->add("VerticalDatum",true,IfcUtil::Argument_STRING,Type::IfcIdentifier);
current = entity_descriptor_map[Type::IfcCostValue] = new IfcEntityDescriptor(Type::IfcCostValue,entity_descriptor_map.find(Type::IfcAppliedValue)->second); current = entity_descriptor_map[Type::IfcCostValue] = new IfcEntityDescriptor(Type::IfcCostValue,entity_descriptor_map.find(Type::IfcAppliedValue)->second);
@@ -498,7 +506,7 @@ void InitDescriptorMap() {
current = entity_descriptor_map[Type::IfcMetric] = new IfcEntityDescriptor(Type::IfcMetric,entity_descriptor_map.find(Type::IfcConstraint)->second); current = entity_descriptor_map[Type::IfcMetric] = new IfcEntityDescriptor(Type::IfcMetric,entity_descriptor_map.find(Type::IfcConstraint)->second);
current->add("Benchmark",false,IfcUtil::Argument_ENUMERATION,Type::IfcBenchmarkEnum); current->add("Benchmark",false,IfcUtil::Argument_ENUMERATION,Type::IfcBenchmarkEnum);
current->add("ValueSource",true,IfcUtil::Argument_STRING,Type::IfcLabel); current->add("ValueSource",true,IfcUtil::Argument_STRING,Type::IfcLabel);
current->add("DataValue",false,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcMetricValueSelect); current->add("DataValue",true,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcMetricValueSelect);
current->add("ReferencePath",true,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcReference); current->add("ReferencePath",true,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcReference);
current = entity_descriptor_map[Type::IfcMonetaryUnit] = new IfcEntityDescriptor(Type::IfcMonetaryUnit,0); current = entity_descriptor_map[Type::IfcMonetaryUnit] = new IfcEntityDescriptor(Type::IfcMonetaryUnit,0);
current->add("Currency",false,IfcUtil::Argument_STRING,Type::IfcLabel); current->add("Currency",false,IfcUtil::Argument_STRING,Type::IfcLabel);
@@ -561,9 +569,9 @@ void InitDescriptorMap() {
current->add("AssignedItems",false,IfcUtil::Argument_AGGREGATE_OF_ENTITY_INSTANCE,Type::IfcLayeredItem); current->add("AssignedItems",false,IfcUtil::Argument_AGGREGATE_OF_ENTITY_INSTANCE,Type::IfcLayeredItem);
current->add("Identifier",true,IfcUtil::Argument_STRING,Type::IfcIdentifier); current->add("Identifier",true,IfcUtil::Argument_STRING,Type::IfcIdentifier);
current = entity_descriptor_map[Type::IfcPresentationLayerWithStyle] = new IfcEntityDescriptor(Type::IfcPresentationLayerWithStyle,entity_descriptor_map.find(Type::IfcPresentationLayerAssignment)->second); current = entity_descriptor_map[Type::IfcPresentationLayerWithStyle] = new IfcEntityDescriptor(Type::IfcPresentationLayerWithStyle,entity_descriptor_map.find(Type::IfcPresentationLayerAssignment)->second);
current->add("LayerOn",false,IfcUtil::Argument_BOOL,Type::UNDEFINED); current->add("LayerOn",false,IfcUtil::Argument_BOOL,Type::IfcLogical);
current->add("LayerFrozen",false,IfcUtil::Argument_BOOL,Type::UNDEFINED); current->add("LayerFrozen",false,IfcUtil::Argument_BOOL,Type::IfcLogical);
current->add("LayerBlocked",false,IfcUtil::Argument_BOOL,Type::UNDEFINED); current->add("LayerBlocked",false,IfcUtil::Argument_BOOL,Type::IfcLogical);
current->add("LayerStyles",false,IfcUtil::Argument_AGGREGATE_OF_ENTITY_INSTANCE,Type::IfcPresentationStyle); current->add("LayerStyles",false,IfcUtil::Argument_AGGREGATE_OF_ENTITY_INSTANCE,Type::IfcPresentationStyle);
current = entity_descriptor_map[Type::IfcPresentationStyle] = new IfcEntityDescriptor(Type::IfcPresentationStyle,0); current = entity_descriptor_map[Type::IfcPresentationStyle] = new IfcEntityDescriptor(Type::IfcPresentationStyle,0);
current->add("Name",true,IfcUtil::Argument_STRING,Type::IfcLabel); current->add("Name",true,IfcUtil::Argument_STRING,Type::IfcLabel);
@@ -617,7 +625,7 @@ void InitDescriptorMap() {
current->add("TypeIdentifier",true,IfcUtil::Argument_STRING,Type::IfcIdentifier); current->add("TypeIdentifier",true,IfcUtil::Argument_STRING,Type::IfcIdentifier);
current->add("AttributeIdentifier",true,IfcUtil::Argument_STRING,Type::IfcIdentifier); current->add("AttributeIdentifier",true,IfcUtil::Argument_STRING,Type::IfcIdentifier);
current->add("InstanceName",true,IfcUtil::Argument_STRING,Type::IfcLabel); current->add("InstanceName",true,IfcUtil::Argument_STRING,Type::IfcLabel);
current->add("ListPositions",true,IfcUtil::Argument_AGGREGATE_OF_INT,Type::UNDEFINED); current->add("ListPositions",true,IfcUtil::Argument_AGGREGATE_OF_INT,Type::IfcInteger);
current->add("InnerReference",true,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcReference); current->add("InnerReference",true,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcReference);
current = entity_descriptor_map[Type::IfcRepresentation] = new IfcEntityDescriptor(Type::IfcRepresentation,0); current = entity_descriptor_map[Type::IfcRepresentation] = new IfcEntityDescriptor(Type::IfcRepresentation,0);
current->add("ContextOfItems",false,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcRepresentationContext); current->add("ContextOfItems",false,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcRepresentationContext);
@@ -651,7 +659,7 @@ void InitDescriptorMap() {
current->add("ShapeRepresentations",false,IfcUtil::Argument_AGGREGATE_OF_ENTITY_INSTANCE,Type::IfcShapeModel); current->add("ShapeRepresentations",false,IfcUtil::Argument_AGGREGATE_OF_ENTITY_INSTANCE,Type::IfcShapeModel);
current->add("Name",true,IfcUtil::Argument_STRING,Type::IfcLabel); current->add("Name",true,IfcUtil::Argument_STRING,Type::IfcLabel);
current->add("Description",true,IfcUtil::Argument_STRING,Type::IfcText); current->add("Description",true,IfcUtil::Argument_STRING,Type::IfcText);
current->add("ProductDefinitional",false,IfcUtil::Argument_BOOL,Type::UNDEFINED); current->add("ProductDefinitional",false,IfcUtil::Argument_BOOL,Type::IfcLogical);
current->add("PartOfProductDefinitionShape",true,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcProductRepresentationSelect); current->add("PartOfProductDefinitionShape",true,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcProductRepresentationSelect);
current = entity_descriptor_map[Type::IfcShapeModel] = new IfcEntityDescriptor(Type::IfcShapeModel,entity_descriptor_map.find(Type::IfcRepresentation)->second); current = entity_descriptor_map[Type::IfcShapeModel] = new IfcEntityDescriptor(Type::IfcShapeModel,entity_descriptor_map.find(Type::IfcRepresentation)->second);
@@ -700,8 +708,8 @@ void InitDescriptorMap() {
current = entity_descriptor_map[Type::IfcSurfaceStyleWithTextures] = new IfcEntityDescriptor(Type::IfcSurfaceStyleWithTextures,entity_descriptor_map.find(Type::IfcPresentationItem)->second); current = entity_descriptor_map[Type::IfcSurfaceStyleWithTextures] = new IfcEntityDescriptor(Type::IfcSurfaceStyleWithTextures,entity_descriptor_map.find(Type::IfcPresentationItem)->second);
current->add("Textures",false,IfcUtil::Argument_AGGREGATE_OF_ENTITY_INSTANCE,Type::IfcSurfaceTexture); current->add("Textures",false,IfcUtil::Argument_AGGREGATE_OF_ENTITY_INSTANCE,Type::IfcSurfaceTexture);
current = entity_descriptor_map[Type::IfcSurfaceTexture] = new IfcEntityDescriptor(Type::IfcSurfaceTexture,entity_descriptor_map.find(Type::IfcPresentationItem)->second); current = entity_descriptor_map[Type::IfcSurfaceTexture] = new IfcEntityDescriptor(Type::IfcSurfaceTexture,entity_descriptor_map.find(Type::IfcPresentationItem)->second);
current->add("RepeatS",false,IfcUtil::Argument_BOOL,Type::UNDEFINED); current->add("RepeatS",false,IfcUtil::Argument_BOOL,Type::IfcBoolean);
current->add("RepeatT",false,IfcUtil::Argument_BOOL,Type::UNDEFINED); current->add("RepeatT",false,IfcUtil::Argument_BOOL,Type::IfcBoolean);
current->add("Mode",true,IfcUtil::Argument_STRING,Type::IfcIdentifier); current->add("Mode",true,IfcUtil::Argument_STRING,Type::IfcIdentifier);
current->add("TextureTransform",true,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcCartesianTransformationOperator2D); current->add("TextureTransform",true,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcCartesianTransformationOperator2D);
current->add("Parameter",true,IfcUtil::Argument_AGGREGATE_OF_STRING,Type::IfcIdentifier); current->add("Parameter",true,IfcUtil::Argument_AGGREGATE_OF_STRING,Type::IfcIdentifier);
@@ -717,7 +725,7 @@ void InitDescriptorMap() {
current->add("ReferencePath",true,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcReference); current->add("ReferencePath",true,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcReference);
current = entity_descriptor_map[Type::IfcTableRow] = new IfcEntityDescriptor(Type::IfcTableRow,0); current = entity_descriptor_map[Type::IfcTableRow] = new IfcEntityDescriptor(Type::IfcTableRow,0);
current->add("RowCells",true,IfcUtil::Argument_AGGREGATE_OF_ENTITY_INSTANCE,Type::IfcValue); current->add("RowCells",true,IfcUtil::Argument_AGGREGATE_OF_ENTITY_INSTANCE,Type::IfcValue);
current->add("IsHeading",true,IfcUtil::Argument_BOOL,Type::UNDEFINED); current->add("IsHeading",true,IfcUtil::Argument_BOOL,Type::IfcBoolean);
current = entity_descriptor_map[Type::IfcTaskTime] = new IfcEntityDescriptor(Type::IfcTaskTime,entity_descriptor_map.find(Type::IfcSchedulingTime)->second); current = entity_descriptor_map[Type::IfcTaskTime] = new IfcEntityDescriptor(Type::IfcTaskTime,entity_descriptor_map.find(Type::IfcSchedulingTime)->second);
current->add("DurationType",true,IfcUtil::Argument_ENUMERATION,Type::IfcTaskDurationEnum); current->add("DurationType",true,IfcUtil::Argument_ENUMERATION,Type::IfcTaskDurationEnum);
current->add("ScheduleDuration",true,IfcUtil::Argument_STRING,Type::IfcDuration); current->add("ScheduleDuration",true,IfcUtil::Argument_STRING,Type::IfcDuration);
@@ -729,7 +737,7 @@ void InitDescriptorMap() {
current->add("LateFinish",true,IfcUtil::Argument_STRING,Type::IfcDateTime); current->add("LateFinish",true,IfcUtil::Argument_STRING,Type::IfcDateTime);
current->add("FreeFloat",true,IfcUtil::Argument_STRING,Type::IfcDuration); current->add("FreeFloat",true,IfcUtil::Argument_STRING,Type::IfcDuration);
current->add("TotalFloat",true,IfcUtil::Argument_STRING,Type::IfcDuration); current->add("TotalFloat",true,IfcUtil::Argument_STRING,Type::IfcDuration);
current->add("IsCritical",true,IfcUtil::Argument_BOOL,Type::UNDEFINED); current->add("IsCritical",true,IfcUtil::Argument_BOOL,Type::IfcBoolean);
current->add("StatusTime",true,IfcUtil::Argument_STRING,Type::IfcDateTime); current->add("StatusTime",true,IfcUtil::Argument_STRING,Type::IfcDateTime);
current->add("ActualDuration",true,IfcUtil::Argument_STRING,Type::IfcDuration); current->add("ActualDuration",true,IfcUtil::Argument_STRING,Type::IfcDuration);
current->add("ActualStart",true,IfcUtil::Argument_STRING,Type::IfcDateTime); current->add("ActualStart",true,IfcUtil::Argument_STRING,Type::IfcDateTime);
@@ -737,7 +745,7 @@ void InitDescriptorMap() {
current->add("RemainingTime",true,IfcUtil::Argument_STRING,Type::IfcDuration); current->add("RemainingTime",true,IfcUtil::Argument_STRING,Type::IfcDuration);
current->add("Completion",true,IfcUtil::Argument_DOUBLE,Type::IfcPositiveRatioMeasure); current->add("Completion",true,IfcUtil::Argument_DOUBLE,Type::IfcPositiveRatioMeasure);
current = entity_descriptor_map[Type::IfcTaskTimeRecurring] = new IfcEntityDescriptor(Type::IfcTaskTimeRecurring,entity_descriptor_map.find(Type::IfcTaskTime)->second); current = entity_descriptor_map[Type::IfcTaskTimeRecurring] = new IfcEntityDescriptor(Type::IfcTaskTimeRecurring,entity_descriptor_map.find(Type::IfcTaskTime)->second);
current->add("Recurrance",false,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcRecurrencePattern); current->add("Recurrence",false,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcRecurrencePattern);
current = entity_descriptor_map[Type::IfcTelecomAddress] = new IfcEntityDescriptor(Type::IfcTelecomAddress,entity_descriptor_map.find(Type::IfcAddress)->second); current = entity_descriptor_map[Type::IfcTelecomAddress] = new IfcEntityDescriptor(Type::IfcTelecomAddress,entity_descriptor_map.find(Type::IfcAddress)->second);
current->add("TelephoneNumbers",true,IfcUtil::Argument_AGGREGATE_OF_STRING,Type::IfcLabel); current->add("TelephoneNumbers",true,IfcUtil::Argument_AGGREGATE_OF_STRING,Type::IfcLabel);
current->add("FacsimileNumbers",true,IfcUtil::Argument_AGGREGATE_OF_STRING,Type::IfcLabel); current->add("FacsimileNumbers",true,IfcUtil::Argument_AGGREGATE_OF_STRING,Type::IfcLabel);
@@ -749,7 +757,7 @@ void InitDescriptorMap() {
current->add("TextCharacterAppearance",true,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcTextStyleForDefinedFont); current->add("TextCharacterAppearance",true,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcTextStyleForDefinedFont);
current->add("TextStyle",true,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcTextStyleTextModel); current->add("TextStyle",true,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcTextStyleTextModel);
current->add("TextFontStyle",false,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcTextFontSelect); current->add("TextFontStyle",false,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcTextFontSelect);
current->add("ModelOrDraughting",true,IfcUtil::Argument_BOOL,Type::UNDEFINED); current->add("ModelOrDraughting",true,IfcUtil::Argument_BOOL,Type::IfcBoolean);
current = entity_descriptor_map[Type::IfcTextStyleForDefinedFont] = new IfcEntityDescriptor(Type::IfcTextStyleForDefinedFont,entity_descriptor_map.find(Type::IfcPresentationItem)->second); current = entity_descriptor_map[Type::IfcTextStyleForDefinedFont] = new IfcEntityDescriptor(Type::IfcTextStyleForDefinedFont,entity_descriptor_map.find(Type::IfcPresentationItem)->second);
current->add("Colour",false,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcColour); current->add("Colour",false,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcColour);
current->add("BackgroundColour",true,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcColour); current->add("BackgroundColour",true,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcColour);
@@ -815,7 +823,7 @@ void InitDescriptorMap() {
current->add("InnerCurves",false,IfcUtil::Argument_AGGREGATE_OF_ENTITY_INSTANCE,Type::IfcCurve); current->add("InnerCurves",false,IfcUtil::Argument_AGGREGATE_OF_ENTITY_INSTANCE,Type::IfcCurve);
current = entity_descriptor_map[Type::IfcBlobTexture] = new IfcEntityDescriptor(Type::IfcBlobTexture,entity_descriptor_map.find(Type::IfcSurfaceTexture)->second); current = entity_descriptor_map[Type::IfcBlobTexture] = new IfcEntityDescriptor(Type::IfcBlobTexture,entity_descriptor_map.find(Type::IfcSurfaceTexture)->second);
current->add("RasterFormat",false,IfcUtil::Argument_STRING,Type::IfcIdentifier); current->add("RasterFormat",false,IfcUtil::Argument_STRING,Type::IfcIdentifier);
current->add("RasterCode",false,IfcUtil::Argument_BINARY,Type::UNDEFINED); current->add("RasterCode",false,IfcUtil::Argument_BINARY,Type::IfcBinary);
current = entity_descriptor_map[Type::IfcCenterLineProfileDef] = new IfcEntityDescriptor(Type::IfcCenterLineProfileDef,entity_descriptor_map.find(Type::IfcArbitraryOpenProfileDef)->second); current = entity_descriptor_map[Type::IfcCenterLineProfileDef] = new IfcEntityDescriptor(Type::IfcCenterLineProfileDef,entity_descriptor_map.find(Type::IfcArbitraryOpenProfileDef)->second);
current->add("Thickness",false,IfcUtil::Argument_DOUBLE,Type::IfcPositiveLengthMeasure); current->add("Thickness",false,IfcUtil::Argument_DOUBLE,Type::IfcPositiveLengthMeasure);
current = entity_descriptor_map[Type::IfcClassification] = new IfcEntityDescriptor(Type::IfcClassification,entity_descriptor_map.find(Type::IfcExternalInformation)->second); current = entity_descriptor_map[Type::IfcClassification] = new IfcEntityDescriptor(Type::IfcClassification,entity_descriptor_map.find(Type::IfcExternalInformation)->second);
@@ -863,7 +871,7 @@ void InitDescriptorMap() {
current->add("CurveFont",true,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcCurveFontOrScaledCurveFontSelect); current->add("CurveFont",true,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcCurveFontOrScaledCurveFontSelect);
current->add("CurveWidth",true,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcSizeSelect); current->add("CurveWidth",true,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcSizeSelect);
current->add("CurveColour",true,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcColour); current->add("CurveColour",true,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcColour);
current->add("ModelOrDraughting",true,IfcUtil::Argument_BOOL,Type::UNDEFINED); current->add("ModelOrDraughting",true,IfcUtil::Argument_BOOL,Type::IfcBoolean);
current = entity_descriptor_map[Type::IfcCurveStyleFont] = new IfcEntityDescriptor(Type::IfcCurveStyleFont,entity_descriptor_map.find(Type::IfcPresentationItem)->second); current = entity_descriptor_map[Type::IfcCurveStyleFont] = new IfcEntityDescriptor(Type::IfcCurveStyleFont,entity_descriptor_map.find(Type::IfcPresentationItem)->second);
current->add("Name",true,IfcUtil::Argument_STRING,Type::IfcLabel); current->add("Name",true,IfcUtil::Argument_STRING,Type::IfcLabel);
current->add("PatternList",false,IfcUtil::Argument_AGGREGATE_OF_ENTITY_INSTANCE,Type::IfcCurveStyleFontPattern); current->add("PatternList",false,IfcUtil::Argument_AGGREGATE_OF_ENTITY_INSTANCE,Type::IfcCurveStyleFontPattern);
@@ -908,7 +916,7 @@ void InitDescriptorMap() {
current->add("EdgeEnd",false,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcVertex); current->add("EdgeEnd",false,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcVertex);
current = entity_descriptor_map[Type::IfcEdgeCurve] = new IfcEntityDescriptor(Type::IfcEdgeCurve,entity_descriptor_map.find(Type::IfcEdge)->second); current = entity_descriptor_map[Type::IfcEdgeCurve] = new IfcEntityDescriptor(Type::IfcEdgeCurve,entity_descriptor_map.find(Type::IfcEdge)->second);
current->add("EdgeGeometry",false,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcCurve); current->add("EdgeGeometry",false,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcCurve);
current->add("SameSense",false,IfcUtil::Argument_BOOL,Type::UNDEFINED); current->add("SameSense",false,IfcUtil::Argument_BOOL,Type::IfcBoolean);
current = entity_descriptor_map[Type::IfcEventTime] = new IfcEntityDescriptor(Type::IfcEventTime,entity_descriptor_map.find(Type::IfcSchedulingTime)->second); current = entity_descriptor_map[Type::IfcEventTime] = new IfcEntityDescriptor(Type::IfcEventTime,entity_descriptor_map.find(Type::IfcSchedulingTime)->second);
current->add("ActualDate",true,IfcUtil::Argument_STRING,Type::IfcDateTime); current->add("ActualDate",true,IfcUtil::Argument_STRING,Type::IfcDateTime);
current->add("EarlyDate",true,IfcUtil::Argument_STRING,Type::IfcDateTime); current->add("EarlyDate",true,IfcUtil::Argument_STRING,Type::IfcDateTime);
@@ -925,12 +933,12 @@ void InitDescriptorMap() {
current->add("Bounds",false,IfcUtil::Argument_AGGREGATE_OF_ENTITY_INSTANCE,Type::IfcFaceBound); current->add("Bounds",false,IfcUtil::Argument_AGGREGATE_OF_ENTITY_INSTANCE,Type::IfcFaceBound);
current = entity_descriptor_map[Type::IfcFaceBound] = new IfcEntityDescriptor(Type::IfcFaceBound,entity_descriptor_map.find(Type::IfcTopologicalRepresentationItem)->second); current = entity_descriptor_map[Type::IfcFaceBound] = new IfcEntityDescriptor(Type::IfcFaceBound,entity_descriptor_map.find(Type::IfcTopologicalRepresentationItem)->second);
current->add("Bound",false,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcLoop); current->add("Bound",false,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcLoop);
current->add("Orientation",false,IfcUtil::Argument_BOOL,Type::UNDEFINED); current->add("Orientation",false,IfcUtil::Argument_BOOL,Type::IfcBoolean);
current = entity_descriptor_map[Type::IfcFaceOuterBound] = new IfcEntityDescriptor(Type::IfcFaceOuterBound,entity_descriptor_map.find(Type::IfcFaceBound)->second); current = entity_descriptor_map[Type::IfcFaceOuterBound] = new IfcEntityDescriptor(Type::IfcFaceOuterBound,entity_descriptor_map.find(Type::IfcFaceBound)->second);
current = entity_descriptor_map[Type::IfcFaceSurface] = new IfcEntityDescriptor(Type::IfcFaceSurface,entity_descriptor_map.find(Type::IfcFace)->second); current = entity_descriptor_map[Type::IfcFaceSurface] = new IfcEntityDescriptor(Type::IfcFaceSurface,entity_descriptor_map.find(Type::IfcFace)->second);
current->add("FaceSurface",false,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcSurface); current->add("FaceSurface",false,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcSurface);
current->add("SameSense",false,IfcUtil::Argument_BOOL,Type::UNDEFINED); current->add("SameSense",false,IfcUtil::Argument_BOOL,Type::IfcBoolean);
current = entity_descriptor_map[Type::IfcFailureConnectionCondition] = new IfcEntityDescriptor(Type::IfcFailureConnectionCondition,entity_descriptor_map.find(Type::IfcStructuralConnectionCondition)->second); current = entity_descriptor_map[Type::IfcFailureConnectionCondition] = new IfcEntityDescriptor(Type::IfcFailureConnectionCondition,entity_descriptor_map.find(Type::IfcStructuralConnectionCondition)->second);
current->add("TensionFailureX",true,IfcUtil::Argument_DOUBLE,Type::IfcForceMeasure); current->add("TensionFailureX",true,IfcUtil::Argument_DOUBLE,Type::IfcForceMeasure);
current->add("TensionFailureY",true,IfcUtil::Argument_DOUBLE,Type::IfcForceMeasure); current->add("TensionFailureY",true,IfcUtil::Argument_DOUBLE,Type::IfcForceMeasure);
@@ -940,10 +948,10 @@ void InitDescriptorMap() {
current->add("CompressionFailureZ",true,IfcUtil::Argument_DOUBLE,Type::IfcForceMeasure); current->add("CompressionFailureZ",true,IfcUtil::Argument_DOUBLE,Type::IfcForceMeasure);
current = entity_descriptor_map[Type::IfcFillAreaStyle] = new IfcEntityDescriptor(Type::IfcFillAreaStyle,entity_descriptor_map.find(Type::IfcPresentationStyle)->second); current = entity_descriptor_map[Type::IfcFillAreaStyle] = new IfcEntityDescriptor(Type::IfcFillAreaStyle,entity_descriptor_map.find(Type::IfcPresentationStyle)->second);
current->add("FillStyles",false,IfcUtil::Argument_AGGREGATE_OF_ENTITY_INSTANCE,Type::IfcFillStyleSelect); current->add("FillStyles",false,IfcUtil::Argument_AGGREGATE_OF_ENTITY_INSTANCE,Type::IfcFillStyleSelect);
current->add("ModelorDraughting",true,IfcUtil::Argument_BOOL,Type::UNDEFINED); current->add("ModelorDraughting",true,IfcUtil::Argument_BOOL,Type::IfcBoolean);
current = entity_descriptor_map[Type::IfcGeometricRepresentationContext] = new IfcEntityDescriptor(Type::IfcGeometricRepresentationContext,entity_descriptor_map.find(Type::IfcRepresentationContext)->second); current = entity_descriptor_map[Type::IfcGeometricRepresentationContext] = new IfcEntityDescriptor(Type::IfcGeometricRepresentationContext,entity_descriptor_map.find(Type::IfcRepresentationContext)->second);
current->add("CoordinateSpaceDimension",false,IfcUtil::Argument_INT,Type::IfcDimensionCount); current->add("CoordinateSpaceDimension",false,IfcUtil::Argument_INT,Type::IfcDimensionCount);
current->add("Precision",true,IfcUtil::Argument_DOUBLE,Type::UNDEFINED); current->add("Precision",true,IfcUtil::Argument_DOUBLE,Type::IfcReal);
current->add("WorldCoordinateSystem",false,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcAxis2Placement); current->add("WorldCoordinateSystem",false,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcAxis2Placement);
current->add("TrueNorth",true,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcDirection); current->add("TrueNorth",true,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcDirection);
current = entity_descriptor_map[Type::IfcGeometricRepresentationItem] = new IfcEntityDescriptor(Type::IfcGeometricRepresentationItem,entity_descriptor_map.find(Type::IfcRepresentationItem)->second); current = entity_descriptor_map[Type::IfcGeometricRepresentationItem] = new IfcEntityDescriptor(Type::IfcGeometricRepresentationItem,entity_descriptor_map.find(Type::IfcRepresentationItem)->second);
@@ -960,19 +968,19 @@ void InitDescriptorMap() {
current->add("PlacementRefDirection",true,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcGridPlacementDirectionSelect); current->add("PlacementRefDirection",true,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcGridPlacementDirectionSelect);
current = entity_descriptor_map[Type::IfcHalfSpaceSolid] = new IfcEntityDescriptor(Type::IfcHalfSpaceSolid,entity_descriptor_map.find(Type::IfcGeometricRepresentationItem)->second); current = entity_descriptor_map[Type::IfcHalfSpaceSolid] = new IfcEntityDescriptor(Type::IfcHalfSpaceSolid,entity_descriptor_map.find(Type::IfcGeometricRepresentationItem)->second);
current->add("BaseSurface",false,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcSurface); current->add("BaseSurface",false,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcSurface);
current->add("AgreementFlag",false,IfcUtil::Argument_BOOL,Type::UNDEFINED); current->add("AgreementFlag",false,IfcUtil::Argument_BOOL,Type::IfcBoolean);
current = entity_descriptor_map[Type::IfcImageTexture] = new IfcEntityDescriptor(Type::IfcImageTexture,entity_descriptor_map.find(Type::IfcSurfaceTexture)->second); current = entity_descriptor_map[Type::IfcImageTexture] = new IfcEntityDescriptor(Type::IfcImageTexture,entity_descriptor_map.find(Type::IfcSurfaceTexture)->second);
current->add("URLReference",false,IfcUtil::Argument_STRING,Type::IfcURIReference); current->add("URLReference",false,IfcUtil::Argument_STRING,Type::IfcURIReference);
current = entity_descriptor_map[Type::IfcIndexedColourMap] = new IfcEntityDescriptor(Type::IfcIndexedColourMap,entity_descriptor_map.find(Type::IfcPresentationItem)->second); current = entity_descriptor_map[Type::IfcIndexedColourMap] = new IfcEntityDescriptor(Type::IfcIndexedColourMap,entity_descriptor_map.find(Type::IfcPresentationItem)->second);
current->add("MappedTo",false,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcTessellatedFaceSet); current->add("MappedTo",false,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcTessellatedFaceSet);
current->add("Overrides",true,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcSurfaceStyleShading); current->add("Overrides",true,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcSurfaceStyleShading);
current->add("Colours",false,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcColourRgbList); current->add("Colours",false,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcColourRgbList);
current->add("ColourIndex",false,IfcUtil::Argument_AGGREGATE_OF_INT,Type::UNDEFINED); current->add("ColourIndex",false,IfcUtil::Argument_AGGREGATE_OF_INT,Type::IfcPositiveInteger);
current = entity_descriptor_map[Type::IfcIndexedTextureMap] = new IfcEntityDescriptor(Type::IfcIndexedTextureMap,entity_descriptor_map.find(Type::IfcTextureCoordinate)->second); current = entity_descriptor_map[Type::IfcIndexedTextureMap] = new IfcEntityDescriptor(Type::IfcIndexedTextureMap,entity_descriptor_map.find(Type::IfcTextureCoordinate)->second);
current->add("MappedTo",false,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcTessellatedFaceSet); current->add("MappedTo",false,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcTessellatedFaceSet);
current->add("TexCoords",false,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcTextureVertexList); current->add("TexCoords",false,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcTextureVertexList);
current = entity_descriptor_map[Type::IfcIndexedTriangleTextureMap] = new IfcEntityDescriptor(Type::IfcIndexedTriangleTextureMap,entity_descriptor_map.find(Type::IfcIndexedTextureMap)->second); current = entity_descriptor_map[Type::IfcIndexedTriangleTextureMap] = new IfcEntityDescriptor(Type::IfcIndexedTriangleTextureMap,entity_descriptor_map.find(Type::IfcIndexedTextureMap)->second);
current->add("TexCoordIndex",true,IfcUtil::Argument_AGGREGATE_OF_AGGREGATE_OF_INT,Type::UNDEFINED); current->add("TexCoordIndex",true,IfcUtil::Argument_AGGREGATE_OF_AGGREGATE_OF_INT,Type::IfcPositiveInteger);
current = entity_descriptor_map[Type::IfcIrregularTimeSeries] = new IfcEntityDescriptor(Type::IfcIrregularTimeSeries,entity_descriptor_map.find(Type::IfcTimeSeries)->second); current = entity_descriptor_map[Type::IfcIrregularTimeSeries] = new IfcEntityDescriptor(Type::IfcIrregularTimeSeries,entity_descriptor_map.find(Type::IfcTimeSeries)->second);
current->add("Values",false,IfcUtil::Argument_AGGREGATE_OF_ENTITY_INSTANCE,Type::IfcIrregularTimeSeriesValue); current->add("Values",false,IfcUtil::Argument_AGGREGATE_OF_ENTITY_INSTANCE,Type::IfcIrregularTimeSeriesValue);
current = entity_descriptor_map[Type::IfcLagTime] = new IfcEntityDescriptor(Type::IfcLagTime,entity_descriptor_map.find(Type::IfcSchedulingTime)->second); current = entity_descriptor_map[Type::IfcLagTime] = new IfcEntityDescriptor(Type::IfcLagTime,entity_descriptor_map.find(Type::IfcSchedulingTime)->second);
@@ -1059,7 +1067,7 @@ void InitDescriptorMap() {
current->add("RelatedOrganizations",false,IfcUtil::Argument_AGGREGATE_OF_ENTITY_INSTANCE,Type::IfcOrganization); current->add("RelatedOrganizations",false,IfcUtil::Argument_AGGREGATE_OF_ENTITY_INSTANCE,Type::IfcOrganization);
current = entity_descriptor_map[Type::IfcOrientedEdge] = new IfcEntityDescriptor(Type::IfcOrientedEdge,entity_descriptor_map.find(Type::IfcEdge)->second); current = entity_descriptor_map[Type::IfcOrientedEdge] = new IfcEntityDescriptor(Type::IfcOrientedEdge,entity_descriptor_map.find(Type::IfcEdge)->second);
current->add("EdgeElement",false,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcEdge); current->add("EdgeElement",false,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcEdge);
current->add("Orientation",false,IfcUtil::Argument_BOOL,Type::UNDEFINED); current->add("Orientation",false,IfcUtil::Argument_BOOL,Type::IfcBoolean);
current = entity_descriptor_map[Type::IfcParameterizedProfileDef] = new IfcEntityDescriptor(Type::IfcParameterizedProfileDef,entity_descriptor_map.find(Type::IfcProfileDef)->second); current = entity_descriptor_map[Type::IfcParameterizedProfileDef] = new IfcEntityDescriptor(Type::IfcParameterizedProfileDef,entity_descriptor_map.find(Type::IfcProfileDef)->second);
current->add("Position",true,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcAxis2Placement2D); current->add("Position",true,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcAxis2Placement2D);
current = entity_descriptor_map[Type::IfcPath] = new IfcEntityDescriptor(Type::IfcPath,entity_descriptor_map.find(Type::IfcTopologicalRepresentationItem)->second); current = entity_descriptor_map[Type::IfcPath] = new IfcEntityDescriptor(Type::IfcPath,entity_descriptor_map.find(Type::IfcTopologicalRepresentationItem)->second);
@@ -1073,7 +1081,7 @@ void InitDescriptorMap() {
current->add("Width",false,IfcUtil::Argument_INT,Type::IfcInteger); current->add("Width",false,IfcUtil::Argument_INT,Type::IfcInteger);
current->add("Height",false,IfcUtil::Argument_INT,Type::IfcInteger); current->add("Height",false,IfcUtil::Argument_INT,Type::IfcInteger);
current->add("ColourComponents",false,IfcUtil::Argument_INT,Type::IfcInteger); current->add("ColourComponents",false,IfcUtil::Argument_INT,Type::IfcInteger);
current->add("Pixel",false,IfcUtil::Argument_AGGREGATE_OF_BINARY,Type::UNDEFINED); current->add("Pixel",false,IfcUtil::Argument_AGGREGATE_OF_BINARY,Type::IfcBinary);
current = entity_descriptor_map[Type::IfcPlacement] = new IfcEntityDescriptor(Type::IfcPlacement,entity_descriptor_map.find(Type::IfcGeometricRepresentationItem)->second); current = entity_descriptor_map[Type::IfcPlacement] = new IfcEntityDescriptor(Type::IfcPlacement,entity_descriptor_map.find(Type::IfcGeometricRepresentationItem)->second);
current->add("Location",false,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcCartesianPoint); current->add("Location",false,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcCartesianPoint);
current = entity_descriptor_map[Type::IfcPlanarExtent] = new IfcEntityDescriptor(Type::IfcPlanarExtent,entity_descriptor_map.find(Type::IfcGeometricRepresentationItem)->second); current = entity_descriptor_map[Type::IfcPlanarExtent] = new IfcEntityDescriptor(Type::IfcPlanarExtent,entity_descriptor_map.find(Type::IfcGeometricRepresentationItem)->second);
@@ -1146,7 +1154,7 @@ void InitDescriptorMap() {
current->add("ScheduleFinish",true,IfcUtil::Argument_STRING,Type::IfcDateTime); current->add("ScheduleFinish",true,IfcUtil::Argument_STRING,Type::IfcDateTime);
current->add("ScheduleContour",true,IfcUtil::Argument_STRING,Type::IfcLabel); current->add("ScheduleContour",true,IfcUtil::Argument_STRING,Type::IfcLabel);
current->add("LevelingDelay",true,IfcUtil::Argument_STRING,Type::IfcDuration); current->add("LevelingDelay",true,IfcUtil::Argument_STRING,Type::IfcDuration);
current->add("IsOverAllocated",true,IfcUtil::Argument_BOOL,Type::UNDEFINED); current->add("IsOverAllocated",true,IfcUtil::Argument_BOOL,Type::IfcBoolean);
current->add("StatusTime",true,IfcUtil::Argument_STRING,Type::IfcDateTime); current->add("StatusTime",true,IfcUtil::Argument_STRING,Type::IfcDateTime);
current->add("ActualWork",true,IfcUtil::Argument_STRING,Type::IfcDuration); current->add("ActualWork",true,IfcUtil::Argument_STRING,Type::IfcDuration);
current->add("ActualUsage",true,IfcUtil::Argument_DOUBLE,Type::IfcPositiveRatioMeasure); current->add("ActualUsage",true,IfcUtil::Argument_DOUBLE,Type::IfcPositiveRatioMeasure);
@@ -1298,8 +1306,8 @@ void InitDescriptorMap() {
current = entity_descriptor_map[Type::IfcWindowStyle] = new IfcEntityDescriptor(Type::IfcWindowStyle,entity_descriptor_map.find(Type::IfcTypeProduct)->second); current = entity_descriptor_map[Type::IfcWindowStyle] = new IfcEntityDescriptor(Type::IfcWindowStyle,entity_descriptor_map.find(Type::IfcTypeProduct)->second);
current->add("ConstructionType",false,IfcUtil::Argument_ENUMERATION,Type::IfcWindowStyleConstructionEnum); current->add("ConstructionType",false,IfcUtil::Argument_ENUMERATION,Type::IfcWindowStyleConstructionEnum);
current->add("OperationType",false,IfcUtil::Argument_ENUMERATION,Type::IfcWindowStyleOperationEnum); current->add("OperationType",false,IfcUtil::Argument_ENUMERATION,Type::IfcWindowStyleOperationEnum);
current->add("ParameterTakesPrecedence",false,IfcUtil::Argument_BOOL,Type::UNDEFINED); current->add("ParameterTakesPrecedence",false,IfcUtil::Argument_BOOL,Type::IfcBoolean);
current->add("Sizeable",false,IfcUtil::Argument_BOOL,Type::UNDEFINED); current->add("Sizeable",false,IfcUtil::Argument_BOOL,Type::IfcBoolean);
current = entity_descriptor_map[Type::IfcZShapeProfileDef] = new IfcEntityDescriptor(Type::IfcZShapeProfileDef,entity_descriptor_map.find(Type::IfcParameterizedProfileDef)->second); current = entity_descriptor_map[Type::IfcZShapeProfileDef] = new IfcEntityDescriptor(Type::IfcZShapeProfileDef,entity_descriptor_map.find(Type::IfcParameterizedProfileDef)->second);
current->add("Depth",false,IfcUtil::Argument_DOUBLE,Type::IfcPositiveLengthMeasure); current->add("Depth",false,IfcUtil::Argument_DOUBLE,Type::IfcPositiveLengthMeasure);
current->add("FlangeWidth",false,IfcUtil::Argument_DOUBLE,Type::IfcPositiveLengthMeasure); current->add("FlangeWidth",false,IfcUtil::Argument_DOUBLE,Type::IfcPositiveLengthMeasure);
@@ -1355,22 +1363,24 @@ void InitDescriptorMap() {
current->add("Coordinates",false,IfcUtil::Argument_AGGREGATE_OF_DOUBLE,Type::IfcLengthMeasure); current->add("Coordinates",false,IfcUtil::Argument_AGGREGATE_OF_DOUBLE,Type::IfcLengthMeasure);
current = entity_descriptor_map[Type::IfcCartesianPointList] = new IfcEntityDescriptor(Type::IfcCartesianPointList,entity_descriptor_map.find(Type::IfcGeometricRepresentationItem)->second); current = entity_descriptor_map[Type::IfcCartesianPointList] = new IfcEntityDescriptor(Type::IfcCartesianPointList,entity_descriptor_map.find(Type::IfcGeometricRepresentationItem)->second);
current = entity_descriptor_map[Type::IfcCartesianPointList2D] = new IfcEntityDescriptor(Type::IfcCartesianPointList2D,entity_descriptor_map.find(Type::IfcCartesianPointList)->second);
current->add("CoordList",false,IfcUtil::Argument_AGGREGATE_OF_AGGREGATE_OF_DOUBLE,Type::IfcLengthMeasure);
current = entity_descriptor_map[Type::IfcCartesianPointList3D] = new IfcEntityDescriptor(Type::IfcCartesianPointList3D,entity_descriptor_map.find(Type::IfcCartesianPointList)->second); current = entity_descriptor_map[Type::IfcCartesianPointList3D] = new IfcEntityDescriptor(Type::IfcCartesianPointList3D,entity_descriptor_map.find(Type::IfcCartesianPointList)->second);
current->add("CoordList",false,IfcUtil::Argument_AGGREGATE_OF_AGGREGATE_OF_DOUBLE,Type::IfcLengthMeasure); current->add("CoordList",false,IfcUtil::Argument_AGGREGATE_OF_AGGREGATE_OF_DOUBLE,Type::IfcLengthMeasure);
current = entity_descriptor_map[Type::IfcCartesianTransformationOperator] = new IfcEntityDescriptor(Type::IfcCartesianTransformationOperator,entity_descriptor_map.find(Type::IfcGeometricRepresentationItem)->second); current = entity_descriptor_map[Type::IfcCartesianTransformationOperator] = new IfcEntityDescriptor(Type::IfcCartesianTransformationOperator,entity_descriptor_map.find(Type::IfcGeometricRepresentationItem)->second);
current->add("Axis1",true,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcDirection); current->add("Axis1",true,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcDirection);
current->add("Axis2",true,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcDirection); current->add("Axis2",true,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcDirection);
current->add("LocalOrigin",false,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcCartesianPoint); current->add("LocalOrigin",false,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcCartesianPoint);
current->add("Scale",true,IfcUtil::Argument_DOUBLE,Type::UNDEFINED); current->add("Scale",true,IfcUtil::Argument_DOUBLE,Type::IfcReal);
current = entity_descriptor_map[Type::IfcCartesianTransformationOperator2D] = new IfcEntityDescriptor(Type::IfcCartesianTransformationOperator2D,entity_descriptor_map.find(Type::IfcCartesianTransformationOperator)->second); current = entity_descriptor_map[Type::IfcCartesianTransformationOperator2D] = new IfcEntityDescriptor(Type::IfcCartesianTransformationOperator2D,entity_descriptor_map.find(Type::IfcCartesianTransformationOperator)->second);
current = entity_descriptor_map[Type::IfcCartesianTransformationOperator2DnonUniform] = new IfcEntityDescriptor(Type::IfcCartesianTransformationOperator2DnonUniform,entity_descriptor_map.find(Type::IfcCartesianTransformationOperator2D)->second); current = entity_descriptor_map[Type::IfcCartesianTransformationOperator2DnonUniform] = new IfcEntityDescriptor(Type::IfcCartesianTransformationOperator2DnonUniform,entity_descriptor_map.find(Type::IfcCartesianTransformationOperator2D)->second);
current->add("Scale2",true,IfcUtil::Argument_DOUBLE,Type::UNDEFINED); current->add("Scale2",true,IfcUtil::Argument_DOUBLE,Type::IfcReal);
current = entity_descriptor_map[Type::IfcCartesianTransformationOperator3D] = new IfcEntityDescriptor(Type::IfcCartesianTransformationOperator3D,entity_descriptor_map.find(Type::IfcCartesianTransformationOperator)->second); current = entity_descriptor_map[Type::IfcCartesianTransformationOperator3D] = new IfcEntityDescriptor(Type::IfcCartesianTransformationOperator3D,entity_descriptor_map.find(Type::IfcCartesianTransformationOperator)->second);
current->add("Axis3",true,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcDirection); current->add("Axis3",true,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcDirection);
current = entity_descriptor_map[Type::IfcCartesianTransformationOperator3DnonUniform] = new IfcEntityDescriptor(Type::IfcCartesianTransformationOperator3DnonUniform,entity_descriptor_map.find(Type::IfcCartesianTransformationOperator3D)->second); current = entity_descriptor_map[Type::IfcCartesianTransformationOperator3DnonUniform] = new IfcEntityDescriptor(Type::IfcCartesianTransformationOperator3DnonUniform,entity_descriptor_map.find(Type::IfcCartesianTransformationOperator3D)->second);
current->add("Scale2",true,IfcUtil::Argument_DOUBLE,Type::UNDEFINED); current->add("Scale2",true,IfcUtil::Argument_DOUBLE,Type::IfcReal);
current->add("Scale3",true,IfcUtil::Argument_DOUBLE,Type::UNDEFINED); current->add("Scale3",true,IfcUtil::Argument_DOUBLE,Type::IfcReal);
current = entity_descriptor_map[Type::IfcCircleProfileDef] = new IfcEntityDescriptor(Type::IfcCircleProfileDef,entity_descriptor_map.find(Type::IfcParameterizedProfileDef)->second); current = entity_descriptor_map[Type::IfcCircleProfileDef] = new IfcEntityDescriptor(Type::IfcCircleProfileDef,entity_descriptor_map.find(Type::IfcParameterizedProfileDef)->second);
current->add("Radius",false,IfcUtil::Argument_DOUBLE,Type::IfcPositiveLengthMeasure); current->add("Radius",false,IfcUtil::Argument_DOUBLE,Type::IfcPositiveLengthMeasure);
current = entity_descriptor_map[Type::IfcClosedShell] = new IfcEntityDescriptor(Type::IfcClosedShell,entity_descriptor_map.find(Type::IfcConnectedFaceSet)->second); current = entity_descriptor_map[Type::IfcClosedShell] = new IfcEntityDescriptor(Type::IfcClosedShell,entity_descriptor_map.find(Type::IfcConnectedFaceSet)->second);
@@ -1384,7 +1394,7 @@ void InitDescriptorMap() {
current->add("HasProperties",false,IfcUtil::Argument_AGGREGATE_OF_ENTITY_INSTANCE,Type::IfcProperty); current->add("HasProperties",false,IfcUtil::Argument_AGGREGATE_OF_ENTITY_INSTANCE,Type::IfcProperty);
current = entity_descriptor_map[Type::IfcCompositeCurveSegment] = new IfcEntityDescriptor(Type::IfcCompositeCurveSegment,entity_descriptor_map.find(Type::IfcGeometricRepresentationItem)->second); current = entity_descriptor_map[Type::IfcCompositeCurveSegment] = new IfcEntityDescriptor(Type::IfcCompositeCurveSegment,entity_descriptor_map.find(Type::IfcGeometricRepresentationItem)->second);
current->add("Transition",false,IfcUtil::Argument_ENUMERATION,Type::IfcTransitionCode); current->add("Transition",false,IfcUtil::Argument_ENUMERATION,Type::IfcTransitionCode);
current->add("SameSense",false,IfcUtil::Argument_BOOL,Type::UNDEFINED); current->add("SameSense",false,IfcUtil::Argument_BOOL,Type::IfcBoolean);
current->add("ParentCurve",false,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcCurve); current->add("ParentCurve",false,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcCurve);
current = entity_descriptor_map[Type::IfcConstructionResourceType] = new IfcEntityDescriptor(Type::IfcConstructionResourceType,entity_descriptor_map.find(Type::IfcTypeResource)->second); current = entity_descriptor_map[Type::IfcConstructionResourceType] = new IfcEntityDescriptor(Type::IfcConstructionResourceType,entity_descriptor_map.find(Type::IfcTypeResource)->second);
current->add("BaseCosts",true,IfcUtil::Argument_AGGREGATE_OF_ENTITY_INSTANCE,Type::IfcAppliedValue); current->add("BaseCosts",true,IfcUtil::Argument_AGGREGATE_OF_ENTITY_INSTANCE,Type::IfcAppliedValue);
@@ -1410,14 +1420,14 @@ void InitDescriptorMap() {
current = entity_descriptor_map[Type::IfcCurveBoundedSurface] = new IfcEntityDescriptor(Type::IfcCurveBoundedSurface,entity_descriptor_map.find(Type::IfcBoundedSurface)->second); current = entity_descriptor_map[Type::IfcCurveBoundedSurface] = new IfcEntityDescriptor(Type::IfcCurveBoundedSurface,entity_descriptor_map.find(Type::IfcBoundedSurface)->second);
current->add("BasisSurface",false,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcSurface); current->add("BasisSurface",false,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcSurface);
current->add("Boundaries",false,IfcUtil::Argument_AGGREGATE_OF_ENTITY_INSTANCE,Type::IfcBoundaryCurve); current->add("Boundaries",false,IfcUtil::Argument_AGGREGATE_OF_ENTITY_INSTANCE,Type::IfcBoundaryCurve);
current->add("ImplicitOuter",false,IfcUtil::Argument_BOOL,Type::UNDEFINED); current->add("ImplicitOuter",false,IfcUtil::Argument_BOOL,Type::IfcBoolean);
current = entity_descriptor_map[Type::IfcDirection] = new IfcEntityDescriptor(Type::IfcDirection,entity_descriptor_map.find(Type::IfcGeometricRepresentationItem)->second); current = entity_descriptor_map[Type::IfcDirection] = new IfcEntityDescriptor(Type::IfcDirection,entity_descriptor_map.find(Type::IfcGeometricRepresentationItem)->second);
current->add("DirectionRatios",false,IfcUtil::Argument_AGGREGATE_OF_DOUBLE,Type::UNDEFINED); current->add("DirectionRatios",false,IfcUtil::Argument_AGGREGATE_OF_DOUBLE,Type::IfcReal);
current = entity_descriptor_map[Type::IfcDoorStyle] = new IfcEntityDescriptor(Type::IfcDoorStyle,entity_descriptor_map.find(Type::IfcTypeProduct)->second); current = entity_descriptor_map[Type::IfcDoorStyle] = new IfcEntityDescriptor(Type::IfcDoorStyle,entity_descriptor_map.find(Type::IfcTypeProduct)->second);
current->add("OperationType",false,IfcUtil::Argument_ENUMERATION,Type::IfcDoorStyleOperationEnum); current->add("OperationType",false,IfcUtil::Argument_ENUMERATION,Type::IfcDoorStyleOperationEnum);
current->add("ConstructionType",false,IfcUtil::Argument_ENUMERATION,Type::IfcDoorStyleConstructionEnum); current->add("ConstructionType",false,IfcUtil::Argument_ENUMERATION,Type::IfcDoorStyleConstructionEnum);
current->add("ParameterTakesPrecedence",false,IfcUtil::Argument_BOOL,Type::UNDEFINED); current->add("ParameterTakesPrecedence",false,IfcUtil::Argument_BOOL,Type::IfcBoolean);
current->add("Sizeable",false,IfcUtil::Argument_BOOL,Type::UNDEFINED); current->add("Sizeable",false,IfcUtil::Argument_BOOL,Type::IfcBoolean);
current = entity_descriptor_map[Type::IfcEdgeLoop] = new IfcEntityDescriptor(Type::IfcEdgeLoop,entity_descriptor_map.find(Type::IfcLoop)->second); current = entity_descriptor_map[Type::IfcEdgeLoop] = new IfcEntityDescriptor(Type::IfcEdgeLoop,entity_descriptor_map.find(Type::IfcLoop)->second);
current->add("EdgeList",false,IfcUtil::Argument_AGGREGATE_OF_ENTITY_INSTANCE,Type::IfcOrientedEdge); current->add("EdgeList",false,IfcUtil::Argument_AGGREGATE_OF_ENTITY_INSTANCE,Type::IfcOrientedEdge);
current = entity_descriptor_map[Type::IfcElementQuantity] = new IfcEntityDescriptor(Type::IfcElementQuantity,entity_descriptor_map.find(Type::IfcQuantitySet)->second); current = entity_descriptor_map[Type::IfcElementQuantity] = new IfcEntityDescriptor(Type::IfcElementQuantity,entity_descriptor_map.find(Type::IfcQuantitySet)->second);
@@ -1492,11 +1502,11 @@ void InitDescriptorMap() {
current = entity_descriptor_map[Type::IfcOffsetCurve2D] = new IfcEntityDescriptor(Type::IfcOffsetCurve2D,entity_descriptor_map.find(Type::IfcCurve)->second); current = entity_descriptor_map[Type::IfcOffsetCurve2D] = new IfcEntityDescriptor(Type::IfcOffsetCurve2D,entity_descriptor_map.find(Type::IfcCurve)->second);
current->add("BasisCurve",false,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcCurve); current->add("BasisCurve",false,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcCurve);
current->add("Distance",false,IfcUtil::Argument_DOUBLE,Type::IfcLengthMeasure); current->add("Distance",false,IfcUtil::Argument_DOUBLE,Type::IfcLengthMeasure);
current->add("SelfIntersect",false,IfcUtil::Argument_BOOL,Type::UNDEFINED); current->add("SelfIntersect",false,IfcUtil::Argument_BOOL,Type::IfcLogical);
current = entity_descriptor_map[Type::IfcOffsetCurve3D] = new IfcEntityDescriptor(Type::IfcOffsetCurve3D,entity_descriptor_map.find(Type::IfcCurve)->second); current = entity_descriptor_map[Type::IfcOffsetCurve3D] = new IfcEntityDescriptor(Type::IfcOffsetCurve3D,entity_descriptor_map.find(Type::IfcCurve)->second);
current->add("BasisCurve",false,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcCurve); current->add("BasisCurve",false,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcCurve);
current->add("Distance",false,IfcUtil::Argument_DOUBLE,Type::IfcLengthMeasure); current->add("Distance",false,IfcUtil::Argument_DOUBLE,Type::IfcLengthMeasure);
current->add("SelfIntersect",false,IfcUtil::Argument_BOOL,Type::UNDEFINED); current->add("SelfIntersect",false,IfcUtil::Argument_BOOL,Type::IfcLogical);
current->add("RefDirection",false,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcDirection); current->add("RefDirection",false,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcDirection);
current = entity_descriptor_map[Type::IfcPcurve] = new IfcEntityDescriptor(Type::IfcPcurve,entity_descriptor_map.find(Type::IfcCurve)->second); current = entity_descriptor_map[Type::IfcPcurve] = new IfcEntityDescriptor(Type::IfcPcurve,entity_descriptor_map.find(Type::IfcCurve)->second);
current->add("BasisSurface",false,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcSurface); current->add("BasisSurface",false,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcSurface);
@@ -1572,8 +1582,8 @@ void InitDescriptorMap() {
current->add("V1",false,IfcUtil::Argument_DOUBLE,Type::IfcParameterValue); current->add("V1",false,IfcUtil::Argument_DOUBLE,Type::IfcParameterValue);
current->add("U2",false,IfcUtil::Argument_DOUBLE,Type::IfcParameterValue); current->add("U2",false,IfcUtil::Argument_DOUBLE,Type::IfcParameterValue);
current->add("V2",false,IfcUtil::Argument_DOUBLE,Type::IfcParameterValue); current->add("V2",false,IfcUtil::Argument_DOUBLE,Type::IfcParameterValue);
current->add("Usense",false,IfcUtil::Argument_BOOL,Type::UNDEFINED); current->add("Usense",false,IfcUtil::Argument_BOOL,Type::IfcBoolean);
current->add("Vsense",false,IfcUtil::Argument_BOOL,Type::UNDEFINED); current->add("Vsense",false,IfcUtil::Argument_BOOL,Type::IfcBoolean);
current = entity_descriptor_map[Type::IfcReinforcementDefinitionProperties] = new IfcEntityDescriptor(Type::IfcReinforcementDefinitionProperties,entity_descriptor_map.find(Type::IfcPreDefinedPropertySet)->second); current = entity_descriptor_map[Type::IfcReinforcementDefinitionProperties] = new IfcEntityDescriptor(Type::IfcReinforcementDefinitionProperties,entity_descriptor_map.find(Type::IfcPreDefinedPropertySet)->second);
current->add("DefinitionType",true,IfcUtil::Argument_STRING,Type::IfcLabel); current->add("DefinitionType",true,IfcUtil::Argument_STRING,Type::IfcLabel);
current->add("ReinforcementSectionDefinitions",false,IfcUtil::Argument_AGGREGATE_OF_ENTITY_INSTANCE,Type::IfcSectionReinforcementProperties); current->add("ReinforcementSectionDefinitions",false,IfcUtil::Argument_AGGREGATE_OF_ENTITY_INSTANCE,Type::IfcSectionReinforcementProperties);
@@ -1618,8 +1628,8 @@ void InitDescriptorMap() {
current->add("RelatingElement",false,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcElement); current->add("RelatingElement",false,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcElement);
current->add("RelatedElement",false,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcElement); current->add("RelatedElement",false,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcElement);
current = entity_descriptor_map[Type::IfcRelConnectsPathElements] = new IfcEntityDescriptor(Type::IfcRelConnectsPathElements,entity_descriptor_map.find(Type::IfcRelConnectsElements)->second); current = entity_descriptor_map[Type::IfcRelConnectsPathElements] = new IfcEntityDescriptor(Type::IfcRelConnectsPathElements,entity_descriptor_map.find(Type::IfcRelConnectsElements)->second);
current->add("RelatingPriorities",false,IfcUtil::Argument_AGGREGATE_OF_DOUBLE,Type::UNDEFINED); current->add("RelatingPriorities",false,IfcUtil::Argument_AGGREGATE_OF_INT,Type::IfcInteger);
current->add("RelatedPriorities",false,IfcUtil::Argument_AGGREGATE_OF_DOUBLE,Type::UNDEFINED); current->add("RelatedPriorities",false,IfcUtil::Argument_AGGREGATE_OF_INT,Type::IfcInteger);
current->add("RelatedConnectionType",false,IfcUtil::Argument_ENUMERATION,Type::IfcConnectionTypeEnum); current->add("RelatedConnectionType",false,IfcUtil::Argument_ENUMERATION,Type::IfcConnectionTypeEnum);
current->add("RelatingConnectionType",false,IfcUtil::Argument_ENUMERATION,Type::IfcConnectionTypeEnum); current->add("RelatingConnectionType",false,IfcUtil::Argument_ENUMERATION,Type::IfcConnectionTypeEnum);
current = entity_descriptor_map[Type::IfcRelConnectsPortToElement] = new IfcEntityDescriptor(Type::IfcRelConnectsPortToElement,entity_descriptor_map.find(Type::IfcRelConnects)->second); current = entity_descriptor_map[Type::IfcRelConnectsPortToElement] = new IfcEntityDescriptor(Type::IfcRelConnectsPortToElement,entity_descriptor_map.find(Type::IfcRelConnects)->second);
@@ -1788,8 +1798,8 @@ void InitDescriptorMap() {
current = entity_descriptor_map[Type::IfcTask] = new IfcEntityDescriptor(Type::IfcTask,entity_descriptor_map.find(Type::IfcProcess)->second); current = entity_descriptor_map[Type::IfcTask] = new IfcEntityDescriptor(Type::IfcTask,entity_descriptor_map.find(Type::IfcProcess)->second);
current->add("Status",true,IfcUtil::Argument_STRING,Type::IfcLabel); current->add("Status",true,IfcUtil::Argument_STRING,Type::IfcLabel);
current->add("WorkMethod",true,IfcUtil::Argument_STRING,Type::IfcLabel); current->add("WorkMethod",true,IfcUtil::Argument_STRING,Type::IfcLabel);
current->add("IsMilestone",false,IfcUtil::Argument_BOOL,Type::UNDEFINED); current->add("IsMilestone",false,IfcUtil::Argument_BOOL,Type::IfcBoolean);
current->add("Priority",true,IfcUtil::Argument_INT,Type::UNDEFINED); current->add("Priority",true,IfcUtil::Argument_INT,Type::IfcInteger);
current->add("TaskTime",true,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcTaskTime); current->add("TaskTime",true,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcTaskTime);
current->add("PredefinedType",true,IfcUtil::Argument_ENUMERATION,Type::IfcTaskTypeEnum); current->add("PredefinedType",true,IfcUtil::Argument_ENUMERATION,Type::IfcTaskTypeEnum);
current = entity_descriptor_map[Type::IfcTaskType] = new IfcEntityDescriptor(Type::IfcTaskType,entity_descriptor_map.find(Type::IfcTypeProcess)->second); current = entity_descriptor_map[Type::IfcTaskType] = new IfcEntityDescriptor(Type::IfcTaskType,entity_descriptor_map.find(Type::IfcTypeProcess)->second);
@@ -1798,12 +1808,12 @@ void InitDescriptorMap() {
current = entity_descriptor_map[Type::IfcTessellatedFaceSet] = new IfcEntityDescriptor(Type::IfcTessellatedFaceSet,entity_descriptor_map.find(Type::IfcTessellatedItem)->second); current = entity_descriptor_map[Type::IfcTessellatedFaceSet] = new IfcEntityDescriptor(Type::IfcTessellatedFaceSet,entity_descriptor_map.find(Type::IfcTessellatedItem)->second);
current->add("Coordinates",false,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcCartesianPointList3D); current->add("Coordinates",false,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcCartesianPointList3D);
current->add("Normals",true,IfcUtil::Argument_AGGREGATE_OF_AGGREGATE_OF_DOUBLE,Type::IfcParameterValue); current->add("Normals",true,IfcUtil::Argument_AGGREGATE_OF_AGGREGATE_OF_DOUBLE,Type::IfcParameterValue);
current->add("Closed",true,IfcUtil::Argument_BOOL,Type::UNDEFINED); current->add("Closed",true,IfcUtil::Argument_BOOL,Type::IfcBoolean);
current = entity_descriptor_map[Type::IfcTransportElementType] = new IfcEntityDescriptor(Type::IfcTransportElementType,entity_descriptor_map.find(Type::IfcElementType)->second); current = entity_descriptor_map[Type::IfcTransportElementType] = new IfcEntityDescriptor(Type::IfcTransportElementType,entity_descriptor_map.find(Type::IfcElementType)->second);
current->add("PredefinedType",false,IfcUtil::Argument_ENUMERATION,Type::IfcTransportElementTypeEnum); current->add("PredefinedType",false,IfcUtil::Argument_ENUMERATION,Type::IfcTransportElementTypeEnum);
current = entity_descriptor_map[Type::IfcTriangulatedFaceSet] = new IfcEntityDescriptor(Type::IfcTriangulatedFaceSet,entity_descriptor_map.find(Type::IfcTessellatedFaceSet)->second); current = entity_descriptor_map[Type::IfcTriangulatedFaceSet] = new IfcEntityDescriptor(Type::IfcTriangulatedFaceSet,entity_descriptor_map.find(Type::IfcTessellatedFaceSet)->second);
current->add("CoordIndex",false,IfcUtil::Argument_AGGREGATE_OF_AGGREGATE_OF_INT,Type::UNDEFINED); current->add("CoordIndex",false,IfcUtil::Argument_AGGREGATE_OF_AGGREGATE_OF_INT,Type::IfcPositiveInteger);
current->add("NormalIndex",true,IfcUtil::Argument_AGGREGATE_OF_AGGREGATE_OF_INT,Type::UNDEFINED); current->add("NormalIndex",true,IfcUtil::Argument_AGGREGATE_OF_AGGREGATE_OF_INT,Type::IfcPositiveInteger);
current = entity_descriptor_map[Type::IfcWindowLiningProperties] = new IfcEntityDescriptor(Type::IfcWindowLiningProperties,entity_descriptor_map.find(Type::IfcPreDefinedPropertySet)->second); current = entity_descriptor_map[Type::IfcWindowLiningProperties] = new IfcEntityDescriptor(Type::IfcWindowLiningProperties,entity_descriptor_map.find(Type::IfcPreDefinedPropertySet)->second);
current->add("LiningDepth",true,IfcUtil::Argument_DOUBLE,Type::IfcPositiveLengthMeasure); current->add("LiningDepth",true,IfcUtil::Argument_DOUBLE,Type::IfcPositiveLengthMeasure);
current->add("LiningThickness",true,IfcUtil::Argument_DOUBLE,Type::IfcNonNegativeLengthMeasure); current->add("LiningThickness",true,IfcUtil::Argument_DOUBLE,Type::IfcNonNegativeLengthMeasure);
@@ -1832,16 +1842,16 @@ void InitDescriptorMap() {
current = entity_descriptor_map[Type::IfcAnnotation] = new IfcEntityDescriptor(Type::IfcAnnotation,entity_descriptor_map.find(Type::IfcProduct)->second); current = entity_descriptor_map[Type::IfcAnnotation] = new IfcEntityDescriptor(Type::IfcAnnotation,entity_descriptor_map.find(Type::IfcProduct)->second);
current = entity_descriptor_map[Type::IfcBSplineSurface] = new IfcEntityDescriptor(Type::IfcBSplineSurface,entity_descriptor_map.find(Type::IfcBoundedSurface)->second); current = entity_descriptor_map[Type::IfcBSplineSurface] = new IfcEntityDescriptor(Type::IfcBSplineSurface,entity_descriptor_map.find(Type::IfcBoundedSurface)->second);
current->add("UDegree",false,IfcUtil::Argument_INT,Type::UNDEFINED); current->add("UDegree",false,IfcUtil::Argument_INT,Type::IfcInteger);
current->add("VDegree",false,IfcUtil::Argument_INT,Type::UNDEFINED); current->add("VDegree",false,IfcUtil::Argument_INT,Type::IfcInteger);
current->add("ControlPointsList",false,IfcUtil::Argument_AGGREGATE_OF_AGGREGATE_OF_ENTITY_INSTANCE,Type::IfcCartesianPoint); current->add("ControlPointsList",false,IfcUtil::Argument_AGGREGATE_OF_AGGREGATE_OF_ENTITY_INSTANCE,Type::IfcCartesianPoint);
current->add("SurfaceForm",false,IfcUtil::Argument_ENUMERATION,Type::IfcBSplineSurfaceForm); current->add("SurfaceForm",false,IfcUtil::Argument_ENUMERATION,Type::IfcBSplineSurfaceForm);
current->add("UClosed",false,IfcUtil::Argument_BOOL,Type::UNDEFINED); current->add("UClosed",false,IfcUtil::Argument_BOOL,Type::IfcLogical);
current->add("VClosed",false,IfcUtil::Argument_BOOL,Type::UNDEFINED); current->add("VClosed",false,IfcUtil::Argument_BOOL,Type::IfcLogical);
current->add("SelfIntersect",false,IfcUtil::Argument_BOOL,Type::UNDEFINED); current->add("SelfIntersect",false,IfcUtil::Argument_BOOL,Type::IfcLogical);
current = entity_descriptor_map[Type::IfcBSplineSurfaceWithKnots] = new IfcEntityDescriptor(Type::IfcBSplineSurfaceWithKnots,entity_descriptor_map.find(Type::IfcBSplineSurface)->second); current = entity_descriptor_map[Type::IfcBSplineSurfaceWithKnots] = new IfcEntityDescriptor(Type::IfcBSplineSurfaceWithKnots,entity_descriptor_map.find(Type::IfcBSplineSurface)->second);
current->add("UMultiplicities",false,IfcUtil::Argument_AGGREGATE_OF_INT,Type::UNDEFINED); current->add("UMultiplicities",false,IfcUtil::Argument_AGGREGATE_OF_INT,Type::IfcInteger);
current->add("VMultiplicities",false,IfcUtil::Argument_AGGREGATE_OF_INT,Type::UNDEFINED); current->add("VMultiplicities",false,IfcUtil::Argument_AGGREGATE_OF_INT,Type::IfcInteger);
current->add("UKnots",false,IfcUtil::Argument_AGGREGATE_OF_DOUBLE,Type::IfcParameterValue); current->add("UKnots",false,IfcUtil::Argument_AGGREGATE_OF_DOUBLE,Type::IfcParameterValue);
current->add("VKnots",false,IfcUtil::Argument_AGGREGATE_OF_DOUBLE,Type::IfcParameterValue); current->add("VKnots",false,IfcUtil::Argument_AGGREGATE_OF_DOUBLE,Type::IfcParameterValue);
current->add("KnotSpec",false,IfcUtil::Argument_ENUMERATION,Type::IfcKnotType); current->add("KnotSpec",false,IfcUtil::Argument_ENUMERATION,Type::IfcKnotType);
@@ -1875,7 +1885,7 @@ void InitDescriptorMap() {
current->add("HasPropertyTemplates",true,IfcUtil::Argument_AGGREGATE_OF_ENTITY_INSTANCE,Type::IfcPropertyTemplate); current->add("HasPropertyTemplates",true,IfcUtil::Argument_AGGREGATE_OF_ENTITY_INSTANCE,Type::IfcPropertyTemplate);
current = entity_descriptor_map[Type::IfcCompositeCurve] = new IfcEntityDescriptor(Type::IfcCompositeCurve,entity_descriptor_map.find(Type::IfcBoundedCurve)->second); current = entity_descriptor_map[Type::IfcCompositeCurve] = new IfcEntityDescriptor(Type::IfcCompositeCurve,entity_descriptor_map.find(Type::IfcBoundedCurve)->second);
current->add("Segments",false,IfcUtil::Argument_AGGREGATE_OF_ENTITY_INSTANCE,Type::IfcCompositeCurveSegment); current->add("Segments",false,IfcUtil::Argument_AGGREGATE_OF_ENTITY_INSTANCE,Type::IfcCompositeCurveSegment);
current->add("SelfIntersect",false,IfcUtil::Argument_BOOL,Type::UNDEFINED); current->add("SelfIntersect",false,IfcUtil::Argument_BOOL,Type::IfcLogical);
current = entity_descriptor_map[Type::IfcCompositeCurveOnSurface] = new IfcEntityDescriptor(Type::IfcCompositeCurveOnSurface,entity_descriptor_map.find(Type::IfcCompositeCurve)->second); current = entity_descriptor_map[Type::IfcCompositeCurveOnSurface] = new IfcEntityDescriptor(Type::IfcCompositeCurveOnSurface,entity_descriptor_map.find(Type::IfcCompositeCurve)->second);
current = entity_descriptor_map[Type::IfcConic] = new IfcEntityDescriptor(Type::IfcConic,entity_descriptor_map.find(Type::IfcCurve)->second); current = entity_descriptor_map[Type::IfcConic] = new IfcEntityDescriptor(Type::IfcConic,entity_descriptor_map.find(Type::IfcCurve)->second);
@@ -1936,7 +1946,7 @@ void InitDescriptorMap() {
current = entity_descriptor_map[Type::IfcDoorType] = new IfcEntityDescriptor(Type::IfcDoorType,entity_descriptor_map.find(Type::IfcBuildingElementType)->second); current = entity_descriptor_map[Type::IfcDoorType] = new IfcEntityDescriptor(Type::IfcDoorType,entity_descriptor_map.find(Type::IfcBuildingElementType)->second);
current->add("PredefinedType",false,IfcUtil::Argument_ENUMERATION,Type::IfcDoorTypeEnum); current->add("PredefinedType",false,IfcUtil::Argument_ENUMERATION,Type::IfcDoorTypeEnum);
current->add("OperationType",false,IfcUtil::Argument_ENUMERATION,Type::IfcDoorTypeOperationEnum); current->add("OperationType",false,IfcUtil::Argument_ENUMERATION,Type::IfcDoorTypeOperationEnum);
current->add("ParameterTakesPrecedence",true,IfcUtil::Argument_BOOL,Type::UNDEFINED); current->add("ParameterTakesPrecedence",true,IfcUtil::Argument_BOOL,Type::IfcBoolean);
current->add("UserDefinedOperationType",true,IfcUtil::Argument_STRING,Type::IfcLabel); current->add("UserDefinedOperationType",true,IfcUtil::Argument_STRING,Type::IfcLabel);
current = entity_descriptor_map[Type::IfcDraughtingPreDefinedColour] = new IfcEntityDescriptor(Type::IfcDraughtingPreDefinedColour,entity_descriptor_map.find(Type::IfcPreDefinedColour)->second); current = entity_descriptor_map[Type::IfcDraughtingPreDefinedColour] = new IfcEntityDescriptor(Type::IfcDraughtingPreDefinedColour,entity_descriptor_map.find(Type::IfcPreDefinedColour)->second);
@@ -2020,6 +2030,10 @@ void InitDescriptorMap() {
current->add("PredefinedType",false,IfcUtil::Argument_ENUMERATION,Type::IfcHeatExchangerTypeEnum); current->add("PredefinedType",false,IfcUtil::Argument_ENUMERATION,Type::IfcHeatExchangerTypeEnum);
current = entity_descriptor_map[Type::IfcHumidifierType] = new IfcEntityDescriptor(Type::IfcHumidifierType,entity_descriptor_map.find(Type::IfcEnergyConversionDeviceType)->second); current = entity_descriptor_map[Type::IfcHumidifierType] = new IfcEntityDescriptor(Type::IfcHumidifierType,entity_descriptor_map.find(Type::IfcEnergyConversionDeviceType)->second);
current->add("PredefinedType",false,IfcUtil::Argument_ENUMERATION,Type::IfcHumidifierTypeEnum); current->add("PredefinedType",false,IfcUtil::Argument_ENUMERATION,Type::IfcHumidifierTypeEnum);
current = entity_descriptor_map[Type::IfcIndexedPolyCurve] = new IfcEntityDescriptor(Type::IfcIndexedPolyCurve,entity_descriptor_map.find(Type::IfcBoundedCurve)->second);
current->add("Points",false,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcCartesianPointList);
current->add("Segments",true,IfcUtil::Argument_AGGREGATE_OF_ENTITY_INSTANCE,Type::IfcSegmentIndexSelect);
current->add("SelfIntersect",true,IfcUtil::Argument_BOOL,Type::IfcBoolean);
current = entity_descriptor_map[Type::IfcInterceptorType] = new IfcEntityDescriptor(Type::IfcInterceptorType,entity_descriptor_map.find(Type::IfcFlowTreatmentDeviceType)->second); current = entity_descriptor_map[Type::IfcInterceptorType] = new IfcEntityDescriptor(Type::IfcInterceptorType,entity_descriptor_map.find(Type::IfcFlowTreatmentDeviceType)->second);
current->add("PredefinedType",false,IfcUtil::Argument_ENUMERATION,Type::IfcInterceptorTypeEnum); current->add("PredefinedType",false,IfcUtil::Argument_ENUMERATION,Type::IfcInterceptorTypeEnum);
current = entity_descriptor_map[Type::IfcInventory] = new IfcEntityDescriptor(Type::IfcInventory,entity_descriptor_map.find(Type::IfcGroup)->second); current = entity_descriptor_map[Type::IfcInventory] = new IfcEntityDescriptor(Type::IfcInventory,entity_descriptor_map.find(Type::IfcGroup)->second);
@@ -2103,7 +2117,7 @@ void InitDescriptorMap() {
current = entity_descriptor_map[Type::IfcRampType] = new IfcEntityDescriptor(Type::IfcRampType,entity_descriptor_map.find(Type::IfcBuildingElementType)->second); current = entity_descriptor_map[Type::IfcRampType] = new IfcEntityDescriptor(Type::IfcRampType,entity_descriptor_map.find(Type::IfcBuildingElementType)->second);
current->add("PredefinedType",false,IfcUtil::Argument_ENUMERATION,Type::IfcRampTypeEnum); current->add("PredefinedType",false,IfcUtil::Argument_ENUMERATION,Type::IfcRampTypeEnum);
current = entity_descriptor_map[Type::IfcRationalBSplineSurfaceWithKnots] = new IfcEntityDescriptor(Type::IfcRationalBSplineSurfaceWithKnots,entity_descriptor_map.find(Type::IfcBSplineSurfaceWithKnots)->second); current = entity_descriptor_map[Type::IfcRationalBSplineSurfaceWithKnots] = new IfcEntityDescriptor(Type::IfcRationalBSplineSurfaceWithKnots,entity_descriptor_map.find(Type::IfcBSplineSurfaceWithKnots)->second);
current->add("WeightsData",false,IfcUtil::Argument_AGGREGATE_OF_AGGREGATE_OF_DOUBLE,Type::UNDEFINED); current->add("WeightsData",false,IfcUtil::Argument_AGGREGATE_OF_AGGREGATE_OF_DOUBLE,Type::IfcReal);
current = entity_descriptor_map[Type::IfcReinforcingElement] = new IfcEntityDescriptor(Type::IfcReinforcingElement,entity_descriptor_map.find(Type::IfcElementComponent)->second); current = entity_descriptor_map[Type::IfcReinforcingElement] = new IfcEntityDescriptor(Type::IfcReinforcingElement,entity_descriptor_map.find(Type::IfcElementComponent)->second);
current->add("SteelGrade",true,IfcUtil::Argument_STRING,Type::IfcLabel); current->add("SteelGrade",true,IfcUtil::Argument_STRING,Type::IfcLabel);
current = entity_descriptor_map[Type::IfcReinforcingElementType] = new IfcEntityDescriptor(Type::IfcReinforcingElementType,entity_descriptor_map.find(Type::IfcElementComponentType)->second); current = entity_descriptor_map[Type::IfcReinforcingElementType] = new IfcEntityDescriptor(Type::IfcReinforcingElementType,entity_descriptor_map.find(Type::IfcElementComponentType)->second);
@@ -2164,7 +2178,7 @@ void InitDescriptorMap() {
current = entity_descriptor_map[Type::IfcStairType] = new IfcEntityDescriptor(Type::IfcStairType,entity_descriptor_map.find(Type::IfcBuildingElementType)->second); current = entity_descriptor_map[Type::IfcStairType] = new IfcEntityDescriptor(Type::IfcStairType,entity_descriptor_map.find(Type::IfcBuildingElementType)->second);
current->add("PredefinedType",false,IfcUtil::Argument_ENUMERATION,Type::IfcStairTypeEnum); current->add("PredefinedType",false,IfcUtil::Argument_ENUMERATION,Type::IfcStairTypeEnum);
current = entity_descriptor_map[Type::IfcStructuralAction] = new IfcEntityDescriptor(Type::IfcStructuralAction,entity_descriptor_map.find(Type::IfcStructuralActivity)->second); current = entity_descriptor_map[Type::IfcStructuralAction] = new IfcEntityDescriptor(Type::IfcStructuralAction,entity_descriptor_map.find(Type::IfcStructuralActivity)->second);
current->add("DestabilizingLoad",true,IfcUtil::Argument_BOOL,Type::UNDEFINED); current->add("DestabilizingLoad",true,IfcUtil::Argument_BOOL,Type::IfcBoolean);
current = entity_descriptor_map[Type::IfcStructuralConnection] = new IfcEntityDescriptor(Type::IfcStructuralConnection,entity_descriptor_map.find(Type::IfcStructuralItem)->second); current = entity_descriptor_map[Type::IfcStructuralConnection] = new IfcEntityDescriptor(Type::IfcStructuralConnection,entity_descriptor_map.find(Type::IfcStructuralItem)->second);
current->add("AppliedCondition",true,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcBoundaryCondition); current->add("AppliedCondition",true,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcBoundaryCondition);
current = entity_descriptor_map[Type::IfcStructuralCurveAction] = new IfcEntityDescriptor(Type::IfcStructuralCurveAction,entity_descriptor_map.find(Type::IfcStructuralAction)->second); current = entity_descriptor_map[Type::IfcStructuralCurveAction] = new IfcEntityDescriptor(Type::IfcStructuralCurveAction,entity_descriptor_map.find(Type::IfcStructuralAction)->second);
@@ -2196,7 +2210,7 @@ void InitDescriptorMap() {
current = entity_descriptor_map[Type::IfcStructuralResultGroup] = new IfcEntityDescriptor(Type::IfcStructuralResultGroup,entity_descriptor_map.find(Type::IfcGroup)->second); current = entity_descriptor_map[Type::IfcStructuralResultGroup] = new IfcEntityDescriptor(Type::IfcStructuralResultGroup,entity_descriptor_map.find(Type::IfcGroup)->second);
current->add("TheoryType",false,IfcUtil::Argument_ENUMERATION,Type::IfcAnalysisTheoryTypeEnum); current->add("TheoryType",false,IfcUtil::Argument_ENUMERATION,Type::IfcAnalysisTheoryTypeEnum);
current->add("ResultForLoadGroup",true,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcStructuralLoadGroup); current->add("ResultForLoadGroup",true,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcStructuralLoadGroup);
current->add("IsLinear",false,IfcUtil::Argument_BOOL,Type::UNDEFINED); current->add("IsLinear",false,IfcUtil::Argument_BOOL,Type::IfcBoolean);
current = entity_descriptor_map[Type::IfcStructuralSurfaceAction] = new IfcEntityDescriptor(Type::IfcStructuralSurfaceAction,entity_descriptor_map.find(Type::IfcStructuralAction)->second); current = entity_descriptor_map[Type::IfcStructuralSurfaceAction] = new IfcEntityDescriptor(Type::IfcStructuralSurfaceAction,entity_descriptor_map.find(Type::IfcStructuralAction)->second);
current->add("ProjectedOrTrue",true,IfcUtil::Argument_ENUMERATION,Type::IfcProjectedOrTrueLengthEnum); current->add("ProjectedOrTrue",true,IfcUtil::Argument_ENUMERATION,Type::IfcProjectedOrTrueLengthEnum);
current->add("PredefinedType",false,IfcUtil::Argument_ENUMERATION,Type::IfcStructuralSurfaceActivityTypeEnum); current->add("PredefinedType",false,IfcUtil::Argument_ENUMERATION,Type::IfcStructuralSurfaceActivityTypeEnum);
@@ -2240,7 +2254,7 @@ void InitDescriptorMap() {
current->add("BasisCurve",false,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcCurve); current->add("BasisCurve",false,IfcUtil::Argument_ENTITY_INSTANCE,Type::IfcCurve);
current->add("Trim1",false,IfcUtil::Argument_AGGREGATE_OF_ENTITY_INSTANCE,Type::IfcTrimmingSelect); current->add("Trim1",false,IfcUtil::Argument_AGGREGATE_OF_ENTITY_INSTANCE,Type::IfcTrimmingSelect);
current->add("Trim2",false,IfcUtil::Argument_AGGREGATE_OF_ENTITY_INSTANCE,Type::IfcTrimmingSelect); current->add("Trim2",false,IfcUtil::Argument_AGGREGATE_OF_ENTITY_INSTANCE,Type::IfcTrimmingSelect);
current->add("SenseAgreement",false,IfcUtil::Argument_BOOL,Type::UNDEFINED); current->add("SenseAgreement",false,IfcUtil::Argument_BOOL,Type::IfcBoolean);
current->add("MasterRepresentation",false,IfcUtil::Argument_ENUMERATION,Type::IfcTrimmingPreference); current->add("MasterRepresentation",false,IfcUtil::Argument_ENUMERATION,Type::IfcTrimmingPreference);
current = entity_descriptor_map[Type::IfcTubeBundleType] = new IfcEntityDescriptor(Type::IfcTubeBundleType,entity_descriptor_map.find(Type::IfcEnergyConversionDeviceType)->second); current = entity_descriptor_map[Type::IfcTubeBundleType] = new IfcEntityDescriptor(Type::IfcTubeBundleType,entity_descriptor_map.find(Type::IfcEnergyConversionDeviceType)->second);
current->add("PredefinedType",false,IfcUtil::Argument_ENUMERATION,Type::IfcTubeBundleTypeEnum); current->add("PredefinedType",false,IfcUtil::Argument_ENUMERATION,Type::IfcTubeBundleTypeEnum);
@@ -2263,7 +2277,7 @@ void InitDescriptorMap() {
current = entity_descriptor_map[Type::IfcWindowType] = new IfcEntityDescriptor(Type::IfcWindowType,entity_descriptor_map.find(Type::IfcBuildingElementType)->second); current = entity_descriptor_map[Type::IfcWindowType] = new IfcEntityDescriptor(Type::IfcWindowType,entity_descriptor_map.find(Type::IfcBuildingElementType)->second);
current->add("PredefinedType",false,IfcUtil::Argument_ENUMERATION,Type::IfcWindowTypeEnum); current->add("PredefinedType",false,IfcUtil::Argument_ENUMERATION,Type::IfcWindowTypeEnum);
current->add("PartitioningType",false,IfcUtil::Argument_ENUMERATION,Type::IfcWindowTypePartitioningEnum); current->add("PartitioningType",false,IfcUtil::Argument_ENUMERATION,Type::IfcWindowTypePartitioningEnum);
current->add("ParameterTakesPrecedence",true,IfcUtil::Argument_BOOL,Type::UNDEFINED); current->add("ParameterTakesPrecedence",true,IfcUtil::Argument_BOOL,Type::IfcBoolean);
current->add("UserDefinedPartitioningType",true,IfcUtil::Argument_STRING,Type::IfcLabel); current->add("UserDefinedPartitioningType",true,IfcUtil::Argument_STRING,Type::IfcLabel);
current = entity_descriptor_map[Type::IfcWorkCalendar] = new IfcEntityDescriptor(Type::IfcWorkCalendar,entity_descriptor_map.find(Type::IfcControl)->second); current = entity_descriptor_map[Type::IfcWorkCalendar] = new IfcEntityDescriptor(Type::IfcWorkCalendar,entity_descriptor_map.find(Type::IfcControl)->second);
current->add("WorkingTimes",true,IfcUtil::Argument_AGGREGATE_OF_ENTITY_INSTANCE,Type::IfcWorkTime); current->add("WorkingTimes",true,IfcUtil::Argument_AGGREGATE_OF_ENTITY_INSTANCE,Type::IfcWorkTime);
@@ -2306,13 +2320,13 @@ void InitDescriptorMap() {
current = entity_descriptor_map[Type::IfcAudioVisualApplianceType] = new IfcEntityDescriptor(Type::IfcAudioVisualApplianceType,entity_descriptor_map.find(Type::IfcFlowTerminalType)->second); current = entity_descriptor_map[Type::IfcAudioVisualApplianceType] = new IfcEntityDescriptor(Type::IfcAudioVisualApplianceType,entity_descriptor_map.find(Type::IfcFlowTerminalType)->second);
current->add("PredefinedType",false,IfcUtil::Argument_ENUMERATION,Type::IfcAudioVisualApplianceTypeEnum); current->add("PredefinedType",false,IfcUtil::Argument_ENUMERATION,Type::IfcAudioVisualApplianceTypeEnum);
current = entity_descriptor_map[Type::IfcBSplineCurve] = new IfcEntityDescriptor(Type::IfcBSplineCurve,entity_descriptor_map.find(Type::IfcBoundedCurve)->second); current = entity_descriptor_map[Type::IfcBSplineCurve] = new IfcEntityDescriptor(Type::IfcBSplineCurve,entity_descriptor_map.find(Type::IfcBoundedCurve)->second);
current->add("Degree",false,IfcUtil::Argument_INT,Type::UNDEFINED); current->add("Degree",false,IfcUtil::Argument_INT,Type::IfcInteger);
current->add("ControlPointsList",false,IfcUtil::Argument_AGGREGATE_OF_ENTITY_INSTANCE,Type::IfcCartesianPoint); current->add("ControlPointsList",false,IfcUtil::Argument_AGGREGATE_OF_ENTITY_INSTANCE,Type::IfcCartesianPoint);
current->add("CurveForm",false,IfcUtil::Argument_ENUMERATION,Type::IfcBSplineCurveForm); current->add("CurveForm",false,IfcUtil::Argument_ENUMERATION,Type::IfcBSplineCurveForm);
current->add("ClosedCurve",false,IfcUtil::Argument_BOOL,Type::UNDEFINED); current->add("ClosedCurve",false,IfcUtil::Argument_BOOL,Type::IfcLogical);
current->add("SelfIntersect",false,IfcUtil::Argument_BOOL,Type::UNDEFINED); current->add("SelfIntersect",false,IfcUtil::Argument_BOOL,Type::IfcLogical);
current = entity_descriptor_map[Type::IfcBSplineCurveWithKnots] = new IfcEntityDescriptor(Type::IfcBSplineCurveWithKnots,entity_descriptor_map.find(Type::IfcBSplineCurve)->second); current = entity_descriptor_map[Type::IfcBSplineCurveWithKnots] = new IfcEntityDescriptor(Type::IfcBSplineCurveWithKnots,entity_descriptor_map.find(Type::IfcBSplineCurve)->second);
current->add("KnotMultiplicities",false,IfcUtil::Argument_AGGREGATE_OF_INT,Type::UNDEFINED); current->add("KnotMultiplicities",false,IfcUtil::Argument_AGGREGATE_OF_INT,Type::IfcInteger);
current->add("Knots",false,IfcUtil::Argument_AGGREGATE_OF_DOUBLE,Type::IfcParameterValue); current->add("Knots",false,IfcUtil::Argument_AGGREGATE_OF_DOUBLE,Type::IfcParameterValue);
current->add("KnotSpec",false,IfcUtil::Argument_ENUMERATION,Type::IfcKnotType); current->add("KnotSpec",false,IfcUtil::Argument_ENUMERATION,Type::IfcKnotType);
current = entity_descriptor_map[Type::IfcBeamType] = new IfcEntityDescriptor(Type::IfcBeamType,entity_descriptor_map.find(Type::IfcBuildingElementType)->second); current = entity_descriptor_map[Type::IfcBeamType] = new IfcEntityDescriptor(Type::IfcBeamType,entity_descriptor_map.find(Type::IfcBuildingElementType)->second);
@@ -2333,6 +2347,7 @@ void InitDescriptorMap() {
current->add("PredefinedType",false,IfcUtil::Argument_ENUMERATION,Type::IfcBuildingElementProxyTypeEnum); current->add("PredefinedType",false,IfcUtil::Argument_ENUMERATION,Type::IfcBuildingElementProxyTypeEnum);
current = entity_descriptor_map[Type::IfcBuildingSystem] = new IfcEntityDescriptor(Type::IfcBuildingSystem,entity_descriptor_map.find(Type::IfcSystem)->second); current = entity_descriptor_map[Type::IfcBuildingSystem] = new IfcEntityDescriptor(Type::IfcBuildingSystem,entity_descriptor_map.find(Type::IfcSystem)->second);
current->add("PredefinedType",true,IfcUtil::Argument_ENUMERATION,Type::IfcBuildingSystemTypeEnum); current->add("PredefinedType",true,IfcUtil::Argument_ENUMERATION,Type::IfcBuildingSystemTypeEnum);
current->add("LongName",true,IfcUtil::Argument_STRING,Type::IfcLabel);
current = entity_descriptor_map[Type::IfcBurnerType] = new IfcEntityDescriptor(Type::IfcBurnerType,entity_descriptor_map.find(Type::IfcEnergyConversionDeviceType)->second); current = entity_descriptor_map[Type::IfcBurnerType] = new IfcEntityDescriptor(Type::IfcBurnerType,entity_descriptor_map.find(Type::IfcEnergyConversionDeviceType)->second);
current->add("PredefinedType",false,IfcUtil::Argument_ENUMERATION,Type::IfcBurnerTypeEnum); current->add("PredefinedType",false,IfcUtil::Argument_ENUMERATION,Type::IfcBurnerTypeEnum);
current = entity_descriptor_map[Type::IfcCableCarrierFittingType] = new IfcEntityDescriptor(Type::IfcCableCarrierFittingType,entity_descriptor_map.find(Type::IfcFlowFittingType)->second); current = entity_descriptor_map[Type::IfcCableCarrierFittingType] = new IfcEntityDescriptor(Type::IfcCableCarrierFittingType,entity_descriptor_map.find(Type::IfcFlowFittingType)->second);
@@ -2508,7 +2523,7 @@ void InitDescriptorMap() {
current = entity_descriptor_map[Type::IfcRampFlight] = new IfcEntityDescriptor(Type::IfcRampFlight,entity_descriptor_map.find(Type::IfcBuildingElement)->second); current = entity_descriptor_map[Type::IfcRampFlight] = new IfcEntityDescriptor(Type::IfcRampFlight,entity_descriptor_map.find(Type::IfcBuildingElement)->second);
current->add("PredefinedType",true,IfcUtil::Argument_ENUMERATION,Type::IfcRampFlightTypeEnum); current->add("PredefinedType",true,IfcUtil::Argument_ENUMERATION,Type::IfcRampFlightTypeEnum);
current = entity_descriptor_map[Type::IfcRationalBSplineCurveWithKnots] = new IfcEntityDescriptor(Type::IfcRationalBSplineCurveWithKnots,entity_descriptor_map.find(Type::IfcBSplineCurveWithKnots)->second); current = entity_descriptor_map[Type::IfcRationalBSplineCurveWithKnots] = new IfcEntityDescriptor(Type::IfcRationalBSplineCurveWithKnots,entity_descriptor_map.find(Type::IfcBSplineCurveWithKnots)->second);
current->add("WeightsData",false,IfcUtil::Argument_AGGREGATE_OF_DOUBLE,Type::UNDEFINED); current->add("WeightsData",false,IfcUtil::Argument_AGGREGATE_OF_DOUBLE,Type::IfcReal);
current = entity_descriptor_map[Type::IfcReinforcingBar] = new IfcEntityDescriptor(Type::IfcReinforcingBar,entity_descriptor_map.find(Type::IfcReinforcingElement)->second); current = entity_descriptor_map[Type::IfcReinforcingBar] = new IfcEntityDescriptor(Type::IfcReinforcingBar,entity_descriptor_map.find(Type::IfcReinforcingElement)->second);
current->add("NominalDiameter",true,IfcUtil::Argument_DOUBLE,Type::IfcPositiveLengthMeasure); current->add("NominalDiameter",true,IfcUtil::Argument_DOUBLE,Type::IfcPositiveLengthMeasure);
current->add("CrossSectionArea",true,IfcUtil::Argument_DOUBLE,Type::IfcAreaMeasure); current->add("CrossSectionArea",true,IfcUtil::Argument_DOUBLE,Type::IfcAreaMeasure);
@@ -2546,8 +2561,8 @@ void InitDescriptorMap() {
current = entity_descriptor_map[Type::IfcStair] = new IfcEntityDescriptor(Type::IfcStair,entity_descriptor_map.find(Type::IfcBuildingElement)->second); current = entity_descriptor_map[Type::IfcStair] = new IfcEntityDescriptor(Type::IfcStair,entity_descriptor_map.find(Type::IfcBuildingElement)->second);
current->add("PredefinedType",true,IfcUtil::Argument_ENUMERATION,Type::IfcStairTypeEnum); current->add("PredefinedType",true,IfcUtil::Argument_ENUMERATION,Type::IfcStairTypeEnum);
current = entity_descriptor_map[Type::IfcStairFlight] = new IfcEntityDescriptor(Type::IfcStairFlight,entity_descriptor_map.find(Type::IfcBuildingElement)->second); current = entity_descriptor_map[Type::IfcStairFlight] = new IfcEntityDescriptor(Type::IfcStairFlight,entity_descriptor_map.find(Type::IfcBuildingElement)->second);
current->add("NumberOfRiser",true,IfcUtil::Argument_INT,Type::UNDEFINED); current->add("NumberOfRisers",true,IfcUtil::Argument_INT,Type::IfcInteger);
current->add("NumberOfTreads",true,IfcUtil::Argument_INT,Type::UNDEFINED); current->add("NumberOfTreads",true,IfcUtil::Argument_INT,Type::IfcInteger);
current->add("RiserHeight",true,IfcUtil::Argument_DOUBLE,Type::IfcPositiveLengthMeasure); current->add("RiserHeight",true,IfcUtil::Argument_DOUBLE,Type::IfcPositiveLengthMeasure);
current->add("TreadLength",true,IfcUtil::Argument_DOUBLE,Type::IfcPositiveLengthMeasure); current->add("TreadLength",true,IfcUtil::Argument_DOUBLE,Type::IfcPositiveLengthMeasure);
current->add("PredefinedType",true,IfcUtil::Argument_ENUMERATION,Type::IfcStairFlightTypeEnum); current->add("PredefinedType",true,IfcUtil::Argument_ENUMERATION,Type::IfcStairFlightTypeEnum);
@@ -4212,13 +4227,16 @@ void InitDescriptorMap() {
values.push_back("TAPERED"); values.push_back("TAPERED");
current_enum = enumeration_descriptor_map[Type::IfcSectionTypeEnum] = new IfcEnumerationDescriptor(Type::IfcSectionTypeEnum, values); current_enum = enumeration_descriptor_map[Type::IfcSectionTypeEnum] = new IfcEnumerationDescriptor(Type::IfcSectionTypeEnum, values);
values.clear(); values.reserve(128); values.clear(); values.reserve(128);
values.push_back("CO2SENSOR");
values.push_back("CONDUCTANCESENSOR"); values.push_back("CONDUCTANCESENSOR");
values.push_back("CONTACTSENSOR"); values.push_back("CONTACTSENSOR");
values.push_back("FIRESENSOR"); values.push_back("FIRESENSOR");
values.push_back("FLOWSENSOR"); values.push_back("FLOWSENSOR");
values.push_back("FROSTSENSOR");
values.push_back("GASSENSOR"); values.push_back("GASSENSOR");
values.push_back("HEATSENSOR"); values.push_back("HEATSENSOR");
values.push_back("HUMIDITYSENSOR"); values.push_back("HUMIDITYSENSOR");
values.push_back("IDENTIFIERSENSOR");
values.push_back("IONCONCENTRATIONSENSOR"); values.push_back("IONCONCENTRATIONSENSOR");
values.push_back("LEVELSENSOR"); values.push_back("LEVELSENSOR");
values.push_back("LIGHTSENSOR"); values.push_back("LIGHTSENSOR");
@@ -4738,7 +4756,6 @@ void InitInverseMap() {
inverse_map[Type::IfcApproval].insert(std::make_pair("ApprovedResources", std::make_pair(Type::IfcResourceApprovalRelationship, 3))); inverse_map[Type::IfcApproval].insert(std::make_pair("ApprovedResources", std::make_pair(Type::IfcResourceApprovalRelationship, 3)));
inverse_map[Type::IfcApproval].insert(std::make_pair("IsRelatedWith", std::make_pair(Type::IfcApprovalRelationship, 3))); inverse_map[Type::IfcApproval].insert(std::make_pair("IsRelatedWith", std::make_pair(Type::IfcApprovalRelationship, 3)));
inverse_map[Type::IfcApproval].insert(std::make_pair("Relates", std::make_pair(Type::IfcApprovalRelationship, 2))); inverse_map[Type::IfcApproval].insert(std::make_pair("Relates", std::make_pair(Type::IfcApprovalRelationship, 2)));
inverse_map[Type::IfcBuildingElement].insert(std::make_pair("HasCoverings", std::make_pair(Type::IfcRelCoversBldgElements, 4)));
inverse_map[Type::IfcClassification].insert(std::make_pair("ClassificationForObjects", std::make_pair(Type::IfcRelAssociatesClassification, 5))); inverse_map[Type::IfcClassification].insert(std::make_pair("ClassificationForObjects", std::make_pair(Type::IfcRelAssociatesClassification, 5)));
inverse_map[Type::IfcClassification].insert(std::make_pair("HasReferences", std::make_pair(Type::IfcClassificationReference, 3))); inverse_map[Type::IfcClassification].insert(std::make_pair("HasReferences", std::make_pair(Type::IfcClassificationReference, 3)));
inverse_map[Type::IfcClassificationReference].insert(std::make_pair("ClassificationRefForObjects", std::make_pair(Type::IfcRelAssociatesClassification, 5))); inverse_map[Type::IfcClassificationReference].insert(std::make_pair("ClassificationRefForObjects", std::make_pair(Type::IfcRelAssociatesClassification, 5)));
@@ -4751,6 +4768,7 @@ void InitInverseMap() {
inverse_map[Type::IfcContextDependentUnit].insert(std::make_pair("HasExternalReference", std::make_pair(Type::IfcExternalReferenceRelationship, 3))); inverse_map[Type::IfcContextDependentUnit].insert(std::make_pair("HasExternalReference", std::make_pair(Type::IfcExternalReferenceRelationship, 3)));
inverse_map[Type::IfcControl].insert(std::make_pair("Controls", std::make_pair(Type::IfcRelAssignsToControl, 6))); inverse_map[Type::IfcControl].insert(std::make_pair("Controls", std::make_pair(Type::IfcRelAssignsToControl, 6)));
inverse_map[Type::IfcConversionBasedUnit].insert(std::make_pair("HasExternalReference", std::make_pair(Type::IfcExternalReferenceRelationship, 3))); inverse_map[Type::IfcConversionBasedUnit].insert(std::make_pair("HasExternalReference", std::make_pair(Type::IfcExternalReferenceRelationship, 3)));
inverse_map[Type::IfcCoordinateReferenceSystem].insert(std::make_pair("HasCoordinateOperation", std::make_pair(Type::IfcCoordinateOperation, 0)));
inverse_map[Type::IfcCovering].insert(std::make_pair("CoversSpaces", std::make_pair(Type::IfcRelCoversSpaces, 5))); inverse_map[Type::IfcCovering].insert(std::make_pair("CoversSpaces", std::make_pair(Type::IfcRelCoversSpaces, 5)));
inverse_map[Type::IfcCovering].insert(std::make_pair("CoversElements", std::make_pair(Type::IfcRelCoversBldgElements, 5))); inverse_map[Type::IfcCovering].insert(std::make_pair("CoversElements", std::make_pair(Type::IfcRelCoversBldgElements, 5)));
inverse_map[Type::IfcDistributionControlElement].insert(std::make_pair("AssignedToFlowElement", std::make_pair(Type::IfcRelFlowControlElements, 4))); inverse_map[Type::IfcDistributionControlElement].insert(std::make_pair("AssignedToFlowElement", std::make_pair(Type::IfcRelFlowControlElements, 4)));
@@ -4772,12 +4790,14 @@ void InitInverseMap() {
inverse_map[Type::IfcElement].insert(std::make_pair("ProvidesBoundaries", std::make_pair(Type::IfcRelSpaceBoundary, 5))); inverse_map[Type::IfcElement].insert(std::make_pair("ProvidesBoundaries", std::make_pair(Type::IfcRelSpaceBoundary, 5)));
inverse_map[Type::IfcElement].insert(std::make_pair("ConnectedFrom", std::make_pair(Type::IfcRelConnectsElements, 6))); inverse_map[Type::IfcElement].insert(std::make_pair("ConnectedFrom", std::make_pair(Type::IfcRelConnectsElements, 6)));
inverse_map[Type::IfcElement].insert(std::make_pair("ContainedInStructure", std::make_pair(Type::IfcRelContainedInSpatialStructure, 4))); inverse_map[Type::IfcElement].insert(std::make_pair("ContainedInStructure", std::make_pair(Type::IfcRelContainedInSpatialStructure, 4)));
inverse_map[Type::IfcElement].insert(std::make_pair("HasCoverings", std::make_pair(Type::IfcRelCoversBldgElements, 4)));
inverse_map[Type::IfcExternalReference].insert(std::make_pair("ExternalReferenceForResources", std::make_pair(Type::IfcExternalReferenceRelationship, 2))); inverse_map[Type::IfcExternalReference].insert(std::make_pair("ExternalReferenceForResources", std::make_pair(Type::IfcExternalReferenceRelationship, 2)));
inverse_map[Type::IfcExternalSpatialElement].insert(std::make_pair("BoundedBy", std::make_pair(Type::IfcRelSpaceBoundary, 4))); inverse_map[Type::IfcExternalSpatialElement].insert(std::make_pair("BoundedBy", std::make_pair(Type::IfcRelSpaceBoundary, 4)));
inverse_map[Type::IfcFace].insert(std::make_pair("HasTextureMaps", std::make_pair(Type::IfcTextureMap, 2))); inverse_map[Type::IfcFace].insert(std::make_pair("HasTextureMaps", std::make_pair(Type::IfcTextureMap, 2)));
inverse_map[Type::IfcFeatureElementAddition].insert(std::make_pair("ProjectsElements", std::make_pair(Type::IfcRelProjectsElement, 5))); inverse_map[Type::IfcFeatureElementAddition].insert(std::make_pair("ProjectsElements", std::make_pair(Type::IfcRelProjectsElement, 5)));
inverse_map[Type::IfcFeatureElementSubtraction].insert(std::make_pair("VoidsElements", std::make_pair(Type::IfcRelVoidsElement, 5))); inverse_map[Type::IfcFeatureElementSubtraction].insert(std::make_pair("VoidsElements", std::make_pair(Type::IfcRelVoidsElement, 5)));
inverse_map[Type::IfcGeometricRepresentationContext].insert(std::make_pair("HasSubContexts", std::make_pair(Type::IfcGeometricRepresentationSubContext, 6))); inverse_map[Type::IfcGeometricRepresentationContext].insert(std::make_pair("HasSubContexts", std::make_pair(Type::IfcGeometricRepresentationSubContext, 6)));
inverse_map[Type::IfcGeometricRepresentationContext].insert(std::make_pair("HasCoordinateOperation", std::make_pair(Type::IfcCoordinateOperation, 0)));
inverse_map[Type::IfcGrid].insert(std::make_pair("ContainedInStructure", std::make_pair(Type::IfcRelContainedInSpatialStructure, 4))); inverse_map[Type::IfcGrid].insert(std::make_pair("ContainedInStructure", std::make_pair(Type::IfcRelContainedInSpatialStructure, 4)));
inverse_map[Type::IfcGridAxis].insert(std::make_pair("PartOfW", std::make_pair(Type::IfcGrid, 9))); inverse_map[Type::IfcGridAxis].insert(std::make_pair("PartOfW", std::make_pair(Type::IfcGrid, 9)));
inverse_map[Type::IfcGridAxis].insert(std::make_pair("PartOfV", std::make_pair(Type::IfcGrid, 8))); inverse_map[Type::IfcGridAxis].insert(std::make_pair("PartOfV", std::make_pair(Type::IfcGrid, 8)));
@@ -4832,6 +4852,8 @@ void InitInverseMap() {
inverse_map[Type::IfcProperty].insert(std::make_pair("PropertyForDependance", std::make_pair(Type::IfcPropertyDependencyRelationship, 2))); inverse_map[Type::IfcProperty].insert(std::make_pair("PropertyForDependance", std::make_pair(Type::IfcPropertyDependencyRelationship, 2)));
inverse_map[Type::IfcProperty].insert(std::make_pair("PropertyDependsOn", std::make_pair(Type::IfcPropertyDependencyRelationship, 3))); inverse_map[Type::IfcProperty].insert(std::make_pair("PropertyDependsOn", std::make_pair(Type::IfcPropertyDependencyRelationship, 3)));
inverse_map[Type::IfcProperty].insert(std::make_pair("PartOfComplex", std::make_pair(Type::IfcComplexProperty, 3))); inverse_map[Type::IfcProperty].insert(std::make_pair("PartOfComplex", std::make_pair(Type::IfcComplexProperty, 3)));
inverse_map[Type::IfcProperty].insert(std::make_pair("HasConstraints", std::make_pair(Type::IfcResourceConstraintRelationship, 3)));
inverse_map[Type::IfcProperty].insert(std::make_pair("HasApprovals", std::make_pair(Type::IfcResourceApprovalRelationship, 2)));
inverse_map[Type::IfcPropertyAbstraction].insert(std::make_pair("HasExternalReferences", std::make_pair(Type::IfcExternalReferenceRelationship, 3))); inverse_map[Type::IfcPropertyAbstraction].insert(std::make_pair("HasExternalReferences", std::make_pair(Type::IfcExternalReferenceRelationship, 3)));
inverse_map[Type::IfcPropertyDefinition].insert(std::make_pair("HasContext", std::make_pair(Type::IfcRelDeclares, 5))); inverse_map[Type::IfcPropertyDefinition].insert(std::make_pair("HasContext", std::make_pair(Type::IfcRelDeclares, 5)));
inverse_map[Type::IfcPropertyDefinition].insert(std::make_pair("HasAssociations", std::make_pair(Type::IfcRelAssociates, 4))); inverse_map[Type::IfcPropertyDefinition].insert(std::make_pair("HasAssociations", std::make_pair(Type::IfcRelAssociates, 4)));
@@ -4868,7 +4890,6 @@ void InitInverseMap() {
inverse_map[Type::IfcSurfaceTexture].insert(std::make_pair("IsMappedBy", std::make_pair(Type::IfcTextureCoordinate, 0))); inverse_map[Type::IfcSurfaceTexture].insert(std::make_pair("IsMappedBy", std::make_pair(Type::IfcTextureCoordinate, 0)));
inverse_map[Type::IfcSurfaceTexture].insert(std::make_pair("UsedInStyles", std::make_pair(Type::IfcSurfaceStyleWithTextures, 0))); inverse_map[Type::IfcSurfaceTexture].insert(std::make_pair("UsedInStyles", std::make_pair(Type::IfcSurfaceStyleWithTextures, 0)));
inverse_map[Type::IfcSystem].insert(std::make_pair("ServicesBuildings", std::make_pair(Type::IfcRelServicesBuildings, 4))); inverse_map[Type::IfcSystem].insert(std::make_pair("ServicesBuildings", std::make_pair(Type::IfcRelServicesBuildings, 4)));
inverse_map[Type::IfcTableRow].insert(std::make_pair("OfTable", std::make_pair(Type::IfcTable, 1)));
inverse_map[Type::IfcTessellatedFaceSet].insert(std::make_pair("HasColours", std::make_pair(Type::IfcIndexedColourMap, 0))); inverse_map[Type::IfcTessellatedFaceSet].insert(std::make_pair("HasColours", std::make_pair(Type::IfcIndexedColourMap, 0)));
inverse_map[Type::IfcTessellatedFaceSet].insert(std::make_pair("HasTextures", std::make_pair(Type::IfcIndexedTextureMap, 1))); inverse_map[Type::IfcTessellatedFaceSet].insert(std::make_pair("HasTextures", std::make_pair(Type::IfcIndexedTextureMap, 1)));
inverse_map[Type::IfcTimeSeries].insert(std::make_pair("HasExternalReference", std::make_pair(Type::IfcExternalReferenceRelationship, 3))); inverse_map[Type::IfcTimeSeries].insert(std::make_pair("HasExternalReference", std::make_pair(Type::IfcExternalReferenceRelationship, 3)));
+111 -24
View File
File diff suppressed because one or more lines are too long
+185 -81
View File
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
+5 -2
View File
@@ -112,6 +112,9 @@ std::string IfcWritableEntity::toString(bool upper) const {
return ss.str(); return ss.str();
} }
unsigned int IfcWritableEntity::id() { unsigned int IfcWritableEntity::id() {
if (!file) {
return 0;
}
if ( !_id ) { if ( !_id ) {
_id = new int(file->FreshId()); _id = new int(file->FreshId());
} }
@@ -414,8 +417,8 @@ public:
void operator()(const IfcEntityListList::ptr& i) { void operator()(const IfcEntityListList::ptr& i) {
data << "("; data << "(";
for (IfcEntityListList::outer_it outer_it = i->begin(); outer_it != i->end(); ++outer_it) { for (IfcEntityListList::outer_it outer_it = i->begin(); outer_it != i->end(); ++outer_it) {
data << "(";
if (outer_it != i->begin()) data << ","; if (outer_it != i->begin()) data << ",";
data << "(";
for (IfcEntityListList::inner_it inner_it = outer_it->begin(); inner_it != outer_it->end(); ++inner_it) { for (IfcEntityListList::inner_it inner_it = outer_it->begin(); inner_it != outer_it->end(); ++inner_it) {
if (inner_it != outer_it->begin()) data << ","; if (inner_it != outer_it->begin()) data << ",";
(*this)(*inner_it); (*this)(*inner_it);
@@ -501,7 +504,7 @@ IfcWriteArgument::operator std::vector< boost::dynamic_bitset<> >() const { retu
IfcWriteArgument::operator IfcEntityList::ptr() const { return as<IfcEntityList::ptr>(); } IfcWriteArgument::operator IfcEntityList::ptr() const { return as<IfcEntityList::ptr>(); }
IfcWriteArgument::operator std::vector< std::vector<int> >() const { return as<std::vector< std::vector<int> > >(); } IfcWriteArgument::operator std::vector< std::vector<int> >() const { return as<std::vector< std::vector<int> > >(); }
IfcWriteArgument::operator std::vector< std::vector<double> >() const { return as<std::vector< std::vector<double> > >(); } IfcWriteArgument::operator std::vector< std::vector<double> >() const { return as<std::vector< std::vector<double> > >(); }
IfcWriteArgument::operator IfcEntityListList::ptr() const { throw; } IfcWriteArgument::operator IfcEntityListList::ptr() const { return as<IfcEntityListList::ptr>(); }
bool IfcWriteArgument::isNull() const { return type() == IfcUtil::Argument_NULL; } bool IfcWriteArgument::isNull() const { return type() == IfcUtil::Argument_NULL; }
Argument* IfcWriteArgument::operator [] (unsigned int /*i*/) const { throw IfcParse::IfcException("Invalid cast"); } Argument* IfcWriteArgument::operator [] (unsigned int /*i*/) const { throw IfcParse::IfcException("Invalid cast"); }
std::string IfcWriteArgument::toString(bool upper) const { std::string IfcWriteArgument::toString(bool upper) const {
+2
View File
@@ -73,6 +73,8 @@ IF(PYTHONINTERP_FOUND)
DESTINATION "${python_package_dir}/ifcopenshell") DESTINATION "${python_package_dir}/ifcopenshell")
INSTALL(FILES INSTALL(FILES
"${CMAKE_CURRENT_SOURCE_DIR}/../ifcopenshell-python/ifcopenshell/geom/__init__.py" "${CMAKE_CURRENT_SOURCE_DIR}/../ifcopenshell-python/ifcopenshell/geom/__init__.py"
"${CMAKE_CURRENT_SOURCE_DIR}/../ifcopenshell-python/ifcopenshell/geom/app.py"
"${CMAKE_CURRENT_SOURCE_DIR}/../ifcopenshell-python/ifcopenshell/geom/main.py"
"${CMAKE_CURRENT_SOURCE_DIR}/../ifcopenshell-python/ifcopenshell/geom/occ_utils.py" "${CMAKE_CURRENT_SOURCE_DIR}/../ifcopenshell-python/ifcopenshell/geom/occ_utils.py"
DESTINATION "${python_package_dir}/ifcopenshell/geom") DESTINATION "${python_package_dir}/ifcopenshell/geom")
INSTALL(TARGETS _ifcopenshell_wrapper DESTINATION "${python_package_dir}/ifcopenshell") INSTALL(TARGETS _ifcopenshell_wrapper DESTINATION "${python_package_dir}/ifcopenshell")
+1
View File
@@ -168,6 +168,7 @@ struct ShapeRTTI : public boost::static_visitor<PyObject*>
# Hide the getters with read-only property implementations # Hide the getters with read-only property implementations
id = property(id) id = property(id)
brep_data = property(brep_data) brep_data = property(brep_data)
surface_styles = property(surface_styles)
%} %}
}; };
+22
View File
@@ -124,6 +124,18 @@ namespace IfcUtil {
unsigned i = IfcSchema::Type::GetAttributeIndex($self->type(), a); unsigned i = IfcSchema::Type::GetAttributeIndex($self->type(), a);
return std::pair<IfcUtil::ArgumentType,Argument*>($self->getArgumentType(i), $self->getArgument(i)); return std::pair<IfcUtil::ArgumentType,Argument*>($self->getArgumentType(i), $self->getArgument(i));
} }
bool __eq__(IfcParse::IfcLateBoundEntity* other) const {
if ($self == other) {
return true;
}
return $self->id() == other->id() && $self->entity->file == other->entity->file;
}
// Just something to have a somewhat sensible value to hash
size_t file_pointer() const {
return reinterpret_cast<size_t>($self->entity->file);
}
} }
%extend IfcParse::IfcSpfHeader { %extend IfcParse::IfcSpfHeader {
@@ -208,4 +220,14 @@ namespace IfcUtil {
const char* const version() { const char* const version() {
return IFCOPENSHELL_VERSION; return IFCOPENSHELL_VERSION;
} }
std::string get_supertype(std::string n) {
boost::to_upper(n);
IfcSchema::Type::Enum t = IfcSchema::Type::FromString(n);
if (IfcSchema::Type::Parent(t)) {
return IfcSchema::Type::ToString(*IfcSchema::Type::Parent(t));
} else {
return "";
}
}
%} %}