1 /* This Source Code Form is subject to the terms of the Mozilla Public
\r
2 * License, v. 2.0. If a copy of the MPL was not distributed with this
\r
3 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
\r
4 #include "DBusRuntime.h"
\r
6 namespace CommonAPI {
\r
9 const MiddlewareInfo DBusRuntime::middlewareInfo_("DBus", &DBusRuntime::getInstance);
\r
11 __attribute__((constructor)) void registerDBusMiddleware(void) {
\r
12 Runtime::registerRuntimeLoader("DBus", &DBusRuntime::getInstance);
\r
15 std::shared_ptr<Runtime> DBusRuntime::getInstance() {
\r
16 static std::shared_ptr<Runtime> singleton_;
\r
18 singleton_ = std::make_shared<DBusRuntime>();
\r
23 std::shared_ptr<Factory> DBusRuntime::createFactory() {
\r
24 auto factory = std::make_shared<DBusFactory>(this->shared_from_this(), &middlewareInfo_);
\r
29 } // namespace CommonAPI
\r