Beispiel #1
0
CTree<type>::CTree(const CTree<type>& object)
{
    if(object.IsEmpty())
    {
        m_root=nullptr;
        return;
    }

    copyTree(&m_root,object.m_root);

    return;
}
Beispiel #2
0
const CTree<type>& CTree<type>::operator=(const CTree<type>& object)
{
    if(this==&object)
        return *this;

    destroy(&m_root);

    if(object.IsEmpty())
    {
        m_root=nullptr;
        return *this;
    }

    copyTree(&m_root,object.m_root);

    return *this;
}