// File: xjrueda[P]fixprime/src/Node.cpp
// Function: fprime::Node::operator=(fprime::Node const&)
fprime::Node& Node::operator=(const fprime::Node& other) {
        _type = other._type;
        value = other.value;
        isRequired = other.isRequired;
        field = other.field;
        protocolPtr = other.protocolPtr;
        componentPtr = other.componentPtr;

        fprime::DataHolderFactory factory;

        if (other._type == fprime::Node::NodeType::FIELD_NODE) {
            fprime::DataHolderFactory factory;
            value = factory.create(other.field->getDataType());
            this->value = factory.create(other.field->getDataType());
            const string val = other.value->get();
            this->value->set(val);
        }

        childsVector.clear();
        childsByFieldId.clear();

        for (NodeVector::const_iterator itr = other.childsVector.begin(); itr != other.childsVector.end(); itr++) {
            NodePtr newNode(new Node(**itr));
            childsVector.push_back(newNode);
            if (other._type == fprime::Node::NodeType::ROOT_NODE || other._type == fprime::Node::NodeType::GROUP_INSTANCE)
                childsByFieldId[newNode->getField()->getId()] = newNode;

            if (other._type == fprime::Node::NodeType::REPEATING_GROUP)
                childsByFieldId[childsVector.size()] = newNode;
        }
        return *this;
    }

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x1d0, %rsp            # imm = 0x1D0
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq -0x8(%rbp), %rdi
movq %rdi, -0x180(%rbp)
movq -0x10(%rbp), %rax
movl 0x8(%rax), %eax
movl %eax, 0x8(%rdi)
movq -0x10(%rbp), %rsi
addq $0x10, %rsi
addq $0x10, %rdi
callq 0x9d0f0
movq -0x180(%rbp), %rdi
movq -0x10(%rbp), %rax
movb 0x20(%rax), %al
andb $0x1, %al
movb %al, 0x20(%rdi)
movq -0x10(%rbp), %rsi
addq $0x28, %rsi
addq $0x28, %rdi
callq 0x992c0
movq -0x180(%rbp), %rdi
movq -0x10(%rbp), %rax
movq 0xd0(%rax), %rax
movq %rax, 0xd0(%rdi)
movq -0x10(%rbp), %rsi
addq $0xd8, %rsi
addq $0xd8, %rdi
callq 0x9dcc0
leaq -0x48(%rbp), %rdi
callq 0xa42e0
movq -0x10(%rbp), %rax
cmpl $0x1, 0x8(%rax)
jne 0xcbe6d
leaq -0x80(%rbp), %rdi
callq 0xa42e0
jmp 0xcbc4f
movq -0x10(%rbp), %rdi
addq $0x28, %rdi
callq 0x9d390
movq %rax, %rsi
leaq -0xc0(%rbp), %rdi
callq 0x9f700
jmp 0xcbc6d
leaq -0xa0(%rbp), %rdi
leaq -0x80(%rbp), %rsi
leaq -0xc0(%rbp), %rdx
callq 0x9e630
jmp 0xcbc86
movq -0x180(%rbp), %rdi
addq $0x10, %rdi
leaq -0xa0(%rbp), %rsi
movq %rsi, -0x188(%rbp)
callq 0x9d1f0
movq -0x188(%rbp), %rdi
callq 0xa1ae0
leaq -0xc0(%rbp), %rdi
callq 0xa4f00
movq -0x10(%rbp), %rdi
addq $0x28, %rdi
callq 0x9d390
movq %rax, %rsi
leaq -0xf0(%rbp), %rdi
callq 0x9f700
jmp 0xcbcda
leaq -0xd0(%rbp), %rdi
leaq -0x80(%rbp), %rsi
leaq -0xf0(%rbp), %rdx
callq 0x9e630
jmp 0xcbcf3
movq -0x180(%rbp), %rdi
addq $0x10, %rdi
leaq -0xd0(%rbp), %rsi
movq %rsi, -0x190(%rbp)
callq 0x9d1f0
movq -0x190(%rbp), %rdi
callq 0xa1ae0
leaq -0xf0(%rbp), %rdi
callq 0xa4f00
movq -0x10(%rbp), %rdi
addq $0x10, %rdi
callq 0x9a6e0
movq %rax, %rsi
movq (%rsi), %rax
movq 0x18(%rax), %rax
leaq -0x110(%rbp), %rdi
callq *%rax
jmp 0xcbd4b
movq -0x180(%rbp), %rdi
addq $0x10, %rdi
callq 0x9a6e0
movq %rax, -0x198(%rbp)
leaq -0x130(%rbp), %rdi
leaq -0x110(%rbp), %rsi
callq 0x998d0
jmp 0xcbd77
movq -0x198(%rbp), %rdi
movq (%rdi), %rax
movq 0x10(%rax), %rax
leaq -0x130(%rbp), %rsi
callq *%rax
jmp 0xcbd90
leaq -0x130(%rbp), %rdi
callq 0xa4f00
leaq -0x110(%rbp), %rdi
callq 0xa4f00
leaq -0x80(%rbp), %rdi
callq 0xa4380
jmp 0xcbe6d
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x88(%rbp)
movl %eax, -0x8c(%rbp)
jmp 0xcc0ea
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x88(%rbp)
movl %eax, -0x8c(%rbp)
jmp 0xcbe5f
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x88(%rbp)
movl %eax, -0x8c(%rbp)
leaq -0xc0(%rbp), %rdi
callq 0xa4f00
jmp 0xcbe5f
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x88(%rbp)
movl %eax, -0x8c(%rbp)
leaq -0xf0(%rbp), %rdi
callq 0xa4f00
jmp 0xcbe5f
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x88(%rbp)
movl %eax, -0x8c(%rbp)
jmp 0xcbe53
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x88(%rbp)
movl %eax, -0x8c(%rbp)
leaq -0x130(%rbp), %rdi
callq 0xa4f00
leaq -0x110(%rbp), %rdi
callq 0xa4f00
leaq -0x80(%rbp), %rdi
callq 0xa4380
jmp 0xcc0ea
movq -0x180(%rbp), %rdi
addq $0x38, %rdi
callq 0xa1310
movq -0x180(%rbp), %rdi
addq $0x50, %rdi
callq 0x97740
movq -0x10(%rbp), %rdi
addq $0x38, %rdi
callq 0xa2160
movq %rax, -0x138(%rbp)
movq -0x10(%rbp), %rdi
addq $0x38, %rdi
callq 0x9a070
movq %rax, -0x140(%rbp)
leaq -0x138(%rbp), %rdi
leaq -0x140(%rbp), %rsi
callq 0x9e580
testb $0x1, %al
jne 0xcbed1
jmp 0xcc0d1
movl $0xe8, %edi
callq 0x9dc00
movq %rax, -0x1a0(%rbp)
jmp 0xcbee4
leaq -0x138(%rbp), %rdi
callq 0x9a840
movq %rax, %rdi
callq 0x98560
movq -0x1a0(%rbp), %rdi
movq %rax, %rsi
callq 0xa4060
jmp 0xcbf09
movq -0x1a0(%rbp), %rsi
leaq -0x150(%rbp), %rdi
callq 0xa2850
jmp 0xcbf1e
movq -0x180(%rbp), %rdi
addq $0x38, %rdi
leaq -0x150(%rbp), %rsi
callq 0x9f5c0
jmp 0xcbf37
movq -0x10(%rbp), %rax
cmpl $0x0, 0x8(%rax)
je 0xcbf4f
movq -0x10(%rbp), %rax
cmpl $0x3, 0x8(%rax)
jne 0xcc040
movq -0x180(%rbp), %rax
addq $0x50, %rax
movq %rax, -0x1a8(%rbp)
leaq -0x150(%rbp), %rdi
callq 0x98080
movq %rax, %rsi
leaq -0x168(%rbp), %rdi
callq 0x9e010
jmp 0xcbf7e
leaq -0x168(%rbp), %rdi
callq 0x9d390
movq %rax, %rdi
callq 0x9d720
movl %eax, -0x1ac(%rbp)
jmp 0xcbf9a
movq -0x1a8(%rbp), %rdi
movl -0x1ac(%rbp), %eax
movl %eax, -0x154(%rbp)
leaq -0x154(%rbp), %rsi
callq 0x9bbb0
movq %rax, -0x1b8(%rbp)
jmp 0xcbfc2
movq -0x1b8(%rbp), %rdi
leaq -0x150(%rbp), %rsi
callq 0x9ec30
leaq -0x168(%rbp), %rdi
callq 0xa2ae0
jmp 0xcc040
movq -0x1a0(%rbp), %rdi
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x88(%rbp)
movl %eax, -0x8c(%rbp)
callq 0x9d660
jmp 0xcc0ea
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x88(%rbp)
movl %eax, -0x8c(%rbp)
jmp 0xcc0c3
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x88(%rbp)
movl %eax, -0x8c(%rbp)
leaq -0x168(%rbp), %rdi
callq 0xa2ae0
jmp 0xcc0c3
movq -0x10(%rbp), %rax
cmpl $0x2, 0x8(%rax)
jne 0xcc09d
movq -0x180(%rbp), %rdi
movq %rdi, %rax
addq $0x50, %rax
movq %rax, -0x1c8(%rbp)
addq $0x38, %rdi
callq 0x9dad0
movq -0x1c8(%rbp), %rdi
movl %eax, -0x16c(%rbp)
leaq -0x16c(%rbp), %rsi
callq 0x9bbb0
movq %rax, -0x1c0(%rbp)
jmp 0xcc08a
movq -0x1c0(%rbp), %rdi
leaq -0x150(%rbp), %rsi
callq 0x9ec30
leaq -0x150(%rbp), %rdi
callq 0x997e0
leaq -0x138(%rbp), %rdi
xorl %esi, %esi
callq 0xa4e50
movq %rax, -0x178(%rbp)
jmp 0xcbea1
leaq -0x150(%rbp), %rdi
callq 0x997e0
jmp 0xcc0ea
leaq -0x48(%rbp), %rdi
callq 0xa4380
movq -0x180(%rbp), %rax
addq $0x1d0, %rsp            # imm = 0x1D0
popq %rbp
retq
leaq -0x48(%rbp), %rdi
callq 0xa4380
movq -0x88(%rbp), %rdi
callq 0xa3520
nop