score
Home
Classes
Namespaces
Files
UpdateDeviceSettings.hpp
1
#pragma once
2
#include <Device/Protocol/DeviceSettings.hpp>
3
4
#include <Explorer/Commands/DeviceExplorerCommandFactory.hpp>
5
6
#include <score/command/Command.hpp>
7
#include <score/model/path/Path.hpp>
8
9
#include <QString>
10
11
struct
DataStreamInput
;
12
struct
DataStreamOutput
;
13
14
namespace
Explorer
15
{
16
class
DeviceDocumentPlugin;
17
namespace
Command
18
{
19
class
UpdateDeviceSettings
final :
public
score::Command
20
{
21
SCORE_COMMAND_DECL(
22
DeviceExplorerCommandFactoryName(),
UpdateDeviceSettings
,
"Update a device"
)
23
public
:
24
UpdateDeviceSettings
(
25
const
DeviceDocumentPlugin& devplug,
const
QString& name,
26
const
Device::DeviceSettings
& parameters);
27
28
void
undo(
const
score::DocumentContext
& ctx)
const override
;
29
void
redo(
const
score::DocumentContext
& ctx)
const override
;
30
31
protected
:
32
void
serializeImpl(
DataStreamInput
&)
const override
;
33
void
deserializeImpl(
DataStreamOutput
&)
override
;
34
35
private
:
36
Device::DeviceSettings
m_oldParameters;
37
Device::DeviceSettings
m_newParameters;
38
};
39
}
40
}
Explorer::Command::UpdateDeviceSettings
Definition:
UpdateDeviceSettings.hpp:20
score::Command
The Command class.
Definition:
Command.hpp:34
DataStreamInput
Definition:
DataStreamHelpers.hpp:99
DataStreamOutput
Definition:
DataStreamHelpers.hpp:103
Device::DeviceSettings
Definition:
DeviceSettings.hpp:20
score::DocumentContext
Definition:
DocumentContext.hpp:18