Module Contents#

class ifcopenshell.api.cost.copy_cost_item.Usecase(file, cost_item=None)#

Copies all cost items and related relationships

The following relationships are also duplicated:

  • The copy will have the same attributes and property sets as the original cost item

  • The copy will be assigned to the parent cost schedule

  • The copy will have duplicated nested cost items


cost_item (ifcopenshell.entity_instance.entity_instance) – The cost item to be duplicated


The duplicated cost item or the list of duplicated cost items if the latter has children

Return type

ifcopenshell.entity_instance.entity_instance or list of ifcopenshell.entity_instance.entity_instance

Example: .. code:: python

# We have a cost item cost_item = CostItem(name=”Design new feature”, deadline=”2023-03-01”)

# And now we have two duplicated_cost_item = project.duplicate_cost_item(cost_item)

copy_indirect_attributes(self, from_element, to_element)#
duplicate_cost_item(self, cost_item)#