summaryrefslogtreecommitdiff
path: root/src/test/commonapi/tests/TestInterfaceStubDefault.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/test/commonapi/tests/TestInterfaceStubDefault.cpp')
-rw-r--r--src/test/commonapi/tests/TestInterfaceStubDefault.cpp120
1 files changed, 73 insertions, 47 deletions
diff --git a/src/test/commonapi/tests/TestInterfaceStubDefault.cpp b/src/test/commonapi/tests/TestInterfaceStubDefault.cpp
index e68bf40..e53fe6a 100644
--- a/src/test/commonapi/tests/TestInterfaceStubDefault.cpp
+++ b/src/test/commonapi/tests/TestInterfaceStubDefault.cpp
@@ -1,9 +1,11 @@
/*
-* This file was generated by the CommonAPI Generators.
+* This file was generated by the CommonAPI Generators.
+* Used org.genivi.commonapi.core 2.1.0.qualifier.
+* Used org.franca.core 0.8.9.201308271211.
*
-* 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/.
+* 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 <commonapi/tests/TestInterfaceStubDefault.h>
@@ -29,16 +31,9 @@ const uint32_t& TestInterfaceStubDefault::getTestPredefinedTypeAttributeAttribut
void TestInterfaceStubDefault::setTestPredefinedTypeAttributeAttribute(uint32_t value) {
const bool valueChanged = trySetTestPredefinedTypeAttributeAttribute(std::move(value));
- if (valueChanged)
+ if (valueChanged) {
stubAdapter_->fireTestPredefinedTypeAttributeAttributeChanged(testPredefinedTypeAttributeAttributeValue_);
-}
-
-void TestInterfaceStubDefault::setTestPredefinedTypeAttributeAttribute(const std::shared_ptr<CommonAPI::ClientId> clientId, uint32_t value) {
- setTestPredefinedTypeAttributeAttribute(value);
-}
-
-void TestInterfaceStubDefault::onRemoteTestPredefinedTypeAttributeAttributeChanged() {
- // No operation in default
+ }
}
bool TestInterfaceStubDefault::trySetTestPredefinedTypeAttributeAttribute(uint32_t value) {
@@ -54,18 +49,26 @@ bool TestInterfaceStubDefault::validateTestPredefinedTypeAttributeAttributeReque
return true;
}
-bool TestInterfaceStubDefault::RemoteEventHandler::onRemoteSetTestPredefinedTypeAttributeAttribute(uint32_t value) {
- return defaultStub_->trySetTestPredefinedTypeAttributeAttribute(std::move(value));
+void TestInterfaceStubDefault::setTestPredefinedTypeAttributeAttribute(const std::shared_ptr<CommonAPI::ClientId> clientId, uint32_t value) {
+ setTestPredefinedTypeAttributeAttribute(value);
}
-bool TestInterfaceStubDefault::RemoteEventHandler::onRemoteSetTestPredefinedTypeAttributeAttribute(const std::shared_ptr<CommonAPI::ClientId> clientId, uint32_t value) {
- return onRemoteSetTestPredefinedTypeAttributeAttribute(value);
+void TestInterfaceStubDefault::onRemoteTestPredefinedTypeAttributeAttributeChanged() {
+ // No operation in default
}
void TestInterfaceStubDefault::RemoteEventHandler::onRemoteTestPredefinedTypeAttributeAttributeChanged() {
defaultStub_->onRemoteTestPredefinedTypeAttributeAttributeChanged();
}
+bool TestInterfaceStubDefault::RemoteEventHandler::onRemoteSetTestPredefinedTypeAttributeAttribute(uint32_t value) {
+ return defaultStub_->trySetTestPredefinedTypeAttributeAttribute(std::move(value));
+}
+
+bool TestInterfaceStubDefault::RemoteEventHandler::onRemoteSetTestPredefinedTypeAttributeAttribute(const std::shared_ptr<CommonAPI::ClientId> clientId, uint32_t value) {
+ return onRemoteSetTestPredefinedTypeAttributeAttribute(value);
+}
+
const DerivedTypeCollection::TestStructExtended& TestInterfaceStubDefault::getTestDerivedStructAttributeAttribute() {
return testDerivedStructAttributeAttributeValue_;
}
@@ -76,16 +79,9 @@ const DerivedTypeCollection::TestStructExtended& TestInterfaceStubDefault::getTe
void TestInterfaceStubDefault::setTestDerivedStructAttributeAttribute(DerivedTypeCollection::TestStructExtended value) {
const bool valueChanged = trySetTestDerivedStructAttributeAttribute(std::move(value));
- if (valueChanged)
+ if (valueChanged) {
stubAdapter_->fireTestDerivedStructAttributeAttributeChanged(testDerivedStructAttributeAttributeValue_);
-}
-
-void TestInterfaceStubDefault::setTestDerivedStructAttributeAttribute(const std::shared_ptr<CommonAPI::ClientId> clientId, DerivedTypeCollection::TestStructExtended value) {
- setTestDerivedStructAttributeAttribute(value);
-}
-
-void TestInterfaceStubDefault::onRemoteTestDerivedStructAttributeAttributeChanged() {
- // No operation in default
+ }
}
bool TestInterfaceStubDefault::trySetTestDerivedStructAttributeAttribute(DerivedTypeCollection::TestStructExtended value) {
@@ -101,18 +97,26 @@ bool TestInterfaceStubDefault::validateTestDerivedStructAttributeAttributeReques
return true;
}
-bool TestInterfaceStubDefault::RemoteEventHandler::onRemoteSetTestDerivedStructAttributeAttribute(DerivedTypeCollection::TestStructExtended value) {
- return defaultStub_->trySetTestDerivedStructAttributeAttribute(std::move(value));
+void TestInterfaceStubDefault::setTestDerivedStructAttributeAttribute(const std::shared_ptr<CommonAPI::ClientId> clientId, DerivedTypeCollection::TestStructExtended value) {
+ setTestDerivedStructAttributeAttribute(value);
}
-bool TestInterfaceStubDefault::RemoteEventHandler::onRemoteSetTestDerivedStructAttributeAttribute(const std::shared_ptr<CommonAPI::ClientId> clientId, DerivedTypeCollection::TestStructExtended value) {
- return onRemoteSetTestDerivedStructAttributeAttribute(value);
+void TestInterfaceStubDefault::onRemoteTestDerivedStructAttributeAttributeChanged() {
+ // No operation in default
}
void TestInterfaceStubDefault::RemoteEventHandler::onRemoteTestDerivedStructAttributeAttributeChanged() {
defaultStub_->onRemoteTestDerivedStructAttributeAttributeChanged();
}
+bool TestInterfaceStubDefault::RemoteEventHandler::onRemoteSetTestDerivedStructAttributeAttribute(DerivedTypeCollection::TestStructExtended value) {
+ return defaultStub_->trySetTestDerivedStructAttributeAttribute(std::move(value));
+}
+
+bool TestInterfaceStubDefault::RemoteEventHandler::onRemoteSetTestDerivedStructAttributeAttribute(const std::shared_ptr<CommonAPI::ClientId> clientId, DerivedTypeCollection::TestStructExtended value) {
+ return onRemoteSetTestDerivedStructAttributeAttribute(value);
+}
+
const DerivedTypeCollection::TestArrayUInt64& TestInterfaceStubDefault::getTestDerivedArrayAttributeAttribute() {
return testDerivedArrayAttributeAttributeValue_;
}
@@ -123,16 +127,9 @@ const DerivedTypeCollection::TestArrayUInt64& TestInterfaceStubDefault::getTestD
void TestInterfaceStubDefault::setTestDerivedArrayAttributeAttribute(DerivedTypeCollection::TestArrayUInt64 value) {
const bool valueChanged = trySetTestDerivedArrayAttributeAttribute(std::move(value));
- if (valueChanged)
+ if (valueChanged) {
stubAdapter_->fireTestDerivedArrayAttributeAttributeChanged(testDerivedArrayAttributeAttributeValue_);
-}
-
-void TestInterfaceStubDefault::setTestDerivedArrayAttributeAttribute(const std::shared_ptr<CommonAPI::ClientId> clientId, DerivedTypeCollection::TestArrayUInt64 value) {
- setTestDerivedArrayAttributeAttribute(value);
-}
-
-void TestInterfaceStubDefault::onRemoteTestDerivedArrayAttributeAttributeChanged() {
- // No operation in default
+ }
}
bool TestInterfaceStubDefault::trySetTestDerivedArrayAttributeAttribute(DerivedTypeCollection::TestArrayUInt64 value) {
@@ -148,36 +145,64 @@ bool TestInterfaceStubDefault::validateTestDerivedArrayAttributeAttributeRequest
return true;
}
-bool TestInterfaceStubDefault::RemoteEventHandler::onRemoteSetTestDerivedArrayAttributeAttribute(DerivedTypeCollection::TestArrayUInt64 value) {
- return defaultStub_->trySetTestDerivedArrayAttributeAttribute(std::move(value));
+void TestInterfaceStubDefault::setTestDerivedArrayAttributeAttribute(const std::shared_ptr<CommonAPI::ClientId> clientId, DerivedTypeCollection::TestArrayUInt64 value) {
+ setTestDerivedArrayAttributeAttribute(value);
}
-bool TestInterfaceStubDefault::RemoteEventHandler::onRemoteSetTestDerivedArrayAttributeAttribute(const std::shared_ptr<CommonAPI::ClientId> clientId, DerivedTypeCollection::TestArrayUInt64 value) {
- return onRemoteSetTestDerivedArrayAttributeAttribute(value);
+void TestInterfaceStubDefault::onRemoteTestDerivedArrayAttributeAttributeChanged() {
+ // No operation in default
}
void TestInterfaceStubDefault::RemoteEventHandler::onRemoteTestDerivedArrayAttributeAttributeChanged() {
defaultStub_->onRemoteTestDerivedArrayAttributeAttributeChanged();
}
+bool TestInterfaceStubDefault::RemoteEventHandler::onRemoteSetTestDerivedArrayAttributeAttribute(DerivedTypeCollection::TestArrayUInt64 value) {
+ return defaultStub_->trySetTestDerivedArrayAttributeAttribute(std::move(value));
+}
+
+bool TestInterfaceStubDefault::RemoteEventHandler::onRemoteSetTestDerivedArrayAttributeAttribute(const std::shared_ptr<CommonAPI::ClientId> clientId, DerivedTypeCollection::TestArrayUInt64 value) {
+ return onRemoteSetTestDerivedArrayAttributeAttribute(value);
+}
+
void TestInterfaceStubDefault::testEmptyMethod(const std::shared_ptr<CommonAPI::ClientId> clientId) {
+ // Call old style methods in default
+ testEmptyMethod();
+}
+void TestInterfaceStubDefault::testEmptyMethod() {
// No operation in default
}
void TestInterfaceStubDefault::testVoidPredefinedTypeMethod(const std::shared_ptr<CommonAPI::ClientId> clientId, uint32_t uint32Value, std::string stringValue) {
+ // Call old style methods in default
+ testVoidPredefinedTypeMethod(uint32Value, stringValue);
+}
+void TestInterfaceStubDefault::testVoidPredefinedTypeMethod(uint32_t uint32Value, std::string stringValue) {
// No operation in default
}
void TestInterfaceStubDefault::testPredefinedTypeMethod(const std::shared_ptr<CommonAPI::ClientId> clientId, uint32_t uint32InValue, std::string stringInValue, uint32_t& uint32OutValue, std::string& stringOutValue) {
+ // Call old style methods in default
+ testPredefinedTypeMethod(uint32InValue, stringInValue, uint32OutValue, stringOutValue);
+}
+void TestInterfaceStubDefault::testPredefinedTypeMethod(uint32_t uint32InValue, std::string stringInValue, uint32_t& uint32OutValue, std::string& stringOutValue) {
// No operation in default
}
void TestInterfaceStubDefault::testVoidDerivedTypeMethod(const std::shared_ptr<CommonAPI::ClientId> clientId, DerivedTypeCollection::TestEnumExtended2 testEnumExtended2Value, DerivedTypeCollection::TestMap testMapValue) {
+ // Call old style methods in default
+ testVoidDerivedTypeMethod(testEnumExtended2Value, testMapValue);
+}
+void TestInterfaceStubDefault::testVoidDerivedTypeMethod(DerivedTypeCollection::TestEnumExtended2 testEnumExtended2Value, DerivedTypeCollection::TestMap testMapValue) {
// No operation in default
}
void TestInterfaceStubDefault::testDerivedTypeMethod(const std::shared_ptr<CommonAPI::ClientId> clientId, DerivedTypeCollection::TestEnumExtended2 testEnumExtended2InValue, DerivedTypeCollection::TestMap testMapInValue, DerivedTypeCollection::TestEnumExtended2& testEnumExtended2OutValue, DerivedTypeCollection::TestMap& testMapOutValue) {
+ // Call old style methods in default
+ testDerivedTypeMethod(testEnumExtended2InValue, testMapInValue, testEnumExtended2OutValue, testMapOutValue);
+}
+void TestInterfaceStubDefault::testDerivedTypeMethod(DerivedTypeCollection::TestEnumExtended2 testEnumExtended2InValue, DerivedTypeCollection::TestMap testMapInValue, DerivedTypeCollection::TestEnumExtended2& testEnumExtended2OutValue, DerivedTypeCollection::TestMap& testMapOutValue) {
// No operation in default
}
@@ -185,7 +210,7 @@ void TestInterfaceStubDefault::testDerivedTypeMethod(const std::shared_ptr<Commo
void TestInterfaceStubDefault::fireTestPredefinedTypeBroadcastEvent(const uint32_t& uint32Value, const std::string& stringValue) {
stubAdapter_->fireTestPredefinedTypeBroadcastEvent(uint32Value, stringValue);
}
-void TestInterfaceStubDefault::fireTestSelectiveBroadcastSelective(const CommonAPI::ClientIdList* receivers) {
+void TestInterfaceStubDefault::fireTestSelectiveBroadcastSelective(const std::shared_ptr<CommonAPI::ClientIdList> receivers) {
stubAdapter_->sendTestSelectiveBroadcastSelective(receivers);
}
void TestInterfaceStubDefault::onTestSelectiveBroadcastSelectiveSubscriptionChanged(const std::shared_ptr<CommonAPI::ClientId> clientId, const CommonAPI::SelectiveBroadcastSubscriptionEvent event) {
@@ -195,11 +220,11 @@ bool TestInterfaceStubDefault::onTestSelectiveBroadcastSelectiveSubscriptionRequ
// Accept in default
return true;
}
-CommonAPI::ClientIdList* const TestInterfaceStubDefault::getSubscribersForTestSelectiveBroadcastSelective() {
+std::shared_ptr<CommonAPI::ClientIdList> const TestInterfaceStubDefault::getSubscribersForTestSelectiveBroadcastSelective() {
return(stubAdapter_->getSubscribersForTestSelectiveBroadcastSelective());
}
-void TestInterfaceStubDefault::fireTestBroadcastWithOutArgsSelective(const uint32_t& uint32Value, const std::string& stringValue, const CommonAPI::ClientIdList* receivers) {
+void TestInterfaceStubDefault::fireTestBroadcastWithOutArgsSelective(const uint32_t& uint32Value, const std::string& stringValue, const std::shared_ptr<CommonAPI::ClientIdList> receivers) {
stubAdapter_->sendTestBroadcastWithOutArgsSelective(uint32Value, stringValue, receivers);
}
void TestInterfaceStubDefault::onTestBroadcastWithOutArgsSelectiveSubscriptionChanged(const std::shared_ptr<CommonAPI::ClientId> clientId, const CommonAPI::SelectiveBroadcastSubscriptionEvent event) {
@@ -209,11 +234,12 @@ bool TestInterfaceStubDefault::onTestBroadcastWithOutArgsSelectiveSubscriptionRe
// Accept in default
return true;
}
-CommonAPI::ClientIdList* const TestInterfaceStubDefault::getSubscribersForTestBroadcastWithOutArgsSelective() {
+std::shared_ptr<CommonAPI::ClientIdList> const TestInterfaceStubDefault::getSubscribersForTestBroadcastWithOutArgsSelective() {
return(stubAdapter_->getSubscribersForTestBroadcastWithOutArgsSelective());
}
+
TestInterfaceStubDefault::RemoteEventHandler::RemoteEventHandler(TestInterfaceStubDefault* defaultStub):
defaultStub_(defaultStub) {
}