MoveEventFactoryInterface.hpp
1 #pragma once
2 
3 #include <Process/ExpandMode.hpp>
4 #include <Process/TimeValue.hpp>
5 
6 #include <score/model/Identifier.hpp>
7 #include <score/plugins/Interface.hpp>
8 #include <score/plugins/StringFactoryKey.hpp>
9 
10 #include <score_plugin_scenario_export.h>
11 
12 #include <memory>
13 
14 namespace score
15 {
16 struct ApplicationContext;
17 }
18 template <typename Object>
19 class Path;
20 namespace Scenario
21 {
22 class ProcessModel;
23 class EventModel;
24 class ProcessModel;
25 namespace Command
26 {
27 class SerializableMoveEvent;
28 
29 class SCORE_PLUGIN_SCENARIO_EXPORT MoveEventFactoryInterface
30  : public score::InterfaceBase
31 {
32  SCORE_INTERFACE(MoveEventFactoryInterface, "69dc1f79-5cb9-4a36-b382-8c099f7abf57")
33 
34 public:
35  enum Strategy
36  {
37  CREATION,
38  MOVE
39  };
40  virtual std::unique_ptr<SerializableMoveEvent> make(
41  const Scenario::ProcessModel&, Id<EventModel> eventId, TimeVal newDate,
42  ExpandMode mode, LockMode lm)
43  = 0;
44 
45  virtual std::unique_ptr<SerializableMoveEvent> make(LockMode) = 0;
46  virtual ~MoveEventFactoryInterface();
47 
58  virtual int
59  priority(const score::ApplicationContext& ctx, Strategy strategy) const = 0;
60 };
61 }
62 }
The Path class is a typesafe wrapper around ObjectPath.
Definition: Path.hpp:52
Definition: MoveEventFactoryInterface.hpp:31
virtual int priority(const score::ApplicationContext &ctx, Strategy strategy) const =0
priority the highest priority will be default move behavior for the indicated strategy Basically,...
The core hierarchical and temporal process of score.
Definition: ScenarioModel.hpp:37
The id_base_t class.
Definition: Identifier.hpp:57
Base class for plug-in interfaces.
Definition: Interface.hpp:52
Main plug-in of score.
Definition: score-plugin-dataflow/Dataflow/PortItem.hpp:14
Base toolkit upon which the software is built.
Definition: Application.cpp:90
Definition: TimeValue.hpp:21
Used to access all the application-wide state and structures.
Definition: ApplicationContext.hpp:24