WimaDataContainer.cc 1.12 KB
Newer Older
1 2 3
#include "WimaDataContainer.h"

WimaDataContainer::WimaDataContainer(QObject *parent)
4
    :   QObject     (parent)
5
    ,   _planData   (this /* parent */)
6 7 8
{

}
9

10 11 12 13 14 15 16 17
/*!
 * \fn void WimaDataContainer::push(const WimaPlanData &planData)
 *
 * Updates the \c WimaPlanData members content with \a planData.
 * Emits the planDataChanged() signal.
 *
 * \sa WimaPlanData
 */
18
void WimaDataContainer::push(const WimaPlanData &planData)
19
{
20
    _planData = planData;
21 22

    emit newDataAvailable();
23 24
}

25 26 27 28 29 30 31
/*!
 * \fn const WimaPlanData &WimaDataContainer::pull() const
 *
 * Returns a constant referenc to the \c WimaPlanData member.
 *
 * \sa WimaPlanData
 */
32
const WimaPlanData &WimaDataContainer::pull() const
33
{
34
    return  _planData;
35 36
}

37 38 39 40 41 42 43 44 45 46 47 48
/*!
 * \class WimaDataContainer
 * \brief Data container designed for data exchange between \c WimaPlaner and \c WimaController.
 * Data container designed for data exchange between \c WimaPlaner and \c WimaController.
 * It is meant that only one instance of this class exists. Both \c WimaPlaner and \c WimaController
 * have a reference to this instance and can modify its data.
 *
 * \sa WimaController, WimaPlaner
 */



49