2 #include <Scenario/Commands/ScenarioCommandFactory.hpp>
4 #include <score/command/Command.hpp>
5 #include <score/model/path/Path.hpp>
6 #include <score/model/path/PathSerialization.hpp>
19 return CommandFactoryName();
27 const CommandKey& key()
const noexcept
override {
return static_key(); }
28 QString description()
const override
37 , m_newLabel{std::move(newLabel)}
39 m_oldLabel = obj.metadata().getLabel();
44 auto& obj = m_path.find(ctx);
45 obj.metadata().setLabel(m_oldLabel);
50 auto& obj = m_path.find(ctx);
51 obj.metadata().setLabel(m_newLabel);
57 s << m_path << m_oldLabel << m_newLabel;
62 s >> m_path >> m_oldLabel >> m_newLabel;
73 SCORE_COMMAND_DECL_T(ChangeElementLabel<IntervalModel>)
74 SCORE_COMMAND_DECL_T(ChangeElementLabel<EventModel>)
75 SCORE_COMMAND_DECL_T(ChangeElementLabel<TimeSyncModel>)
76 SCORE_COMMAND_DECL_T(ChangeElementLabel<StateModel>)
77 SCORE_COMMAND_DECL_T(ChangeElementLabel<Process::ProcessModel>)
Definition: ChangeElementLabel.hpp:14
The Command class.
Definition: Command.hpp:34
Main plug-in of score.
Definition: score-plugin-dataflow/Dataflow/PortItem.hpp:14
Definition: DataStreamHelpers.hpp:103
Definition: DocumentContext.hpp:18