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

Method read_schema

src/ifcparse/IfcParse.cpp:2864–2880  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

2862}
2863
2864bool IfcParse::impl::rocks_db_file_storage::read_schema(const IfcParse::schema_definition*& schema) {
2865#ifdef IFOPSH_WITH_ROCKSDB
2866 std::string value;
2867 auto key = "h|file_schema|0";
2868 db->Get(rocksdb::ReadOptions{}, key, &value);
2869 std::vector<std::string> strings;
2870 if (::impl::deserialize(this, value, strings) && strings.size() == 1) {
2871 try {
2872 schema = schema_by_name(strings[0]);
2873 } catch (IfcException&) {
2874 return false;
2875 }
2876 return true;
2877 }
2878#endif
2879 return false;
2880}
2881
2882IfcUtil::IfcBaseClass::IfcBaseClass(IfcEntityInstanceData&& data)
2883 : identity_(counter_++)

Callers 1

initializeMethod · 0.80

Calls 4

deserializeFunction · 0.85
schema_by_nameFunction · 0.85
GetMethod · 0.80
sizeMethod · 0.45

Tested by

no test coverage detected