ifcpatch.recipes.ExtractPropertiesToSQLite

Module Contents

class ifcpatch.recipes.ExtractPropertiesToSQLite.ElementRow

Bases: NamedTuple

class_: str
description: str | None
element_id: int
guid: str
name: str | None
predefined_type: str | None
class ifcpatch.recipes.ExtractPropertiesToSQLite.Patcher(file: ifcopenshell.file, logger: logging.Logger | None = None)

Bases: ifcpatch.BasePatcher

Extracts properties and relationships from a IFC-SPF model to SQLite.

This is a lossy extraction which simplifies popular properties to key value pairs.

Example:

result = ifcpatch.execute({"input": fn, "file": model, "recipe": "ExtractPropertiesToSQLite"})
ifcpatch.write(result, "output.sqlite")
patch()
class ifcpatch.recipes.ExtractPropertiesToSQLite.PropertyRow

Bases: NamedTuple

element_id: int
name: str
pset_name: str
value: str
class ifcpatch.recipes.ExtractPropertiesToSQLite.RelationshipRow

Bases: NamedTuple

element_id: int
rel_ifc_class: str
to_id: int