60 lines
1.3 KiB
C++
Executable File
60 lines
1.3 KiB
C++
Executable File
/**
|
|
* @RDE_HEADER@
|
|
* GUI Plugin for SymbolEditor
|
|
* $Id$
|
|
* $HeadURL$
|
|
* $Author$
|
|
*
|
|
* Created by Chrsitian Roeskens, SLSE, 2017-04-12
|
|
*/
|
|
|
|
#pragma once
|
|
|
|
#include <FileManagement/flm_ftc.h>
|
|
#include <FileManagement/flm_ftc_types.h>
|
|
|
|
#include <QtCore/QObject>
|
|
|
|
|
|
namespace LtsUtils
|
|
{
|
|
class RequestHelper;
|
|
}
|
|
|
|
namespace AdvancedSymbology
|
|
{
|
|
class FileManagementReplyHandler final
|
|
: public QObject
|
|
, public FileManagement::Interface::Ftc::FileContentModifyReplyHandler
|
|
, public FileManagement::Interface::Ftc::GetFileContentDataReplyHandler
|
|
{
|
|
Q_OBJECT
|
|
|
|
public:
|
|
|
|
explicit FileManagementReplyHandler(LtsUtils::RequestHelper *rh, QObject *parent);
|
|
|
|
const std::vector<uint8_t> &getContent() const { return m_content; }
|
|
int32_t getId() const { return m_id; }
|
|
|
|
signals:
|
|
void signalFileContentModifyReplyReceived();
|
|
|
|
protected:
|
|
|
|
// file content
|
|
void onFileContentModifyReply(const Core::FunctionReplyObject &replyObject) override final { requestReply(replyObject); }
|
|
void onGetFileContentDataReply(const FileManagement::GetFileContentDataReply &replyObject) override final;
|
|
|
|
private:
|
|
|
|
void requestReply(const Core::FunctionReplyObject &replyObject);
|
|
|
|
LtsUtils::RequestHelper *m_requestHelper;
|
|
std::vector<uint8_t> m_content;
|
|
int32_t m_id;
|
|
|
|
}; // FileManagementReplyHandler
|
|
|
|
} // namespace PlanEditorPlugin
|