-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMainApplication.h
More file actions
43 lines (28 loc) · 1.08 KB
/
MainApplication.h
File metadata and controls
43 lines (28 loc) · 1.08 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
//
// Created by fquinn on 22/07/2018.
//
#ifndef OPENMAMA_SNAPSHOT_APPLICATIONGOVERNOR_H
#define OPENMAMA_SNAPSHOT_APPLICATIONGOVERNOR_H
#define MAIN_APPLICATION_NAME "MainApplication"
#include <Poco/Util/ServerApplication.h>
/***
* Application governors are responsible for encapsulating multiple application runners and routing things like
* admin commands and external signals.
*/
namespace cascadium {
class MainApplication: public Poco::Util::ServerApplication {
public:
const char *name() const override;
MainApplication();
protected:
void initialize(Application &self) override;
void defineOptions(Poco::Util::OptionSet &options) override;
void uninitialize() override;
void reinitialize(Application &self) override;
void handleOption(const std::string &name, const std::string &value) override;
int main(const std::vector<std::string> &args) override;
static void signalHandler(int signum);
void displayUsage(int exitCode);
};
}
#endif //OPENMAMA_SNAPSHOT_APPLICATIONGOVERNOR_H