mirror of
https://github.com/IfcOpenShell/IfcOpenShell.git
synced 2026-08-09 17:31:45 +00:00
assign/unassign layer - mention representations
This commit is contained in:
@@ -22,7 +22,7 @@ import ifcopenshell
|
||||
def assign_layer(
|
||||
file: ifcopenshell.file, items: list[ifcopenshell.entity_instance], layer: ifcopenshell.entity_instance
|
||||
) -> None:
|
||||
"""Assigns representation items to a layer
|
||||
"""Assigns representation items or representations to a layer
|
||||
|
||||
In IFC, instead of objects being assigned to layers, representation
|
||||
items are assigned to layers. Representation items are portions of the
|
||||
@@ -31,7 +31,7 @@ def assign_layer(
|
||||
its frame) assigned to one layer, and another portion (e.g. the glazing
|
||||
panels) assigned to another layer.
|
||||
|
||||
:param items: The list of IfcRepresentationItems to assign to the layer. This
|
||||
:param items: The list of IfcRepresentationItems / IfcRepresentations to assign to the layer. This
|
||||
should be the items from the object's IfcShapeRepresentation.
|
||||
:param layer: The IfcPresentationLayerAssignment layer to assign the
|
||||
item to.
|
||||
|
||||
@@ -23,14 +23,13 @@ import ifcopenshell.util.element
|
||||
def unassign_layer(
|
||||
file: ifcopenshell.file, items: list[ifcopenshell.entity_instance], layer: ifcopenshell.entity_instance
|
||||
) -> None:
|
||||
"""Unassigns representation items from a layer
|
||||
"""Unassigns representation items or representations from a layer
|
||||
|
||||
If the representation item isn't assigned to the layer, nothing will
|
||||
happen.
|
||||
If the element isn't assigned to the layer, nothing will happen.
|
||||
If after unassignment layer won't have any assigned items it will be
|
||||
removed to keep IFC valid.
|
||||
|
||||
:param items: A list IfcRepresentationItem elements to unassign
|
||||
:param items: A list IfcRepresentationItem / IfcRepresentation elements to unassign
|
||||
:param layer: The IfcPresentationLayerAssignment to unassign from
|
||||
:return: None
|
||||
|
||||
|
||||
Reference in New Issue
Block a user