Lumiera  0.pre.03
»edit your freedom«
session-command-service.hpp
Go to the documentation of this file.
1 /*
2  SESSION-COMMAND-SERVICE.hpp - public service to invoke commands on the session
3 
4  Copyright (C)
5  2016, Hermann Vosseler <Ichthyostega@web.de>
6 
7   **Lumiera** is free software; you can redistribute it and/or modify it
8   under the terms of the GNU General Public License as published by the
9   Free Software Foundation; either version 2 of the License, or (at your
10   option) any later version. See the file COPYING for further details.
11 
12 */
13 
32 #ifndef STEAM_CONTROL_SESSION_COMMAND_SERVICE_H
33 #define STEAM_CONTROL_SESSION_COMMAND_SERVICE_H
34 
35 
40 #include "lib/diff/gen-node.hpp"
41 #include "lib/nocopy.hpp"
42 #include "lib/symbol.hpp"
43 
44 
45 
46 
47 namespace steam {
48 namespace control {
49 
50  using lib::diff::Rec;
51 
52 
53 
54  /***********************************************************/
71  : public SessionCommand
73  {
74  CommandDispatch& dispatcher_;
75  CommandInstanceManager instanceManager_;
76 
77 
78  /* === Interface Lifecycle === */
79 
80  using ServiceInstanceHandle = lumiera::InstanceHandle< LUMIERA_INTERFACE_INAME(lumieraorg_SessionCommand, 0)
82  >;
83  ServiceInstanceHandle serviceInstance_;
84 
85  public:
86  SessionCommandService (CommandDispatch& dispatcherLoopInterface);
87 
88 
89  /* === Implementation of the Facade Interface === */
90 
91  Symbol cycle (Symbol cmdID, string const& invocationID) override;
92  void trigger (Symbol cmdID, Rec const& args) override;
93  void bindArg (Symbol cmdID, Rec const& args) override;
94  void invoke (Symbol cmdID) override;
95  };
96 
97 
98 
99 }} // namespace steam::control
100 #endif /*STEAM_CONTROL_SESSION_COMMAND_SERVICE_H*/
Global access point to invoke commands and cause edit operations within the Session.
Symbol cycle(Symbol cmdID, string const &invocationID) override
start next command cycle and "open" a new anonymous command instance
Interface to abstract the SteamDispatcher&#39;s ability to handle command messages.
Any copy and copy construction prohibited.
Definition: nocopy.hpp:37
Maintain a current command instance for parametrisation.
Service to support forming and invocation of command instances for use by the UI. ...
Actual implementation of the SessionCommand service within the Lumiera Session subsystem.
Steam-Layer implementation namespace root.
Token or Atom with distinct identity.
Definition: symbol.hpp:117
Mix-Ins to allow or prohibit various degrees of copying and cloning.
Marker types to indicate a literal string and a Symbol.
Interface of a service to perform Commands on the session.
Generic building block for tree shaped (meta)data structures.
SessionCommandService(CommandDispatch &dispatcherLoopInterface)
#define LUMIERA_INTERFACE_INAME(name, version)
Construct a type identifier for an interface.
Definition: interface.h:93
A handle template for automatically dealing with interface and plugin registration and deregistration...
object-like record of data.
Definition: record.hpp:141
Major public Interface to the Session subsystem of Lumiera GUI.
void bindArg(Symbol cmdID, Rec const &args) override
void trigger(Symbol cmdID, Rec const &args) override