#include "WimaDataContainer.h"

WimaDataContainer::WimaDataContainer(QObject *parent)
    :   QObject     (parent)
    ,   _joinedArea (nullptr)
    ,   _opArea     (nullptr)
    ,   _serArea    (nullptr)
    ,   _corridor   (nullptr)
{

}

void WimaDataContainer::setJoinedArea(const WimaArea *joinedArea)
{
    if (_joinedArea != joinedArea)  {
        _joinedArea = joinedArea;

        emit joinedAreaChanged(_joinedArea);
    }
}

void WimaDataContainer::setOpArea(const WimaGOperationArea *opArea)
{
    if (_opArea != opArea)  {
        _opArea = opArea;

        emit opAreaChanged(_opArea);
    }
}

void WimaDataContainer::setSerArea(const WimaServiceArea *serArea)
{
    if (_serArea != serArea)  {
        _serArea = serArea;

        emit serAreaChanged(_serArea);
    }
}

void WimaDataContainer::setCorridor(const WimaVCorridor *corridor)
{
    if (_corridor != corridor)  {
        _corridor = corridor;

        emit corridorChanged(_corridor);
    }
}
