Loading...
Searching...
No Matches
BaseScenario.hpp
1#pragma once
2#include <Scenario/Document/BaseScenario/BaseScenarioContainer.hpp>
3
4#include <score/model/IdentifiedObject.hpp>
5#include <score/selection/Selection.hpp>
6#include <score/serialization/VisitorInterface.hpp>
7#include <score/tools/Metadata.hpp>
8
9#include <QVector>
10
11#include <verdigris>
12
13class DataStream;
14class JSONObject;
15class QObject;
16#include <score/model/Identifier.hpp>
17namespace Scenario
18{
19class IntervalModel;
20class TimeSyncModel;
21class BaseScenario final
22 : public IdentifiedObject<BaseScenario>
24{
25 W_OBJECT(BaseScenario)
26 SCORE_SERIALIZE_FRIENDS
27
28public:
30 const Id<BaseScenario>& id, const score::DocumentContext& ctx,
31 QObject* parentObject);
32
33 template <IsDeserializer DeserializerVisitor>
35 DeserializerVisitor&& vis, const score::DocumentContext& ctx, QObject* parent)
36 : IdentifiedObject{vis, parent}
38 {
39 vis.writeTo(*this);
40 }
41
42 ~BaseScenario() override;
43
44 Selection selectedChildren() const;
45 bool focused() const;
46
47 using BaseScenarioContainer::event;
48 using QObject::event;
49};
50
51const QVector<Id<IntervalModel>>
52intervalsBeforeTimeSync(const BaseScenario&, const Id<TimeSyncModel>& timeSyncId);
53}
54
55DEFAULT_MODEL_METADATA(Scenario::BaseScenario, "Base Scenario")
56UNDO_NAME_METADATA(EMPTY_MACRO, Scenario::BaseScenario, "Base Scenario")
Definition VisitorInterface.hpp:53
The IdentifiedObject class.
Definition IdentifiedObject.hpp:19
Definition VisitorInterface.hpp:61
Definition BaseScenarioContainer.hpp:26
Definition BaseScenario.hpp:24
Definition Selection.hpp:12
The id_base_t class.
Definition Identifier.hpp:57
Main plug-in of score.
Definition score-plugin-dataflow/Dataflow/PortItem.hpp:13
Definition BaseScenarioContainer.hpp:30
Definition DocumentContext.hpp:18