Initial commit
This commit is contained in:
commit
b7d90b9afe
16245 files changed
+3396666
No files matched your search
+57
@@ -0,0 +1,57 @@
|
||||
/**
|
||||
* TrainingArea object
|
||||
* $Id$
|
||||
* $HeadURL$
|
||||
* $Author$
|
||||
* Created by Hanna E. Rathje, SLSE, 2016-03-04
|
||||
*/
|
||||
#pragma once
|
||||
|
||||
#include <QObject>
|
||||
#include "dds_handler.h"
|
||||
#include "logger.h"
|
||||
#include <DDS/Core/function_reply_object.h>
|
||||
|
||||
// Generated
|
||||
#include <AssetManagement/asm_db.h>
|
||||
|
||||
namespace NGL
|
||||
{
|
||||
class INGLLogger;
|
||||
}
|
||||
|
||||
namespace AssetManagement
|
||||
{
|
||||
class MainHandler;
|
||||
|
||||
class ObjectTrainingArea
|
||||
{
|
||||
public:
|
||||
explicit ObjectTrainingArea(MainHandler *mainHandler);
|
||||
~ObjectTrainingArea();
|
||||
|
||||
Core::FunctionReplyObject createObject(const TrainingArea &data);
|
||||
Core::FunctionReplyObject updateObject(const TrainingArea &data);
|
||||
Core::FunctionReplyObject removeObject();
|
||||
|
||||
qint32 getId() const { return m_data.id(); }
|
||||
QString getName() const { return QString::fromStdString(m_data.name()); }
|
||||
const TrainingArea &getData() const { return m_data; }
|
||||
|
||||
bool isValid() const;
|
||||
bool isUsed() const;
|
||||
Core::FunctionReplyObject setUsed(bool isUsed);
|
||||
|
||||
// convert methods
|
||||
static Database::AsmTrainingArea toDbData(const TrainingArea &ddsData); // dds -> db
|
||||
|
||||
protected:
|
||||
void onPublishData();
|
||||
|
||||
private:
|
||||
MainHandler *m_mainHandler;
|
||||
TrainingArea m_data;
|
||||
NGL::INGLLogger &m_logger;
|
||||
|
||||
};
|
||||
}
|
||||
Reference in new issue
Block a user