Lumiera  0.pre.03
»edit your freedom«
enginefacade.cpp
Go to the documentation of this file.
1 /*
2  EngineFacade - access point for communicating with the render engine
3 
4  Copyright (C) Lumiera.org
5  2008, Hermann Vosseler <Ichthyostega@web.de>
6 
7  This program is free software; you can redistribute it and/or
8  modify it under the terms of the GNU General Public License as
9  published by the Free Software Foundation; either version 2 of
10  the License, or (at your option) any later version.
11 
12  This program is distributed in the hope that it will be useful,
13  but WITHOUT ANY WARRANTY; without even the implied warranty of
14  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15  GNU General Public License for more details.
16 
17  You should have received a copy of the GNU General Public License
18  along with this program; if not, write to the Free Software
19  Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
20 
21 * *****************************************************/
22 
23 
36 #include "vault/enginefacade.hpp"
37 #include "lib/depend.hpp"
38 
39 #include <string>
40 
41 
42 namespace vault {
43 
44  using std::string;
45  using lumiera::Subsys;
46 
48  : public Subsys
49  {
50  operator string () const { return "Engine"; }
51 
52  bool
54  {
55  TODO ("determine, if renderengine should be started");
56  return false;
57  }
58 
59  bool
60  start (lumiera::Option&, Subsys::SigTerm termination) override
61  {
62  UNIMPLEMENTED ("pull up renderengine and register shutdown hook");
63  return false;
64  }
65 
66  void
67  triggerShutdown () noexcept override
68  {
69  UNIMPLEMENTED ("initiate halting the engine");
70  }
71 
72  bool
73  checkRunningState () noexcept override
74  {
75  //Lock guard{*this};
76  TODO ("implement detecting running state");
77  return false;
78  }
79  };
80 
81  namespace {
83  }
84 
85 
86 
87 
89  Subsys&
91  {
92  return theDescriptor();
93  }
94 
95 
96 
97 } // namespace vault
bool shouldStart(lumiera::Option &) override
query application option state to determine if this subsystem should be activated.
Dependencies and lifecycle of a partially independent Subsystem of the Application.
Definition: subsys.hpp:70
void triggerShutdown() noexcept override
initiate termination of this subsystem.
Global control interface for the render engine subsystem.
Frontend for handling the Lumiera application commandline arguments.
Definition: option.hpp:77
Access point to singletons and other kinds of dependencies designated by type.
Definition: depend.hpp:289
static lumiera::Subsys & getDescriptor()
provide a descriptor for lumiera::AppState, wired accordingly to allow main to pull up and shut down ...
bool start(lumiera::Option &, Subsys::SigTerm termination) override
attempt to bring up this subsystem up.
Singleton services and Dependency Injection.
bool checkRunningState() noexcept override
whether this subsystem is actually operational.
Vault-Layer implementation namespace root.