MIRA
|
#include <fw/FrameworkWithGui.h>
Classes | |
class | Application |
Implements our own Application derived from QApplication in order to overwrite the notify method. More... | |
Public Types | |
typedef ProtecteeMixin< MetaTypeDatabase > | ProtecteeDatabase |
typedef Base::Type | Type |
Public Member Functions | |
FrameworkWithGui (int &argc, char **argv, bool startImmediately=false) | |
Constructor that creates own FrameworkWithGui::Application. More... | |
FrameworkWithGui (int &argc, char **argv, QApplication *app, bool startImmediately=false) | |
Constructor that takes previously created QApplication. More... | |
~FrameworkWithGui () | |
virtual int | exec () |
Executes the framework and executes the underlying QApplication until the application is terminated, e.g. More... | |
virtual void | requestTermination (int exitcode=0) |
Requests the termination of the framework and hence the whole application. More... | |
template<typename Reflector > | |
void | reflect (Reflector &r) |
Reflect method for serialization. More... | |
boost::shared_ptr< PropertyNode > | getProperties () |
void | load (XMLDom &xml) |
Loads the specified XML configuration and applies all registered Loaders on it. More... | |
void | load (const std::string &configFile) |
Opens the specified XML configuration file and applies all registered Loaders on it. More... | |
void | load () |
Loads configuration files given on command line if any by calling above load(const std::string& configFile) function. More... | |
void | start () |
Starts the framework and it's remote component (if one was configured or created) and returns immediately. More... | |
bool | isStarted () const |
Return true if framework is started. More... | |
Duration | getUptime () const |
Return duration since started. More... | |
virtual bool | isTerminationRequested () const |
Returns whether the termination of the framework is reqested. More... | |
int | getTerminationExitCode () const |
Returns the exit code as specified by requestTermination(), or 0 if requestTermination() was not called. More... | |
int | run () |
Calls the above load() and start() methods according to the command line parameters that were passed in the constructor and finally calls exec(). More... | |
std::string | getID () const |
Returns the ID of this framework. More... | |
std::string | getGlobalID () const |
Return the fully qualified global id of this framework (includes namespace) More... | |
XMLVariablesMap & | getVariables () |
Returns the list of variables that are registered via command line or config file. More... | |
XMLDomPreprocessor & | getXMLDomPreprocessor () |
ScopedAccess< ProtecteeDatabase > | getMetaDatabase () |
Return the meta database that contains all known meta information in this framework. More... | |
bool | isInExec () const |
Obtain access to framework components | |
NameRegistry & | getNameRegistry () |
Returns the reference to the name registry. More... | |
AuthorityManager & | getAuthorityManager () |
Returns the reference to the manager singleton for registered authorities. More... | |
ChannelManager & | getChannelManager () |
Returns the reference to the manager singleton for channels. More... | |
boost::shared_ptr< FrameworkTransformer > | getTransformer () |
Returns the pointer to the transform framework. More... | |
ConfigurationLoader & | getConfigurationLoader () |
Returns the reference to the configuration file loader. More... | |
boost::shared_ptr< UnitManager > | getUnitManager () |
Returns the reference to the unit manager. More... | |
RPCManager & | getRPCManager () |
Returns the reference to the manager singleton for registered RPC services. More... | |
boost::shared_ptr< ErrorService > | getErrorService () |
Returns the pointer to the persistent error service. More... | |
boost::shared_ptr< RemoteModule > | getRemoteModule () |
Returns the pointer to the remote module. More... | |
Static Public Member Functions | |
static Type & | instance () |
Returns a reference to the singleton instance. More... | |
static bool | isDestroyed () |
Returns true, if the singleton was already destroyed. More... | |
Protected Member Functions | |
void | initialize () |
void | finalize () |
void | ctrlCHandler (const IntSignal &sig) |
Static Protected Member Functions | |
static void | errorHandler (const IntSignal &sig) |
static bool | enterLeaveErrorHandler (bool enter) |
Protected Attributes | |
bool | mTerminationRequested |
int | mTerminationExitCode |
bool | mIsStarted |
bool | mInExec |
bool | mRemoteDisabled |
boost::shared_ptr< Private::FrameworkAuthority > | mAuthority |
RootPropertyNode | mPropertiesRoot |
boost::shared_ptr< PropertyNode > | mProperties |
NameRegistry | mNames |
boost::shared_ptr< RemoteModule > | mRemoteModule |
RPCManager | mRPCManager |
ChannelManager | mChannelManager |
AuthorityManager | mAuthorityManager |
boost::shared_ptr< FrameworkTransformer > | mTransformer |
boost::shared_ptr< UnitManager > | mUnitManager |
ConfigurationLoader | mConfigurationLoader |
boost::shared_ptr< ErrorService > | mErrorServiceModule |
std::string | mName |
XMLDomPreprocessor | mXMLPreprocessor |
XMLDom | mConfigDom |
ProtecteeDatabase | mMetaDatabase |
Time | mStartTime |
|
inherited |
|
inherited |
|
inline |
Constructor that creates own FrameworkWithGui::Application.
|
inline |
Constructor that takes previously created QApplication.
The caller is responsible for destroying the application at the end.
|
inline |
|
inlinevirtual |
Executes the framework and executes the underlying QApplication until the application is terminated, e.g.
by closing it or by pressing Ctrl+C.
Reimplemented from Framework.
|
inlinevirtual |
Requests the termination of the framework and hence the whole application.
Is called e.g. when user presses Ctrl+C. You can optionally specify an exit code that will be returned as exit code by exec(). Furthermore, this code is returned by the mira executables (mira, miragui, miracenter, etc.).
Reimplemented from Framework.
|
inlineinherited |
Reflect method for serialization.
|
inlineinherited |
|
inherited |
Loads the specified XML configuration and applies all registered Loaders on it.
This will load libraries, instantiate and configure units, etc. This method will do nothing if the xml document is empty.
|
inherited |
Opens the specified XML configuration file and applies all registered Loaders on it.
This will load libraries, instantiate and configure units, etc. This method will do nothing if configFile is empty.
|
inherited |
Loads configuration files given on command line if any by calling above load(const std::string& configFile) function.
|
inherited |
Starts the framework and it's remote component (if one was configured or created) and returns immediately.
|
inlineinherited |
Return true if framework is started.
|
inlineinherited |
Return duration since started.
|
virtualinherited |
Returns whether the termination of the framework is reqested.
|
inherited |
Returns the exit code as specified by requestTermination(), or 0 if requestTermination() was not called.
|
inherited |
Calls the above load() and start() methods according to the command line parameters that were passed in the constructor and finally calls exec().
Hence, this method will launch a fully operating framework and blocks until the framework is terminated, e.g. by pressing Ctrl+C. Returns the exit code as specified by requestTermination(), or 0 if no error or exception has occurred, otherwise -1.
|
inlineinherited |
Returns the reference to the name registry.
|
inlineinherited |
Returns the reference to the manager singleton for registered authorities.
|
inlineinherited |
Returns the reference to the manager singleton for channels.
|
inlineinherited |
Returns the pointer to the transform framework.
|
inlineinherited |
Returns the reference to the configuration file loader.
|
inlineinherited |
Returns the reference to the unit manager.
|
inlineinherited |
Returns the reference to the manager singleton for registered RPC services.
|
inlineinherited |
Returns the pointer to the persistent error service.
|
inlineinherited |
Returns the pointer to the remote module.
|
inlineinherited |
Returns the ID of this framework.
The ID can be specified via command line. If no ID is specified an UUID based one will be generated.
|
inlineinherited |
Return the fully qualified global id of this framework (includes namespace)
|
inlineinherited |
Returns the list of variables that are registered via command line or config file.
|
inlineinherited |
|
inlineinherited |
Return the meta database that contains all known meta information in this framework.
|
inlineinherited |
|
protectedinherited |
|
protectedinherited |
|
protectedinherited |
|
staticprotectedinherited |
|
staticprotectedinherited |
|
inlinestaticinherited |
Returns a reference to the singleton instance.
XSingleton | If the singleton was already destroyed (dead reference) or not yet created (when using ExplicitInstantiation). |
|
inlinestaticinherited |
Returns true, if the singleton was already destroyed.
Trying to access it will result in an exception.
|
protectedinherited |
|
protectedinherited |
|
protectedinherited |
|
protectedinherited |
|
protectedinherited |
|
protectedinherited |
|
protectedinherited |
|
protectedinherited |
|
protectedinherited |
|
protectedinherited |
|
protectedinherited |
|
protectedinherited |
|
protectedinherited |
|
protectedinherited |
|
protectedinherited |
|
protectedinherited |
|
protectedinherited |
|
protectedinherited |
|
protectedinherited |
|
protectedinherited |
|
protectedinherited |
|
protectedinherited |