Deep copy the current data element. Returns: BaseDataElement: The copy of current data element.
(self)
| 293 | return new_data |
| 294 | |
| 295 | def clone(self): |
| 296 | """Deep copy the current data element. |
| 297 | |
| 298 | Returns: |
| 299 | BaseDataElement: The copy of current data element. |
| 300 | """ |
| 301 | clone_data = self.__class__() |
| 302 | clone_data.set_metainfo(dict(self.metainfo_items())) |
| 303 | clone_data.set_data(dict(self.items())) |
| 304 | return clone_data |
| 305 | |
| 306 | def keys(self) -> list: |
| 307 | """ |