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

Method ifc_select

src/ifcmcp/ifcmcp/core.py:280–287  ·  view source on GitHub ↗

Filter elements using ifcopenshell selector syntax. Examples: ``IfcWall``, ``IfcWall, IfcColumn``, ``! IfcWall``, ``IfcWall, Name = "My Wall"``, ``type = "Concrete Wall"``, ``material = "Concrete"``.

(self, query: str)

Source from the content-addressed store, hash-verified

278 return info.info(model, element)
279
280 def ifc_select(self, query: str) -> list[dict[str, Any]]:
281 """Filter elements using ifcopenshell selector syntax.
282
283 Examples: ``IfcWall``, ``IfcWall, IfcColumn``, ``! IfcWall``,
284 ``IfcWall, Name = "My Wall"``, ``type = "Concrete Wall"``,
285 ``material = "Concrete"``.
286 """
287 return select.select(self._require_model(), query)
288
289 def ifc_relations(self, element_id: int, traverse: str = "") -> dict[str, Any] | list[dict[str, Any]]:
290 """Show relationships for an element. Set traverse='up' to walk hierarchy to IfcProject."""

Callers 5

ifc_selectFunction · 0.80
test_select_no_modelMethod · 0.80
test_select_wallsMethod · 0.80
test_select_slabsMethod · 0.80
test_select_no_matchMethod · 0.80

Calls 2

_require_modelMethod · 0.95
selectMethod · 0.45

Tested by 4

test_select_no_modelMethod · 0.64
test_select_wallsMethod · 0.64
test_select_slabsMethod · 0.64
test_select_no_matchMethod · 0.64