Wire Sysio
Wire Sysion 1.0.0
Loading...
Searching...
No Matches
template_plugin.cpp
Go to the documentation of this file.
1
#include <
sysio/template_plugin/template_plugin.hpp
>
2
3
namespace
sysio
{
4
static
appbase::abstract_plugin
& _template_plugin =
app
().
register_plugin
<template_plugin>();
5
6
class
template_plugin_impl
{
7
public
:
8
};
9
10
template_plugin::template_plugin
():my(new
template_plugin_impl
()){}
11
template_plugin::~template_plugin
(){}
12
13
void
template_plugin::set_program_options
(options_description&, options_description& cfg) {
14
cfg.add_options()
15
(
"option-name"
, bpo::value<string>()->default_value(
"default value"
),
16
"Option Description"
)
17
;
18
}
19
20
void
template_plugin::plugin_initialize
(
const
variables_map& options) {
21
try
{
22
if
( options.count(
"option-name"
)) {
23
// Handle the option
24
}
25
}
26
FC_LOG_AND_RETHROW
()
27
}
28
29
void
template_plugin::plugin_startup
() {
30
// Make the magic happen
31
}
32
33
void
template_plugin::plugin_shutdown
() {
34
// OK, that's enough magic
35
}
36
37
}
appbase::abstract_plugin
Definition
plugin.hpp:28
appbase::application::register_plugin
auto & register_plugin()
Definition
application.hpp:136
sysio::template_plugin_impl
Definition
template_plugin.cpp:6
sysio::template_plugin::plugin_shutdown
void plugin_shutdown()
Definition
template_plugin.cpp:33
sysio::template_plugin::~template_plugin
virtual ~template_plugin()
Definition
template_plugin.cpp:11
sysio::template_plugin::set_program_options
virtual void set_program_options(options_description &, options_description &cfg) override
Definition
template_plugin.cpp:13
sysio::template_plugin::template_plugin
template_plugin()
Definition
template_plugin.cpp:10
sysio::template_plugin::plugin_startup
void plugin_startup()
Definition
template_plugin.cpp:29
sysio::template_plugin::plugin_initialize
void plugin_initialize(const variables_map &options)
Definition
template_plugin.cpp:20
FC_LOG_AND_RETHROW
#define FC_LOG_AND_RETHROW()
Definition
exception.hpp:411
appbase::app
application & app()
Definition
application.cpp:210
sysio
Definition
abi_serializer.cpp:8
template_plugin.hpp
plugins
template_plugin
template_plugin.cpp
Generated by
1.12.0