#include "parasetitem.h"

ParaSetItem::ParaSetItem(QObject *parent) : QObject(parent)
{
    clean();
}

ParaSetItem::~ParaSetItem()
{
    clean();
}

ParaSetItem::ParaSetItem(const ParaSetItem & item) : QObject()
{
    copyData(item);
}

ParaSetItem & ParaSetItem::operator= (const ParaSetItem & item)
{
    copyData(item);
    return *this;
}

void ParaSetItem::clean()
{
    m_macType = 0;
    m_showPriority = 0;
    m_name.clear();
    m_topImageName.clear();
    m_paraType = 1;
}

void ParaSetItem::copyData(const ParaSetItem &item)
{
    if (this != &item)
    {
        this->m_macType = item.m_macType;
        this->m_showPriority = item.m_showPriority;
        this->m_name = item.m_name;
        this->m_topImageName = item.m_topImageName;
        this->m_paraType = item.m_paraType;
    }
}

