(self, other, copying)
| 940 | other_attribute)) |
| 941 | |
| 942 | def _sync_attributes(self, other, copying): |
| 943 | self._check_conflicting_attributes(other, copying) |
| 944 | for attribute_name, other_attribute in other.get_attributes().items(): |
| 945 | if attribute_name == constants.DCLASS: |
| 946 | attribute_name = constants.CLASS |
| 947 | |
| 948 | self_attribute = self._attributes[attribute_name] |
| 949 | if other_attribute is not None: |
| 950 | if self_attribute.conflict_behavior in _CONFLICT_BEHAVIOR_FUNC: |
| 951 | if self_attribute.value is not None: |
| 952 | self_attribute.value = ( |
| 953 | _CONFLICT_BEHAVIOR_FUNC[self_attribute.conflict_behavior]( |
| 954 | self_attribute.value, other_attribute)) |
| 955 | else: |
| 956 | self_attribute.value = other_attribute |
| 957 | elif copying or not self_attribute.conflict_allowed: |
| 958 | self_attribute.value = other_attribute |
| 959 | |
| 960 | def _attach_children(self, other, exclude_worldbody, dry_run=False): |
| 961 | for other_child in other.all_children(): |
no test coverage detected