MCPcopy Create free account
hub / github.com/BatchDrake/SigDigger / copyFrom

Method copyFrom

Suscan/Object.cpp:68–85  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

66}
67
68void
69Object::copyFrom(const Object &obj)
70{
71 if (!this->borrowed) {
72 if (this->instance != nullptr) {
73 suscan_object_destroy(this->instance);
74 this->instance = nullptr;
75 }
76 }
77
78 if (obj.isHollow()) {
79 this->borrowed = true;
80 this->instance = nullptr;
81 } else {
82 this->borrowed = false;
83 SU_ATTEMPT(this->instance = suscan_object_copy(obj.instance));
84 }
85}
86
87void
88Object::clear(void)

Callers 2

setComponentConfigMethod · 0.80
deserializeMethod · 0.80

Calls 1

isHollowMethod · 0.80

Tested by

no test coverage detected