summaryrefslogtreecommitdiff
path: root/src/test/commonapi/tests/TestFreedesktopInterfaceStubDefault.h
diff options
context:
space:
mode:
authorStefan Laner <laner@itestra.de>2014-03-13 14:15:28 +0100
committerJohannes Langlotz <Johannes.Langlotz@partner.bmw.de>2014-03-24 16:46:50 +0100
commit845303b00a5ca98a83ccfd5be82075fc546b1e89 (patch)
tree0c876298d22474f17c821f5b6afe756d1a3b97ce /src/test/commonapi/tests/TestFreedesktopInterfaceStubDefault.h
parentb0a9c1d6c6ab78f722a74098080b32881c764784 (diff)
downloadgenivi-common-api-dbus-runtime-845303b00a5ca98a83ccfd5be82075fc546b1e89.tar.gz
Implemented stub support for org.freedesktop.DBus.Properties
Change-Id: I75abc2e75643ff8da51795787970d55cf4e470c2
Diffstat (limited to 'src/test/commonapi/tests/TestFreedesktopInterfaceStubDefault.h')
-rw-r--r--src/test/commonapi/tests/TestFreedesktopInterfaceStubDefault.h104
1 files changed, 104 insertions, 0 deletions
diff --git a/src/test/commonapi/tests/TestFreedesktopInterfaceStubDefault.h b/src/test/commonapi/tests/TestFreedesktopInterfaceStubDefault.h
new file mode 100644
index 0000000..597e176
--- /dev/null
+++ b/src/test/commonapi/tests/TestFreedesktopInterfaceStubDefault.h
@@ -0,0 +1,104 @@
+/*
+* This file was generated by the CommonAPI Generators.
+* Used org.genivi.commonapi.core 2.1.5.qualifier.
+* Used org.franca.core 0.8.10.201309262002.
+*
+* 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/.
+*/
+#ifndef COMMONAPI_TESTS_Test_Freedesktop_Interface_STUB_DEFAULT_H_
+#define COMMONAPI_TESTS_Test_Freedesktop_Interface_STUB_DEFAULT_H_
+
+
+#include <commonapi/tests/TestFreedesktopInterfaceStub.h>
+#include <sstream>
+
+namespace commonapi {
+namespace tests {
+
+/**
+ * Provides a default implementation for TestFreedesktopInterfaceStubRemoteEvent and
+ * TestFreedesktopInterfaceStub. Method callbacks have an empty implementation,
+ * remote set calls on attributes will always change the value of the attribute
+ * to the one received.
+ *
+ * Override this stub if you only want to provide a subset of the functionality
+ * that would be defined for this service, and/or if you do not need any non-default
+ * behaviour.
+ */
+class TestFreedesktopInterfaceStubDefault : public virtual TestFreedesktopInterfaceStub {
+public:
+ TestFreedesktopInterfaceStubDefault();
+
+ TestFreedesktopInterfaceStubRemoteEvent* initStubAdapter(const std::shared_ptr<TestFreedesktopInterfaceStubAdapter>& stubAdapter);
+
+ const CommonAPI::Version& getInterfaceVersion(std::shared_ptr<CommonAPI::ClientId> clientId);
+
+ virtual const uint32_t& getTestPredefinedTypeAttributeAttribute();
+ virtual const uint32_t& getTestPredefinedTypeAttributeAttribute(const std::shared_ptr<CommonAPI::ClientId> clientId);
+ virtual void setTestPredefinedTypeAttributeAttribute(uint32_t value);
+ virtual void setTestPredefinedTypeAttributeAttribute(const std::shared_ptr<CommonAPI::ClientId> clientId, uint32_t value);
+ virtual const uint32_t& getTestReadonlyAttributeAttribute();
+ virtual const uint32_t& getTestReadonlyAttributeAttribute(const std::shared_ptr<CommonAPI::ClientId> clientId);
+ virtual void setTestReadonlyAttributeAttribute(uint32_t value);
+ virtual const DerivedTypeCollection::TestStructExtended& getTestDerivedStructAttributeAttribute();
+ virtual const DerivedTypeCollection::TestStructExtended& getTestDerivedStructAttributeAttribute(const std::shared_ptr<CommonAPI::ClientId> clientId);
+ virtual void setTestDerivedStructAttributeAttribute(DerivedTypeCollection::TestStructExtended value);
+ virtual void setTestDerivedStructAttributeAttribute(const std::shared_ptr<CommonAPI::ClientId> clientId, DerivedTypeCollection::TestStructExtended value);
+ virtual const DerivedTypeCollection::TestArrayUInt64& getTestDerivedArrayAttributeAttribute();
+ virtual const DerivedTypeCollection::TestArrayUInt64& getTestDerivedArrayAttributeAttribute(const std::shared_ptr<CommonAPI::ClientId> clientId);
+ virtual void setTestDerivedArrayAttributeAttribute(DerivedTypeCollection::TestArrayUInt64 value);
+ virtual void setTestDerivedArrayAttributeAttribute(const std::shared_ptr<CommonAPI::ClientId> clientId, DerivedTypeCollection::TestArrayUInt64 value);
+
+
+
+
+protected:
+ virtual bool trySetTestPredefinedTypeAttributeAttribute(uint32_t value);
+ virtual bool validateTestPredefinedTypeAttributeAttributeRequestedValue(const uint32_t& value);
+ virtual void onRemoteTestPredefinedTypeAttributeAttributeChanged();
+ virtual bool trySetTestReadonlyAttributeAttribute(uint32_t value);
+ virtual bool validateTestReadonlyAttributeAttributeRequestedValue(const uint32_t& value);
+ virtual bool trySetTestDerivedStructAttributeAttribute(DerivedTypeCollection::TestStructExtended value);
+ virtual bool validateTestDerivedStructAttributeAttributeRequestedValue(const DerivedTypeCollection::TestStructExtended& value);
+ virtual void onRemoteTestDerivedStructAttributeAttributeChanged();
+ virtual bool trySetTestDerivedArrayAttributeAttribute(DerivedTypeCollection::TestArrayUInt64 value);
+ virtual bool validateTestDerivedArrayAttributeAttributeRequestedValue(const DerivedTypeCollection::TestArrayUInt64& value);
+ virtual void onRemoteTestDerivedArrayAttributeAttributeChanged();
+ class RemoteEventHandler: public virtual TestFreedesktopInterfaceStubRemoteEvent {
+ public:
+ RemoteEventHandler(TestFreedesktopInterfaceStubDefault* defaultStub);
+
+ virtual bool onRemoteSetTestPredefinedTypeAttributeAttribute(uint32_t value);
+ virtual bool onRemoteSetTestPredefinedTypeAttributeAttribute(const std::shared_ptr<CommonAPI::ClientId> clientId, uint32_t value);
+ virtual void onRemoteTestPredefinedTypeAttributeAttributeChanged();
+
+
+ virtual bool onRemoteSetTestDerivedStructAttributeAttribute(DerivedTypeCollection::TestStructExtended value);
+ virtual bool onRemoteSetTestDerivedStructAttributeAttribute(const std::shared_ptr<CommonAPI::ClientId> clientId, DerivedTypeCollection::TestStructExtended value);
+ virtual void onRemoteTestDerivedStructAttributeAttributeChanged();
+
+ virtual bool onRemoteSetTestDerivedArrayAttributeAttribute(DerivedTypeCollection::TestArrayUInt64 value);
+ virtual bool onRemoteSetTestDerivedArrayAttributeAttribute(const std::shared_ptr<CommonAPI::ClientId> clientId, DerivedTypeCollection::TestArrayUInt64 value);
+ virtual void onRemoteTestDerivedArrayAttributeAttributeChanged();
+
+
+ private:
+ TestFreedesktopInterfaceStubDefault* defaultStub_;
+ };
+private:
+ TestFreedesktopInterfaceStubDefault::RemoteEventHandler remoteEventHandler_;
+
+ uint32_t testPredefinedTypeAttributeAttributeValue_;
+ uint32_t testReadonlyAttributeAttributeValue_;
+ DerivedTypeCollection::TestStructExtended testDerivedStructAttributeAttributeValue_;
+ DerivedTypeCollection::TestArrayUInt64 testDerivedArrayAttributeAttributeValue_;
+
+ CommonAPI::Version interfaceVersion_;
+};
+
+} // namespace tests
+} // namespace commonapi
+
+#endif // COMMONAPI_TESTS_Test_Freedesktop_Interface_STUB_DEFAULT_H_