mirror of
https://github.com/IfcOpenShell/IfcOpenShell.git
synced 2026-08-10 17:58:20 +00:00
A few fixes of types and a typo (#1464)
This commit is contained in:
@@ -88,7 +88,7 @@ IfcUtil::IfcBaseClass* execute_based_on_schema(
|
||||
return fn_4x3_rc1(shape, t);
|
||||
}
|
||||
#endif
|
||||
#ifdef HAS_SCHEMA_4x3_rx2
|
||||
#ifdef HAS_SCHEMA_4x3_rc2
|
||||
if (schema_name_lower == "ifc4x3_rc2") {
|
||||
return fn_4x3_rc2(shape, t);
|
||||
}
|
||||
|
||||
@@ -64,12 +64,12 @@ public:
|
||||
|
||||
boost::shared_ptr<IfcEntityList> getInverse (const IfcParse::declaration* type, int attribute_index) const;
|
||||
|
||||
Argument* getArgument(unsigned int i) const;
|
||||
Argument* getArgument(size_t i) const;
|
||||
|
||||
// NB: This makes a copy of the argument
|
||||
void setArgument(unsigned int i, Argument* a, IfcUtil::ArgumentType attr_type = IfcUtil::Argument_UNKNOWN);
|
||||
void setArgument(size_t i, Argument* a, IfcUtil::ArgumentType attr_type = IfcUtil::Argument_UNKNOWN);
|
||||
|
||||
virtual unsigned int getArgumentCount() const {
|
||||
virtual size_t getArgumentCount() const {
|
||||
if (type_ == 0) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
@@ -1038,7 +1038,7 @@ IfcEntityInstanceData::IfcEntityInstanceData(const IfcEntityInstanceData& e) {
|
||||
type_ = e.type_;
|
||||
id_ = 0;
|
||||
|
||||
const unsigned int count = e.getArgumentCount();
|
||||
const size_t count = e.getArgumentCount();
|
||||
|
||||
// In order not to have the instance read from file
|
||||
attributes_ = new Argument*[count];
|
||||
@@ -1051,7 +1051,7 @@ IfcEntityInstanceData::IfcEntityInstanceData(const IfcEntityInstanceData& e) {
|
||||
|
||||
static IfcParse::NullArgument static_null_attribute;
|
||||
|
||||
Argument* IfcEntityInstanceData::getArgument(unsigned int i) const {
|
||||
Argument* IfcEntityInstanceData::getArgument(size_t i) const {
|
||||
if (attributes_ == 0) {
|
||||
load();
|
||||
}
|
||||
@@ -1152,7 +1152,7 @@ public:
|
||||
if (attribute_) {
|
||||
apply_attribute_(t, attribute_);
|
||||
} else {
|
||||
for (unsigned i = 0; i < data_->getArgumentCount(); ++i) {
|
||||
for (size_t i = 0; i < data_->getArgumentCount(); ++i) {
|
||||
Argument* attr = data_->getArgument(i);
|
||||
apply_attribute_(t, attr);
|
||||
}
|
||||
@@ -1161,7 +1161,7 @@ public:
|
||||
|
||||
};
|
||||
|
||||
void IfcEntityInstanceData::setArgument(unsigned int i, Argument* a, IfcUtil::ArgumentType attr_type) {
|
||||
void IfcEntityInstanceData::setArgument(size_t i, Argument* a, IfcUtil::ArgumentType attr_type) {
|
||||
if (attributes_ == 0) {
|
||||
load();
|
||||
}
|
||||
@@ -1603,7 +1603,7 @@ IfcUtil::IfcBaseClass* IfcFile::addEntity(IfcUtil::IfcBaseClass* entity) {
|
||||
// information needs to be accounted for for IfcLengthMeasures.
|
||||
double conversion_factor = std::numeric_limits<double>::quiet_NaN();
|
||||
|
||||
for (unsigned i = 0; i < we->getArgumentCount(); ++i) {
|
||||
for (size_t i = 0; i < we->getArgumentCount(); ++i) {
|
||||
Argument* attr = we->getArgument(i);
|
||||
IfcUtil::ArgumentType attr_type = attr->type();
|
||||
|
||||
@@ -1819,7 +1819,7 @@ void IfcFile::process_deletion_() {
|
||||
continue;
|
||||
}
|
||||
|
||||
for (unsigned i = 0; i < related_instance->data().getArgumentCount(); ++i) {
|
||||
for (size_t i = 0; i < related_instance->data().getArgumentCount(); ++i) {
|
||||
Argument* attr = related_instance->data().getArgument(i);
|
||||
if (attr->isNull()) continue;
|
||||
|
||||
|
||||
@@ -50,7 +50,7 @@ protected:
|
||||
}
|
||||
|
||||
public:
|
||||
virtual unsigned int getArgumentCount() const {
|
||||
virtual size_t getArgumentCount() const {
|
||||
return size_;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user