summaryrefslogtreecommitdiff
path: root/src/test/src-gen/dbus/v1_0/commonapi/tests/TestInterfaceDBusStubAdapter.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/test/src-gen/dbus/v1_0/commonapi/tests/TestInterfaceDBusStubAdapter.cpp')
-rw-r--r--src/test/src-gen/dbus/v1_0/commonapi/tests/TestInterfaceDBusStubAdapter.cpp436
1 files changed, 436 insertions, 0 deletions
diff --git a/src/test/src-gen/dbus/v1_0/commonapi/tests/TestInterfaceDBusStubAdapter.cpp b/src/test/src-gen/dbus/v1_0/commonapi/tests/TestInterfaceDBusStubAdapter.cpp
new file mode 100644
index 0000000..c237cd6
--- /dev/null
+++ b/src/test/src-gen/dbus/v1_0/commonapi/tests/TestInterfaceDBusStubAdapter.cpp
@@ -0,0 +1,436 @@
+/*
+* This file was generated by the CommonAPI Generators.
+* Used org.genivi.commonapi.core 3.1.2.v201506150834.
+* Used org.franca.core 0.9.1.201412191134.
+*
+* This Source Code Form is subject to the terms of the Mozilla Public License, v. 2.0.
+* If a copy of the MPL was not distributed with this file, You can obtain one at
+* http://mozilla.org/MPL/2.0/.
+*/
+#include <v1_0/commonapi/tests/TestInterface.hpp>
+#include <v1_0/commonapi/tests/TestInterfaceDBusStubAdapter.hpp>
+
+namespace v1_0 {
+namespace commonapi {
+namespace tests {
+
+std::shared_ptr<CommonAPI::DBus::DBusStubAdapter> createTestInterfaceDBusStubAdapter(
+ const CommonAPI::DBus::DBusAddress &_address,
+ const std::shared_ptr<CommonAPI::DBus::DBusProxyConnection> &_connection,
+ const std::shared_ptr<CommonAPI::StubBase> &_stub) {
+ return std::make_shared<TestInterfaceDBusStubAdapter>(_address, _connection, _stub);
+}
+
+INITIALIZER(registerTestInterfaceDBusStubAdapter) {
+ CommonAPI::DBus::Factory::get()->registerStubAdapterCreateMethod(
+ TestInterface::getInterface(), &createTestInterfaceDBusStubAdapter);
+}
+
+TestInterfaceDBusStubAdapterInternal::~TestInterfaceDBusStubAdapterInternal() {
+ deactivateManagedInstances();
+ TestInterfaceDBusStubAdapterHelper::deinit();
+}
+
+void TestInterfaceDBusStubAdapterInternal::deactivateManagedInstances() {
+
+}
+
+const char* TestInterfaceDBusStubAdapterInternal::getMethodsDBusIntrospectionXmlData() const {
+ static const std::string introspectionData =
+ "<method name=\"getInterfaceVersion\">\n"
+ "<arg name=\"value\" type=\"uu\" direction=\"out\" />"
+ "</method>\n"
+ "<method name=\"getTestPredefinedTypeAttributeAttribute\">\n"
+ "<arg name=\"value\" type=\"u\" direction=\"out\" />"
+ "</method>\n"
+ "<method name=\"setTestPredefinedTypeAttributeAttribute\">\n"
+ "<arg name=\"requestedValue\" type=\"u\" direction=\"in\" />\n"
+ "<arg name=\"setValue\" type=\"u\" direction=\"out\" />\n"
+ "</method>\n"
+ "<signal name=\"onTestPredefinedTypeAttributeAttributeChanged\">\n"
+ "<arg name=\"changedValue\" type=\"u\" />\n"
+ "</signal>\n"
+ "<method name=\"getTestDerivedStructAttributeAttribute\">\n"
+ "<arg name=\"value\" type=\"(sqi)\" direction=\"out\" />"
+ "</method>\n"
+ "<method name=\"setTestDerivedStructAttributeAttribute\">\n"
+ "<arg name=\"requestedValue\" type=\"(sqi)\" direction=\"in\" />\n"
+ "<arg name=\"setValue\" type=\"(sqi)\" direction=\"out\" />\n"
+ "</method>\n"
+ "<signal name=\"onTestDerivedStructAttributeAttributeChanged\">\n"
+ "<arg name=\"changedValue\" type=\"(sqi)\" />\n"
+ "</signal>\n"
+ "<method name=\"getTestDerivedArrayAttributeAttribute\">\n"
+ "<arg name=\"value\" type=\"at\" direction=\"out\" />"
+ "</method>\n"
+ "<method name=\"setTestDerivedArrayAttributeAttribute\">\n"
+ "<arg name=\"requestedValue\" type=\"at\" direction=\"in\" />\n"
+ "<arg name=\"setValue\" type=\"at\" direction=\"out\" />\n"
+ "</method>\n"
+ "<signal name=\"onTestDerivedArrayAttributeAttributeChanged\">\n"
+ "<arg name=\"changedValue\" type=\"at\" />\n"
+ "</signal>\n"
+ "<signal name=\"TestPredefinedTypeBroadcast\">\n"
+ "<arg name=\"uint32Value\" type=\"u\" />\n"
+ "<arg name=\"stringValue\" type=\"s\" />\n"
+ "</signal>\n"
+ "<signal name=\"TestSelectiveBroadcast\">\n"
+ "</signal>\n"
+ "<signal name=\"TestBroadcastWithOutArgs\">\n"
+ "<arg name=\"uint32Value\" type=\"u\" />\n"
+ "<arg name=\"stringValue\" type=\"s\" />\n"
+ "</signal>\n"
+ "<method name=\"testEmptyMethod\">\n"
+ "</method>\n"
+ "<method name=\"testVoidPredefinedTypeMethod\">\n"
+ "<arg name=\"_uint32Value\" type=\"u\" direction=\"in\" />\n"
+ "<arg name=\"_stringValue\" type=\"s\" direction=\"in\" />\n"
+ "</method>\n"
+ "<method name=\"testPredefinedTypeMethod\">\n"
+ "<arg name=\"_uint32InValue\" type=\"u\" direction=\"in\" />\n"
+ "<arg name=\"_stringInValue\" type=\"s\" direction=\"in\" />\n"
+ "<arg name=\"_uint32OutValue\" type=\"u\" direction=\"out\" />\n"
+ "<arg name=\"_stringOutValue\" type=\"s\" direction=\"out\" />\n"
+ "</method>\n"
+ "<method name=\"testVoidDerivedTypeMethod\">\n"
+ "<arg name=\"_testEnumExtended2Value\" type=\"i\" direction=\"in\" />\n"
+ "<arg name=\"_testMapValue\" type=\"a{ua(sq)}\" direction=\"in\" />\n"
+ "</method>\n"
+ "<method name=\"testDerivedTypeMethod\">\n"
+ "<arg name=\"_testEnumExtended2InValue\" type=\"i\" direction=\"in\" />\n"
+ "<arg name=\"_testMapInValue\" type=\"a{ua(sq)}\" direction=\"in\" />\n"
+ "<arg name=\"_testEnumExtended2OutValue\" type=\"i\" direction=\"out\" />\n"
+ "<arg name=\"_testMapOutValue\" type=\"a{ua(sq)}\" direction=\"out\" />\n"
+ "</method>\n"
+ "<method name=\"TestArrayOfPolymorphicStructMethod\">\n"
+ "<arg name=\"_inArray\" type=\"a(uv)\" direction=\"in\" />\n"
+ "</method>\n"
+ "<method name=\"TestMapOfPolymorphicStructMethod\">\n"
+ "<arg name=\"_inMap\" type=\"a{y(uv)}\" direction=\"in\" />\n"
+ "</method>\n"
+ "<method name=\"TestStructWithPolymorphicMemberMethod\">\n"
+ "<arg name=\"_inStruct\" type=\"(u(uv))\" direction=\"in\" />\n"
+ "</method>\n"
+ "<method name=\"TestStructWithEnumKeyMapMember\">\n"
+ "<arg name=\"_inStruct\" type=\"(a{is})\" direction=\"in\" />\n"
+ "</method>\n"
+
+ ;
+ return introspectionData.c_str();
+}
+
+CommonAPI::DBus::DBusGetAttributeStubDispatcher<
+ TestInterfaceStub,
+ CommonAPI::Version
+ > TestInterfaceDBusStubAdapterInternal::getTestInterfaceInterfaceVersionStubDispatcher(&TestInterfaceStub::getInterfaceVersion, "uu");
+
+CommonAPI::DBus::DBusGetAttributeStubDispatcher<
+ TestInterfaceStub,
+ uint32_t
+ > TestInterfaceDBusStubAdapterInternal::getTestPredefinedTypeAttributeAttributeStubDispatcher(&TestInterfaceStub::getTestPredefinedTypeAttributeAttribute, "u");
+CommonAPI::DBus::DBusSetObservableAttributeStubDispatcher<
+ TestInterfaceStub,
+ uint32_t
+ > TestInterfaceDBusStubAdapterInternal::setTestPredefinedTypeAttributeAttributeStubDispatcher(
+ &TestInterfaceStub::getTestPredefinedTypeAttributeAttribute,
+ &TestInterfaceStubRemoteEvent::onRemoteSetTestPredefinedTypeAttributeAttribute,
+ &TestInterfaceStubRemoteEvent::onRemoteTestPredefinedTypeAttributeAttributeChanged
+ ,&TestInterfaceStubAdapter::fireTestPredefinedTypeAttributeAttributeChanged
+ ,"u"
+ );
+CommonAPI::DBus::DBusGetAttributeStubDispatcher<
+ TestInterfaceStub,
+ ::commonapi::tests::DerivedTypeCollection::TestStructExtended
+ > TestInterfaceDBusStubAdapterInternal::getTestDerivedStructAttributeAttributeStubDispatcher(&TestInterfaceStub::getTestDerivedStructAttributeAttribute, "(sqi)");
+CommonAPI::DBus::DBusSetObservableAttributeStubDispatcher<
+ TestInterfaceStub,
+ ::commonapi::tests::DerivedTypeCollection::TestStructExtended
+ > TestInterfaceDBusStubAdapterInternal::setTestDerivedStructAttributeAttributeStubDispatcher(
+ &TestInterfaceStub::getTestDerivedStructAttributeAttribute,
+ &TestInterfaceStubRemoteEvent::onRemoteSetTestDerivedStructAttributeAttribute,
+ &TestInterfaceStubRemoteEvent::onRemoteTestDerivedStructAttributeAttributeChanged
+ ,&TestInterfaceStubAdapter::fireTestDerivedStructAttributeAttributeChanged
+ ,"(sqi)"
+ );
+CommonAPI::DBus::DBusGetAttributeStubDispatcher<
+ TestInterfaceStub,
+ ::commonapi::tests::DerivedTypeCollection::TestArrayUInt64
+ > TestInterfaceDBusStubAdapterInternal::getTestDerivedArrayAttributeAttributeStubDispatcher(&TestInterfaceStub::getTestDerivedArrayAttributeAttribute, "at");
+CommonAPI::DBus::DBusSetObservableAttributeStubDispatcher<
+ TestInterfaceStub,
+ ::commonapi::tests::DerivedTypeCollection::TestArrayUInt64
+ > TestInterfaceDBusStubAdapterInternal::setTestDerivedArrayAttributeAttributeStubDispatcher(
+ &TestInterfaceStub::getTestDerivedArrayAttributeAttribute,
+ &TestInterfaceStubRemoteEvent::onRemoteSetTestDerivedArrayAttributeAttribute,
+ &TestInterfaceStubRemoteEvent::onRemoteTestDerivedArrayAttributeAttributeChanged
+ ,&TestInterfaceStubAdapter::fireTestDerivedArrayAttributeAttributeChanged
+ ,"at"
+ );
+
+
+CommonAPI::DBus::DBusMethodWithReplyStubDispatcher<
+ TestInterfaceStub,
+ std::tuple<>,
+ std::tuple<>
+ > TestInterfaceDBusStubAdapterInternal::testEmptyMethodStubDispatcher(&TestInterfaceStub::testEmptyMethod, "", std::tuple<>());
+CommonAPI::DBus::DBusMethodWithReplyStubDispatcher<
+ TestInterfaceStub,
+ std::tuple<uint32_t, std::string>,
+ std::tuple<>
+ > TestInterfaceDBusStubAdapterInternal::testVoidPredefinedTypeMethodStubDispatcher(&TestInterfaceStub::testVoidPredefinedTypeMethod, "", std::tuple<uint32_t, std::string>());
+CommonAPI::DBus::DBusMethodWithReplyStubDispatcher<
+ TestInterfaceStub,
+ std::tuple<uint32_t, std::string>,
+ std::tuple<uint32_t, std::string>
+ > TestInterfaceDBusStubAdapterInternal::testPredefinedTypeMethodStubDispatcher(&TestInterfaceStub::testPredefinedTypeMethod, "us", std::tuple<uint32_t, std::string, uint32_t, std::string>());
+CommonAPI::DBus::DBusMethodWithReplyStubDispatcher<
+ TestInterfaceStub,
+ std::tuple<::commonapi::tests::DerivedTypeCollection::TestEnumExtended2, ::commonapi::tests::DerivedTypeCollection::TestMap>,
+ std::tuple<>
+ > TestInterfaceDBusStubAdapterInternal::testVoidDerivedTypeMethodStubDispatcher(&TestInterfaceStub::testVoidDerivedTypeMethod, "", std::tuple<::commonapi::tests::DerivedTypeCollection::TestEnumExtended2, ::commonapi::tests::DerivedTypeCollection::TestMap>());
+CommonAPI::DBus::DBusMethodWithReplyStubDispatcher<
+ TestInterfaceStub,
+ std::tuple<::commonapi::tests::DerivedTypeCollection::TestEnumExtended2, ::commonapi::tests::DerivedTypeCollection::TestMap>,
+ std::tuple<::commonapi::tests::DerivedTypeCollection::TestEnumExtended2, ::commonapi::tests::DerivedTypeCollection::TestMap>
+ > TestInterfaceDBusStubAdapterInternal::testDerivedTypeMethodStubDispatcher(&TestInterfaceStub::testDerivedTypeMethod, "ia{ua(sq)}", std::tuple<::commonapi::tests::DerivedTypeCollection::TestEnumExtended2, ::commonapi::tests::DerivedTypeCollection::TestMap, ::commonapi::tests::DerivedTypeCollection::TestEnumExtended2, ::commonapi::tests::DerivedTypeCollection::TestMap>());
+CommonAPI::DBus::DBusMethodWithReplyStubDispatcher<
+ TestInterfaceStub,
+ std::tuple<std::vector<std::shared_ptr<::commonapi::tests::DerivedTypeCollection::TestPolymorphicStruct>>>,
+ std::tuple<>
+ > TestInterfaceDBusStubAdapterInternal::testArrayOfPolymorphicStructMethodStubDispatcher(&TestInterfaceStub::TestArrayOfPolymorphicStructMethod, "", std::tuple<std::vector<std::shared_ptr<::commonapi::tests::DerivedTypeCollection::TestPolymorphicStruct>>>());
+CommonAPI::DBus::DBusMethodWithReplyStubDispatcher<
+ TestInterfaceStub,
+ std::tuple<::commonapi::tests::DerivedTypeCollection::MapIntToPolymorphic>,
+ std::tuple<>
+ > TestInterfaceDBusStubAdapterInternal::testMapOfPolymorphicStructMethodStubDispatcher(&TestInterfaceStub::TestMapOfPolymorphicStructMethod, "", std::tuple<::commonapi::tests::DerivedTypeCollection::MapIntToPolymorphic>());
+CommonAPI::DBus::DBusMethodWithReplyStubDispatcher<
+ TestInterfaceStub,
+ std::tuple<::commonapi::tests::DerivedTypeCollection::StructWithPolymorphicMember>,
+ std::tuple<>
+ > TestInterfaceDBusStubAdapterInternal::testStructWithPolymorphicMemberMethodStubDispatcher(&TestInterfaceStub::TestStructWithPolymorphicMemberMethod, "", std::tuple<::commonapi::tests::DerivedTypeCollection::StructWithPolymorphicMember>());
+CommonAPI::DBus::DBusMethodWithReplyStubDispatcher<
+ TestInterfaceStub,
+ std::tuple<::commonapi::tests::DerivedTypeCollection::StructWithEnumKeyMap>,
+ std::tuple<>
+ > TestInterfaceDBusStubAdapterInternal::testStructWithEnumKeyMapMemberStubDispatcher(&TestInterfaceStub::TestStructWithEnumKeyMapMember, "", std::tuple<::commonapi::tests::DerivedTypeCollection::StructWithEnumKeyMap>());
+
+
+void TestInterfaceDBusStubAdapterInternal::fireTestPredefinedTypeAttributeAttributeChanged(const uint32_t& value) {
+ CommonAPI::DBus::DBusStubSignalHelper<CommonAPI::DBus::DBusSerializableArguments<uint32_t>>
+ ::sendSignal(
+ *this,
+ "onTestPredefinedTypeAttributeAttributeChanged",
+ "u",
+ value
+ );
+}
+void TestInterfaceDBusStubAdapterInternal::fireTestDerivedStructAttributeAttributeChanged(const ::commonapi::tests::DerivedTypeCollection::TestStructExtended& value) {
+ CommonAPI::DBus::DBusStubSignalHelper<CommonAPI::DBus::DBusSerializableArguments<::commonapi::tests::DerivedTypeCollection::TestStructExtended>>
+ ::sendSignal(
+ *this,
+ "onTestDerivedStructAttributeAttributeChanged",
+ "(sqi)",
+ value
+ );
+}
+void TestInterfaceDBusStubAdapterInternal::fireTestDerivedArrayAttributeAttributeChanged(const ::commonapi::tests::DerivedTypeCollection::TestArrayUInt64& value) {
+ CommonAPI::DBus::DBusStubSignalHelper<CommonAPI::DBus::DBusSerializableArguments<::commonapi::tests::DerivedTypeCollection::TestArrayUInt64>>
+ ::sendSignal(
+ *this,
+ "onTestDerivedArrayAttributeAttributeChanged",
+ "at",
+ value
+ );
+}
+
+void TestInterfaceDBusStubAdapterInternal::fireTestPredefinedTypeBroadcastEvent(const uint32_t& uint32Value, const std::string& stringValue) {
+ CommonAPI::DBus::DBusStubSignalHelper<CommonAPI::DBus::DBusSerializableArguments<uint32_t, std::string>>
+ ::sendSignal(
+ *this,
+ "TestPredefinedTypeBroadcast",
+ "us",
+ uint32Value, stringValue
+ );
+}
+CommonAPI::DBus::DBusMethodWithReplyAdapterDispatcher<
+ TestInterfaceStub,
+ TestInterfaceStubAdapter,
+ std::tuple<>,
+ std::tuple<bool>
+ > TestInterfaceDBusStubAdapterInternal::subscribeTestSelectiveBroadcastSelectiveStubDispatcher(&TestInterfaceStubAdapter::subscribeForTestSelectiveBroadcastSelective, "b");
+
+CommonAPI::DBus::DBusMethodWithReplyAdapterDispatcher<
+ TestInterfaceStub,
+ TestInterfaceStubAdapter,
+ std::tuple<>,
+ std::tuple<>
+ > TestInterfaceDBusStubAdapterInternal::unsubscribeTestSelectiveBroadcastSelectiveStubDispatcher(&TestInterfaceStubAdapter::unsubscribeFromTestSelectiveBroadcastSelective, "");
+
+void TestInterfaceDBusStubAdapterInternal::fireTestSelectiveBroadcastSelective(const std::shared_ptr<CommonAPI::ClientId> _client) {
+ std::shared_ptr<CommonAPI::DBus::DBusClientId> dbusClient = std::dynamic_pointer_cast<CommonAPI::DBus::DBusClientId, CommonAPI::ClientId>(_client);
+
+ if(dbusClient)
+ {
+ CommonAPI::DBus::DBusStubSignalHelper<CommonAPI::DBus::DBusSerializableArguments<>>
+ ::sendSignal(
+ dbusClient->getDBusId(),
+ *this,
+ "TestSelectiveBroadcast",
+ ""
+ );
+ }
+}
+
+void TestInterfaceDBusStubAdapterInternal::sendTestSelectiveBroadcastSelective(const std::shared_ptr<CommonAPI::ClientIdList> _receivers) {
+ std::shared_ptr<CommonAPI::ClientIdList> actualReceiverList = _receivers;
+
+ if (!_receivers)
+ actualReceiverList = subscribersForTestSelectiveBroadcastSelective_;
+
+ for (auto clientIdIterator = actualReceiverList->cbegin(); clientIdIterator != actualReceiverList->cend(); clientIdIterator++) {
+ if (!_receivers || subscribersForTestSelectiveBroadcastSelective_->find(*clientIdIterator) != subscribersForTestSelectiveBroadcastSelective_->end()) {
+ fireTestSelectiveBroadcastSelective(*clientIdIterator);
+ }
+ }
+}
+
+void TestInterfaceDBusStubAdapterInternal::subscribeForTestSelectiveBroadcastSelective(const std::shared_ptr<CommonAPI::ClientId> clientId, bool& success) {
+ bool ok = stub_->onTestSelectiveBroadcastSelectiveSubscriptionRequested(clientId);
+ if (ok) {
+ subscribersForTestSelectiveBroadcastSelective_->insert(clientId);
+ stub_->onTestSelectiveBroadcastSelectiveSubscriptionChanged(clientId, CommonAPI::SelectiveBroadcastSubscriptionEvent::SUBSCRIBED);
+ success = true;
+ } else {
+ success = false;
+ }
+}
+
+
+void TestInterfaceDBusStubAdapterInternal::unsubscribeFromTestSelectiveBroadcastSelective(const std::shared_ptr<CommonAPI::ClientId> clientId) {
+ subscribersForTestSelectiveBroadcastSelective_->erase(clientId);
+ stub_->onTestSelectiveBroadcastSelectiveSubscriptionChanged(clientId, CommonAPI::SelectiveBroadcastSubscriptionEvent::UNSUBSCRIBED);
+}
+
+std::shared_ptr<CommonAPI::ClientIdList> const TestInterfaceDBusStubAdapterInternal::getSubscribersForTestSelectiveBroadcastSelective() {
+ return subscribersForTestSelectiveBroadcastSelective_;
+}
+
+CommonAPI::DBus::DBusMethodWithReplyAdapterDispatcher<
+ TestInterfaceStub,
+ TestInterfaceStubAdapter,
+ std::tuple<>,
+ std::tuple<bool>
+ > TestInterfaceDBusStubAdapterInternal::subscribeTestBroadcastWithOutArgsSelectiveStubDispatcher(&TestInterfaceStubAdapter::subscribeForTestBroadcastWithOutArgsSelective, "b");
+
+CommonAPI::DBus::DBusMethodWithReplyAdapterDispatcher<
+ TestInterfaceStub,
+ TestInterfaceStubAdapter,
+ std::tuple<>,
+ std::tuple<>
+ > TestInterfaceDBusStubAdapterInternal::unsubscribeTestBroadcastWithOutArgsSelectiveStubDispatcher(&TestInterfaceStubAdapter::unsubscribeFromTestBroadcastWithOutArgsSelective, "");
+
+void TestInterfaceDBusStubAdapterInternal::fireTestBroadcastWithOutArgsSelective(const std::shared_ptr<CommonAPI::ClientId> _client, const uint32_t &_uint32Value, const std::string &_stringValue) {
+ std::shared_ptr<CommonAPI::DBus::DBusClientId> dbusClient = std::dynamic_pointer_cast<CommonAPI::DBus::DBusClientId, CommonAPI::ClientId>(_client);
+
+ if(dbusClient)
+ {
+ CommonAPI::DBus::DBusStubSignalHelper<CommonAPI::DBus::DBusSerializableArguments<uint32_t, std::string>>
+ ::sendSignal(
+ dbusClient->getDBusId(),
+ *this,
+ "TestBroadcastWithOutArgs",
+ "us",
+ _uint32Value, _stringValue
+ );
+ }
+}
+
+void TestInterfaceDBusStubAdapterInternal::sendTestBroadcastWithOutArgsSelective(const uint32_t &_uint32Value, const std::string &_stringValue, const std::shared_ptr<CommonAPI::ClientIdList> _receivers) {
+ std::shared_ptr<CommonAPI::ClientIdList> actualReceiverList = _receivers;
+
+ if (!_receivers)
+ actualReceiverList = subscribersForTestBroadcastWithOutArgsSelective_;
+
+ for (auto clientIdIterator = actualReceiverList->cbegin(); clientIdIterator != actualReceiverList->cend(); clientIdIterator++) {
+ if (!_receivers || subscribersForTestBroadcastWithOutArgsSelective_->find(*clientIdIterator) != subscribersForTestBroadcastWithOutArgsSelective_->end()) {
+ fireTestBroadcastWithOutArgsSelective(*clientIdIterator, _uint32Value, _stringValue);
+ }
+ }
+}
+
+void TestInterfaceDBusStubAdapterInternal::subscribeForTestBroadcastWithOutArgsSelective(const std::shared_ptr<CommonAPI::ClientId> clientId, bool& success) {
+ bool ok = stub_->onTestBroadcastWithOutArgsSelectiveSubscriptionRequested(clientId);
+ if (ok) {
+ subscribersForTestBroadcastWithOutArgsSelective_->insert(clientId);
+ stub_->onTestBroadcastWithOutArgsSelectiveSubscriptionChanged(clientId, CommonAPI::SelectiveBroadcastSubscriptionEvent::SUBSCRIBED);
+ success = true;
+ } else {
+ success = false;
+ }
+}
+
+
+void TestInterfaceDBusStubAdapterInternal::unsubscribeFromTestBroadcastWithOutArgsSelective(const std::shared_ptr<CommonAPI::ClientId> clientId) {
+ subscribersForTestBroadcastWithOutArgsSelective_->erase(clientId);
+ stub_->onTestBroadcastWithOutArgsSelectiveSubscriptionChanged(clientId, CommonAPI::SelectiveBroadcastSubscriptionEvent::UNSUBSCRIBED);
+}
+
+std::shared_ptr<CommonAPI::ClientIdList> const TestInterfaceDBusStubAdapterInternal::getSubscribersForTestBroadcastWithOutArgsSelective() {
+ return subscribersForTestBroadcastWithOutArgsSelective_;
+}
+
+
+
+const TestInterfaceDBusStubAdapterHelper::StubDispatcherTable& TestInterfaceDBusStubAdapterInternal::getStubDispatcherTable() {
+ return stubDispatcherTable_;
+}
+
+const CommonAPI::DBus::StubAttributeTable& TestInterfaceDBusStubAdapterInternal::getStubAttributeTable() {
+ return stubAttributeTable_;
+}
+
+TestInterfaceDBusStubAdapterInternal::TestInterfaceDBusStubAdapterInternal(
+ const CommonAPI::DBus::DBusAddress &_address,
+ const std::shared_ptr<CommonAPI::DBus::DBusProxyConnection> &_connection,
+ const std::shared_ptr<CommonAPI::StubBase> &_stub)
+ : CommonAPI::DBus::DBusStubAdapter(_address, _connection,false),
+ TestInterfaceDBusStubAdapterHelper(_address, _connection, std::dynamic_pointer_cast<TestInterfaceStub>(_stub), false),
+ stubDispatcherTable_({
+ { { "getTestPredefinedTypeAttributeAttribute", "" }, &commonapi::tests::TestInterfaceDBusStubAdapterInternal::getTestPredefinedTypeAttributeAttributeStubDispatcher }
+ , { { "setTestPredefinedTypeAttributeAttribute", "u" }, &commonapi::tests::TestInterfaceDBusStubAdapterInternal::setTestPredefinedTypeAttributeAttributeStubDispatcher },
+ { { "getTestDerivedStructAttributeAttribute", "" }, &commonapi::tests::TestInterfaceDBusStubAdapterInternal::getTestDerivedStructAttributeAttributeStubDispatcher }
+ , { { "setTestDerivedStructAttributeAttribute", "(sqi)" }, &commonapi::tests::TestInterfaceDBusStubAdapterInternal::setTestDerivedStructAttributeAttributeStubDispatcher },
+ { { "getTestDerivedArrayAttributeAttribute", "" }, &commonapi::tests::TestInterfaceDBusStubAdapterInternal::getTestDerivedArrayAttributeAttributeStubDispatcher }
+ , { { "setTestDerivedArrayAttributeAttribute", "at" }, &commonapi::tests::TestInterfaceDBusStubAdapterInternal::setTestDerivedArrayAttributeAttributeStubDispatcher }
+ ,
+ { { "testEmptyMethod", "" }, &commonapi::tests::TestInterfaceDBusStubAdapterInternal::testEmptyMethodStubDispatcher },
+ { { "testVoidPredefinedTypeMethod", "us" }, &commonapi::tests::TestInterfaceDBusStubAdapterInternal::testVoidPredefinedTypeMethodStubDispatcher },
+ { { "testPredefinedTypeMethod", "us" }, &commonapi::tests::TestInterfaceDBusStubAdapterInternal::testPredefinedTypeMethodStubDispatcher },
+ { { "testVoidDerivedTypeMethod", "ia{ua(sq)}" }, &commonapi::tests::TestInterfaceDBusStubAdapterInternal::testVoidDerivedTypeMethodStubDispatcher },
+ { { "testDerivedTypeMethod", "ia{ua(sq)}" }, &commonapi::tests::TestInterfaceDBusStubAdapterInternal::testDerivedTypeMethodStubDispatcher },
+ { { "TestArrayOfPolymorphicStructMethod", "a(uv)" }, &commonapi::tests::TestInterfaceDBusStubAdapterInternal::testArrayOfPolymorphicStructMethodStubDispatcher },
+ { { "TestMapOfPolymorphicStructMethod", "a{y(uv)}" }, &commonapi::tests::TestInterfaceDBusStubAdapterInternal::testMapOfPolymorphicStructMethodStubDispatcher },
+ { { "TestStructWithPolymorphicMemberMethod", "(u(uv))" }, &commonapi::tests::TestInterfaceDBusStubAdapterInternal::testStructWithPolymorphicMemberMethodStubDispatcher },
+ { { "TestStructWithEnumKeyMapMember", "(a{is})" }, &commonapi::tests::TestInterfaceDBusStubAdapterInternal::testStructWithEnumKeyMapMemberStubDispatcher }
+ ,
+ { { "subscribeForTestSelectiveBroadcastSelective", "" }, &commonapi::tests::TestInterfaceDBusStubAdapterInternal::subscribeTestSelectiveBroadcastSelectiveStubDispatcher }
+ ,
+ { { "unsubscribeFromTestSelectiveBroadcastSelective", "" }, &commonapi::tests::TestInterfaceDBusStubAdapterInternal::unsubscribeTestSelectiveBroadcastSelectiveStubDispatcher },
+ { { "subscribeForTestBroadcastWithOutArgsSelective", "" }, &commonapi::tests::TestInterfaceDBusStubAdapterInternal::subscribeTestBroadcastWithOutArgsSelectiveStubDispatcher }
+ ,
+ { { "unsubscribeFromTestBroadcastWithOutArgsSelective", "" }, &commonapi::tests::TestInterfaceDBusStubAdapterInternal::unsubscribeTestBroadcastWithOutArgsSelectiveStubDispatcher }
+ }),
+ stubAttributeTable_() {
+ subscribersForTestSelectiveBroadcastSelective_ = std::make_shared<CommonAPI::ClientIdList>();
+ subscribersForTestBroadcastWithOutArgsSelective_ = std::make_shared<CommonAPI::ClientIdList>();
+
+ stubDispatcherTable_.insert({ { "getInterfaceVersion", "" }, &commonapi::tests::TestInterfaceDBusStubAdapterInternal::getTestInterfaceInterfaceVersionStubDispatcher });
+}
+
+const bool TestInterfaceDBusStubAdapterInternal::hasFreedesktopProperties() {
+ return false;
+}
+
+} // namespace tests
+} // namespace commonapi
+} // namespace v1_0