#include "hello.h"
#include <QDebug>

Hello::Hello() : QObject()
{
}

Hello::~Hello()
{
}

void Hello::setText(const QString &text)
{
    // もしtextを使用しないのなら「Q_UNUSED(text)」をコードの先頭に記述する
    _text = text;
    // QMLへtext変更のシグナルを送信する
    emit textChanged();
}

QString Hello::getText()
{
    return _text;
}