From 72fdb5bfac7fb7923b83e47e81a13d10ad09dfe2 Mon Sep 17 00:00:00 2001 From: Date: Thu, 23 Apr 2015 09:44:13 +0200 Subject: Add commonapi generated stuff to allow poi-manager being built --- .gitignore | 2 +- api/franca/.gitignore | 2 +- .../org/genivi/navigation/NavigationTypes.cpp | 146 +++ .../org/genivi/navigation/NavigationTypes.h | 275 +++++ .../navigation/poiservice/POIContentManager.h | 67 ++ .../poiservice/POIContentManagerDBusProxy.cpp | 437 +++++++ .../poiservice/POIContentManagerDBusProxy.h | 173 +++ .../POIContentManagerDBusStubAdapter.cpp | 559 +++++++++ .../poiservice/POIContentManagerDBusStubAdapter.h | 280 +++++ .../navigation/poiservice/POIContentManagerProxy.h | 787 +++++++++++++ .../poiservice/POIContentManagerProxyBase.h | 198 ++++ .../navigation/poiservice/POIContentManagerStub.h | 252 ++++ .../poiservice/POIContentManagerStubDefault.cpp | 265 +++++ .../poiservice/POIContentManagerStubDefault.h | 204 ++++ .../navigation/poiservice/POIServiceTypes.cpp | 722 ++++++++++++ .../genivi/navigation/poiservice/POIServiceTypes.h | 1227 ++++++++++++++++++++ .../poi-manager-server/poi-manager-server-stub.cpp | 193 ++- .../poi-manager-server/poi-manager-server-stub.h | 23 +- src/poi-service/script/build-for-commonapi.sh | 77 ++ src/poi-service/script/build.sh | 12 - 20 files changed, 5876 insertions(+), 25 deletions(-) create mode 100644 api/franca/navigation/src-gen/org/genivi/navigation/NavigationTypes.cpp create mode 100644 api/franca/navigation/src-gen/org/genivi/navigation/NavigationTypes.h create mode 100644 api/franca/navigation/src-gen/org/genivi/navigation/poiservice/POIContentManager.h create mode 100644 api/franca/navigation/src-gen/org/genivi/navigation/poiservice/POIContentManagerDBusProxy.cpp create mode 100644 api/franca/navigation/src-gen/org/genivi/navigation/poiservice/POIContentManagerDBusProxy.h create mode 100644 api/franca/navigation/src-gen/org/genivi/navigation/poiservice/POIContentManagerDBusStubAdapter.cpp create mode 100644 api/franca/navigation/src-gen/org/genivi/navigation/poiservice/POIContentManagerDBusStubAdapter.h create mode 100644 api/franca/navigation/src-gen/org/genivi/navigation/poiservice/POIContentManagerProxy.h create mode 100644 api/franca/navigation/src-gen/org/genivi/navigation/poiservice/POIContentManagerProxyBase.h create mode 100644 api/franca/navigation/src-gen/org/genivi/navigation/poiservice/POIContentManagerStub.h create mode 100644 api/franca/navigation/src-gen/org/genivi/navigation/poiservice/POIContentManagerStubDefault.cpp create mode 100644 api/franca/navigation/src-gen/org/genivi/navigation/poiservice/POIContentManagerStubDefault.h create mode 100644 api/franca/navigation/src-gen/org/genivi/navigation/poiservice/POIServiceTypes.cpp create mode 100644 api/franca/navigation/src-gen/org/genivi/navigation/poiservice/POIServiceTypes.h create mode 100755 src/poi-service/script/build-for-commonapi.sh diff --git a/.gitignore b/.gitignore index e4fc485..f54241d 100644 --- a/.gitignore +++ b/.gitignore @@ -15,4 +15,4 @@ positioning/ CMakeFiles/ CMakeCache.txt cmake_install.cmake -src-gen + diff --git a/api/franca/.gitignore b/api/franca/.gitignore index 17a20a4..04dcda4 100644 --- a/api/franca/.gitignore +++ b/api/franca/.gitignore @@ -1,4 +1,4 @@ *.xml *.project -src-gen/ + diff --git a/api/franca/navigation/src-gen/org/genivi/navigation/NavigationTypes.cpp b/api/franca/navigation/src-gen/org/genivi/navigation/NavigationTypes.cpp new file mode 100644 index 0000000..cb28b7f --- /dev/null +++ b/api/franca/navigation/src-gen/org/genivi/navigation/NavigationTypes.cpp @@ -0,0 +1,146 @@ +/* +* This file was generated by the CommonAPI Generators. +* Used org.genivi.commonapi.core 2.1.6.v20140519. +* Used org.franca.core 0.8.11.201401091023. +* +* 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 "NavigationTypes.h" + + +namespace org { +namespace genivi { +namespace navigation { +namespace NavigationTypes { + + +Version::Version(const uint16_t& versionMajorValue, const uint16_t& versionMinorValue, const uint16_t& versionMicroValue, const std::string& dateValue): + versionMajor(versionMajorValue), + versionMinor(versionMinorValue), + versionMicro(versionMicroValue), + date(dateValue) +{ +} + + +bool operator==(const Version& lhs, const Version& rhs) { + if (&lhs == &rhs) + return true; + + return + lhs.versionMajor == rhs.versionMajor && + lhs.versionMinor == rhs.versionMinor && + lhs.versionMicro == rhs.versionMicro && + lhs.date == rhs.date + ; +} + +void Version::readFromInputStream(CommonAPI::InputStream& inputStream) { + inputStream >> versionMajor; + inputStream >> versionMinor; + inputStream >> versionMicro; + inputStream >> date; +} + +void Version::writeToOutputStream(CommonAPI::OutputStream& outputStream) const { + outputStream << versionMajor; + outputStream << versionMinor; + outputStream << versionMicro; + outputStream << date; +} + + +Coordinate2D::Coordinate2D(const double& latitudeValue, const double& longitudeValue): + latitude(latitudeValue), + longitude(longitudeValue) +{ +} + + +bool operator==(const Coordinate2D& lhs, const Coordinate2D& rhs) { + if (&lhs == &rhs) + return true; + + return + lhs.latitude == rhs.latitude && + lhs.longitude == rhs.longitude + ; +} + +void Coordinate2D::readFromInputStream(CommonAPI::InputStream& inputStream) { + inputStream >> latitude; + inputStream >> longitude; +} + +void Coordinate2D::writeToOutputStream(CommonAPI::OutputStream& outputStream) const { + outputStream << latitude; + outputStream << longitude; +} + +Coordinate3D::Coordinate3D(const double& latitudeValue, const double& longitudeValue, const int32_t& altitudeValue): + Coordinate2D(latitudeValue, longitudeValue), + altitude(altitudeValue) +{ +} + + +bool operator==(const Coordinate3D& lhs, const Coordinate3D& rhs) { + if (&lhs == &rhs) + return true; + + return + static_cast(lhs) == static_cast(rhs) && + lhs.altitude == rhs.altitude + ; +} + +void Coordinate3D::readFromInputStream(CommonAPI::InputStream& inputStream) { + Coordinate2D::readFromInputStream(inputStream); + inputStream >> altitude; +} + +void Coordinate3D::writeToOutputStream(CommonAPI::OutputStream& outputStream) const { + Coordinate2D::writeToOutputStream(outputStream); + outputStream << altitude; +} + + + +Rectangle::Rectangle(const Coordinate2D& topLeftValue, const Coordinate2D& bottomRightValue): + topLeft(topLeftValue), + bottomRight(bottomRightValue) +{ +} + + +bool operator==(const Rectangle& lhs, const Rectangle& rhs) { + if (&lhs == &rhs) + return true; + + return + lhs.topLeft == rhs.topLeft && + lhs.bottomRight == rhs.bottomRight + ; +} + +void Rectangle::readFromInputStream(CommonAPI::InputStream& inputStream) { + inputStream >> topLeft; + inputStream >> bottomRight; +} + +void Rectangle::writeToOutputStream(CommonAPI::OutputStream& outputStream) const { + outputStream << topLeft; + outputStream << bottomRight; +} + + + + + + +} // namespace NavigationTypes +} // namespace navigation +} // namespace genivi +} // namespace org diff --git a/api/franca/navigation/src-gen/org/genivi/navigation/NavigationTypes.h b/api/franca/navigation/src-gen/org/genivi/navigation/NavigationTypes.h new file mode 100644 index 0000000..248ae88 --- /dev/null +++ b/api/franca/navigation/src-gen/org/genivi/navigation/NavigationTypes.h @@ -0,0 +1,275 @@ +/* +* This file was generated by the CommonAPI Generators. +* Used org.genivi.commonapi.core 2.1.6.v20140519. +* Used org.franca.core 0.8.11.201401091023. +* +* 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 ORG_GENIVI_NAVIGATION_Navigation_Types_H_ +#define ORG_GENIVI_NAVIGATION_Navigation_Types_H_ + + + +#if !defined (COMMONAPI_INTERNAL_COMPILATION) +#define COMMONAPI_INTERNAL_COMPILATION +#endif + +#include +#include +#include +#include +#include +#include +#include +#include + +#undef COMMONAPI_INTERNAL_COMPILATION + +namespace org { +namespace genivi { +namespace navigation { + +namespace NavigationTypes { + /** + * version. + */ + /** + * version. + */ + struct Version: CommonAPI::SerializableStruct { + /** + * when the major changes, then backward compatibility with previous releases is + * not granted. + */ + uint16_t versionMajor; + /** + * when the minor changes, then backward compatibility with previous releases is + * granted, but something changed in the implementation of the API (e.g. new + * methods may have been added). + */ + uint16_t versionMinor; + /** + * when the micro changes, then backward compatibility with previous releases is + * granted (bug fixes or documentation modifications). + */ + uint16_t versionMicro; + /** + * release date (e.g. 21-06-2011). + */ + std::string date; + + Version() = default; + Version(const uint16_t& versionMajor, const uint16_t& versionMinor, const uint16_t& versionMicro, const std::string& date); + + + virtual void readFromInputStream(CommonAPI::InputStream& inputStream); + virtual void writeToOutputStream(CommonAPI::OutputStream& outputStream) const; + + static inline void writeToTypeOutputStream(CommonAPI::TypeOutputStream& typeOutputStream) { + typeOutputStream.writeUInt16Type(); + typeOutputStream.writeUInt16Type(); + typeOutputStream.writeUInt16Type(); + typeOutputStream.writeStringType(); + } + }; + typedef uint32_t Handle; + struct Coordinate2D: CommonAPI::SerializableStruct { + double latitude; + double longitude; + + Coordinate2D() = default; + Coordinate2D(const double& latitude, const double& longitude); + + + virtual void readFromInputStream(CommonAPI::InputStream& inputStream); + virtual void writeToOutputStream(CommonAPI::OutputStream& outputStream) const; + + static inline void writeToTypeOutputStream(CommonAPI::TypeOutputStream& typeOutputStream) { + typeOutputStream.writeDoubleType(); + typeOutputStream.writeDoubleType(); + } + }; + struct Coordinate3D: Coordinate2D { + int32_t altitude; + + Coordinate3D() = default; + Coordinate3D(const double& latitude, const double& longitude, const int32_t& altitude); + + + virtual void readFromInputStream(CommonAPI::InputStream& inputStream); + virtual void writeToOutputStream(CommonAPI::OutputStream& outputStream) const; + + static inline void writeToTypeOutputStream(CommonAPI::TypeOutputStream& typeOutputStream) { + Coordinate2D::writeToTypeOutputStream(typeOutputStream); + typeOutputStream.writeInt32Type(); + } + }; + typedef std::vector Polygon; + typedef Polygon Area; + struct Rectangle: CommonAPI::SerializableStruct { + Coordinate2D topLeft; + Coordinate2D bottomRight; + + Rectangle() = default; + Rectangle(const Coordinate2D& topLeft, const Coordinate2D& bottomRight); + + + virtual void readFromInputStream(CommonAPI::InputStream& inputStream); + virtual void writeToOutputStream(CommonAPI::OutputStream& outputStream) const; + + static inline void writeToTypeOutputStream(CommonAPI::TypeOutputStream& typeOutputStream) { + typeOutputStream.beginWriteStructType(); + typeOutputStream.writeDoubleType();typeOutputStream.writeDoubleType(); + typeOutputStream.endWriteStructType(); + typeOutputStream.beginWriteStructType(); + typeOutputStream.writeDoubleType();typeOutputStream.writeDoubleType(); + typeOutputStream.endWriteStructType(); + } + }; + enum class BasicEnum: int32_t { + INVALID = 0x0 + }; + + // Definition of a comparator still is necessary for GCC 4.4.1, topic is fixed since 4.5.1 + struct BasicEnumComparator; + /** + * Settings + */ + enum class Settings: int32_t { + INVALID = 0x0, + UNITS_OF_MEASUREMENT = 0x30, + LOCALE = 0x25, + TIME_FORMAT = 0x3, + COORDINATES_FORMAT = 0x6 + }; + + // Definition of a comparator still is necessary for GCC 4.4.1, topic is fixed since 4.5.1 + struct SettingsComparator; + typedef uint64_t Timestamp; + typedef double Distance; + typedef CommonAPI::ByteBuffer LinkId; + +bool operator==(const Version& lhs, const Version& rhs); +inline bool operator!=(const Version& lhs, const Version& rhs) { + return !(lhs == rhs); +} +bool operator==(const Coordinate2D& lhs, const Coordinate2D& rhs); +inline bool operator!=(const Coordinate2D& lhs, const Coordinate2D& rhs) { + return !(lhs == rhs); +} +bool operator==(const Coordinate3D& lhs, const Coordinate3D& rhs); +inline bool operator!=(const Coordinate3D& lhs, const Coordinate3D& rhs) { + return !(lhs == rhs); +} +bool operator==(const Rectangle& lhs, const Rectangle& rhs); +inline bool operator!=(const Rectangle& lhs, const Rectangle& rhs) { + return !(lhs == rhs); +} +inline CommonAPI::InputStream& operator>>(CommonAPI::InputStream& inputStream, BasicEnum& enumValue) { + return inputStream.readEnumValue(enumValue); +} + +inline CommonAPI::OutputStream& operator<<(CommonAPI::OutputStream& outputStream, const BasicEnum& enumValue) { + return outputStream.writeEnumValue(static_cast(enumValue)); +} + +struct BasicEnumComparator { + inline bool operator()(const BasicEnum& lhs, const BasicEnum& rhs) const { + return static_cast(lhs) < static_cast(rhs); + } +}; + +inline CommonAPI::InputStream& operator>>(CommonAPI::InputStream& inputStream, Settings& enumValue) { + return inputStream.readEnumValue(enumValue); +} + +inline CommonAPI::OutputStream& operator<<(CommonAPI::OutputStream& outputStream, const Settings& enumValue) { + return outputStream.writeEnumValue(static_cast(enumValue)); +} + +struct SettingsComparator { + inline bool operator()(const Settings& lhs, const Settings& rhs) const { + return static_cast(lhs) < static_cast(rhs); + } +}; + + + +static inline const char* getTypeCollectionName() { + static const char* typeCollectionName = "org.genivi.navigation.NavigationTypes"; + return typeCollectionName; +} + + +} // namespace NavigationTypes + +} // namespace navigation +} // namespace genivi +} // namespace org + +namespace CommonAPI { + + template<> + struct BasicTypeWriter { + inline static void writeType (CommonAPI::TypeOutputStream& typeStream) { + typeStream.writeInt32EnumType(); + } + }; + + template<> + struct InputStreamVectorHelper { + static void beginReadVector(InputStream& inputStream, const std::vector& vectorValue) { + inputStream.beginReadInt32EnumVector(); + } + }; + + template <> + struct OutputStreamVectorHelper { + static void beginWriteVector(OutputStream& outputStream, const std::vector& vectorValue) { + outputStream.beginWriteInt32EnumVector(vectorValue.size()); + } + }; + template<> + struct BasicTypeWriter { + inline static void writeType (CommonAPI::TypeOutputStream& typeStream) { + typeStream.writeInt32EnumType(); + } + }; + + template<> + struct InputStreamVectorHelper { + static void beginReadVector(InputStream& inputStream, const std::vector& vectorValue) { + inputStream.beginReadInt32EnumVector(); + } + }; + + template <> + struct OutputStreamVectorHelper { + static void beginWriteVector(OutputStream& outputStream, const std::vector& vectorValue) { + outputStream.beginWriteInt32EnumVector(vectorValue.size()); + } + }; + +} + + +namespace std { + //Hash for BasicEnum + template<> + struct hash { + inline size_t operator()(const org::genivi::navigation::NavigationTypes::BasicEnum& basicEnum) const { + return static_cast(basicEnum); + } + }; + //Hash for Settings + template<> + struct hash { + inline size_t operator()(const org::genivi::navigation::NavigationTypes::Settings& settings) const { + return static_cast(settings); + } + }; +} + +#endif // ORG_GENIVI_NAVIGATION_Navigation_Types_H_ diff --git a/api/franca/navigation/src-gen/org/genivi/navigation/poiservice/POIContentManager.h b/api/franca/navigation/src-gen/org/genivi/navigation/poiservice/POIContentManager.h new file mode 100644 index 0000000..0debe42 --- /dev/null +++ b/api/franca/navigation/src-gen/org/genivi/navigation/poiservice/POIContentManager.h @@ -0,0 +1,67 @@ +/* +* This file was generated by the CommonAPI Generators. +* Used org.genivi.commonapi.core 2.1.6.v20140519. +* Used org.franca.core 0.8.11.201401091023. +* +* 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 interface offers methods that implement the POI search functionality of a + * navigation system. + */ +#ifndef ORG_GENIVI_NAVIGATION_POISERVICE_POI_Content_Manager_H_ +#define ORG_GENIVI_NAVIGATION_POISERVICE_POI_Content_Manager_H_ + + + + +#if !defined (COMMONAPI_INTERNAL_COMPILATION) +#define COMMONAPI_INTERNAL_COMPILATION +#endif + +#include + +#undef COMMONAPI_INTERNAL_COMPILATION + +namespace org { +namespace genivi { +namespace navigation { +namespace poiservice { + +class POIContentManager { + public: + virtual ~POIContentManager() { } + + static inline const char* getInterfaceId(); + static inline CommonAPI::Version getInterfaceVersion(); +}; + +const char* POIContentManager::getInterfaceId() { + static const char* interfaceId = "org.genivi.navigation.poiservice.POIContentManager"; + return interfaceId; +} + +CommonAPI::Version POIContentManager::getInterfaceVersion() { + return CommonAPI::Version(1, 0); +} + + +} // namespace poiservice +} // namespace navigation +} // namespace genivi +} // namespace org + +namespace CommonAPI { + +} + + +namespace std { + //hashes for types + + //hashes for error types +} + +#endif // ORG_GENIVI_NAVIGATION_POISERVICE_POI_Content_Manager_H_ diff --git a/api/franca/navigation/src-gen/org/genivi/navigation/poiservice/POIContentManagerDBusProxy.cpp b/api/franca/navigation/src-gen/org/genivi/navigation/poiservice/POIContentManagerDBusProxy.cpp new file mode 100644 index 0000000..d401748 --- /dev/null +++ b/api/franca/navigation/src-gen/org/genivi/navigation/poiservice/POIContentManagerDBusProxy.cpp @@ -0,0 +1,437 @@ +/* +* This file was generated by the CommonAPI Generators. +* Used org.genivi.commonapi.core 2.1.6.v20140519. +* Used org.franca.core 0.8.11.201401091023. +* +* 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 interface offers methods that implement the POI search functionality of a + * navigation system. + */ +#include "POIContentManagerDBusProxy.h" + +namespace org { +namespace genivi { +namespace navigation { +namespace poiservice { + +std::shared_ptr createPOIContentManagerDBusProxy( + const std::shared_ptr& factory, + const std::string& commonApiAddress, + const std::string& interfaceName, + const std::string& busName, + const std::string& objectPath, + const std::shared_ptr& dbusProxyConnection) { + return std::make_shared(factory, commonApiAddress, interfaceName, busName, objectPath, dbusProxyConnection); +} + +INITIALIZER(registerPOIContentManagerDBusProxy) { + CommonAPI::DBus::DBusFactory::registerProxyFactoryMethod(POIContentManager::getInterfaceId(), + &createPOIContentManagerDBusProxy); +} + +POIContentManagerDBusProxy::POIContentManagerDBusProxy( + const std::shared_ptr& factory, + const std::string& commonApiAddress, + const std::string& interfaceName, + const std::string& busName, + const std::string& objectPath, + const std::shared_ptr& dbusProxyconnection): + CommonAPI::DBus::DBusProxy(factory, commonApiAddress, interfaceName, busName, objectPath, dbusProxyconnection) +, configurationChanged_(*this, "ConfigurationChanged", "aq"), + categoriesRemoved_(*this, "CategoriesRemoved", "au"), + pOIAdded_(*this, "POIAdded", "au"), + pOIRemoved_(*this, "POIRemoved", "au") + { + } + + +POIContentManagerDBusProxy::ConfigurationChangedEvent& POIContentManagerDBusProxy::getConfigurationChangedEvent() { + return configurationChanged_; +} +POIContentManagerDBusProxy::CategoriesRemovedEvent& POIContentManagerDBusProxy::getCategoriesRemovedEvent() { + return categoriesRemoved_; +} +POIContentManagerDBusProxy::POIAddedEvent& POIContentManagerDBusProxy::getPOIAddedEvent() { + return pOIAdded_; +} +POIContentManagerDBusProxy::POIRemovedEvent& POIContentManagerDBusProxy::getPOIRemovedEvent() { + return pOIRemoved_; +} + +/** + * This method returns the API version implemented by the content access module. + */ +void POIContentManagerDBusProxy::getVersion(CommonAPI::CallStatus& callStatus, NavigationTypes::Version& version) { + CommonAPI::DBus::DBusProxyHelper, + CommonAPI::DBus::DBusSerializableArguments >::callMethodWithReply( + *this, + "getVersion", + "", + callStatus + , version); +} +std::future POIContentManagerDBusProxy::getVersionAsync(GetVersionAsyncCallback callback) { + return CommonAPI::DBus::DBusProxyHelper, + CommonAPI::DBus::DBusSerializableArguments >::callMethodAsync( + *this, + "getVersion", + "", + std::move(callback)); +} +/** + * Set the current language set for the search by poi provider module. + + * The language defines the poi and categories name and details language. If the + * language is not supported, the default details will be returned in the native + * language. + */ +void POIContentManagerDBusProxy::setLocale(const std::string& languageCode, const std::string& countryCode, const std::string& scriptCode, CommonAPI::CallStatus& callStatus) { + CommonAPI::DBus::DBusProxyHelper, + CommonAPI::DBus::DBusSerializableArguments<> >::callMethodWithReply( + *this, + "setLocale", + "sss", + languageCode, countryCode, scriptCode, + callStatus + ); +} +std::future POIContentManagerDBusProxy::setLocaleAsync(const std::string& languageCode, const std::string& countryCode, const std::string& scriptCode, SetLocaleAsyncCallback callback) { + return CommonAPI::DBus::DBusProxyHelper, + CommonAPI::DBus::DBusSerializableArguments<> >::callMethodAsync( + *this, + "setLocale", + "sss", + languageCode, countryCode, scriptCode, + std::move(callback)); +} +/** + * Get the current language set for the search by poi provider module. + */ +void POIContentManagerDBusProxy::getLocale(CommonAPI::CallStatus& callStatus, std::string& languageCode, std::string& countryCode, std::string& scriptCode) { + CommonAPI::DBus::DBusProxyHelper, + CommonAPI::DBus::DBusSerializableArguments >::callMethodWithReply( + *this, + "getLocale", + "", + callStatus + , languageCode, countryCode, scriptCode); +} +std::future POIContentManagerDBusProxy::getLocaleAsync(GetLocaleAsyncCallback callback) { + return CommonAPI::DBus::DBusProxyHelper, + CommonAPI::DBus::DBusSerializableArguments >::callMethodAsync( + *this, + "getLocale", + "", + std::move(callback)); +} +/** + * Get the supported set of locales for the search by poi provider module. + */ +void POIContentManagerDBusProxy::getSupportedLocales(CommonAPI::CallStatus& callStatus, std::vector& localeList) { + CommonAPI::DBus::DBusProxyHelper, + CommonAPI::DBus::DBusSerializableArguments> >::callMethodWithReply( + *this, + "getSupportedLocales", + "", + callStatus + , localeList); +} +std::future POIContentManagerDBusProxy::getSupportedLocalesAsync(GetSupportedLocalesAsyncCallback callback) { + return CommonAPI::DBus::DBusProxyHelper, + CommonAPI::DBus::DBusSerializableArguments> >::callMethodAsync( + *this, + "getSupportedLocales", + "", + std::move(callback)); +} +/** + * This method retrieves the list od POI categories available (pre-defined and + * custom). + */ +void POIContentManagerDBusProxy::getAvailableCategories(CommonAPI::CallStatus& callStatus, std::vector& categories) { + CommonAPI::DBus::DBusProxyHelper, + CommonAPI::DBus::DBusSerializableArguments> >::callMethodWithReply( + *this, + "getAvailableCategories", + "", + callStatus + , categories); +} +std::future POIContentManagerDBusProxy::getAvailableCategoriesAsync(GetAvailableCategoriesAsyncCallback callback) { + return CommonAPI::DBus::DBusProxyHelper, + CommonAPI::DBus::DBusSerializableArguments> >::callMethodAsync( + *this, + "getAvailableCategories", + "", + std::move(callback)); +} +/** + * Get the root category id. That would be ALL_CATEGORIES. + */ +void POIContentManagerDBusProxy::getRootCategory(CommonAPI::CallStatus& callStatus, POIServiceTypes::CategoryID& category) { + CommonAPI::DBus::DBusProxyHelper, + CommonAPI::DBus::DBusSerializableArguments >::callMethodWithReply( + *this, + "getRootCategory", + "", + callStatus + , category); +} +std::future POIContentManagerDBusProxy::getRootCategoryAsync(GetRootCategoryAsyncCallback callback) { + return CommonAPI::DBus::DBusProxyHelper, + CommonAPI::DBus::DBusSerializableArguments >::callMethodAsync( + *this, + "getRootCategory", + "", + std::move(callback)); +} +/** + * Get the children categories id and type (top level) from the a parent unique id. + */ +void POIContentManagerDBusProxy::getChildrenCategories(const POIServiceTypes::CategoryID& category, CommonAPI::CallStatus& callStatus, std::vector& categories) { + CommonAPI::DBus::DBusProxyHelper, + CommonAPI::DBus::DBusSerializableArguments> >::callMethodWithReply( + *this, + "getChildrenCategories", + "u", + category, + callStatus + , categories); +} +std::future POIContentManagerDBusProxy::getChildrenCategoriesAsync(const POIServiceTypes::CategoryID& category, GetChildrenCategoriesAsyncCallback callback) { + return CommonAPI::DBus::DBusProxyHelper, + CommonAPI::DBus::DBusSerializableArguments> >::callMethodAsync( + *this, + "getChildrenCategories", + "u", + category, + std::move(callback)); +} +/** + * Get the parent categories id and type (top level) from the a unique id. + */ +void POIContentManagerDBusProxy::getParentCategories(const POIServiceTypes::CategoryID& category, CommonAPI::CallStatus& callStatus, std::vector& categories) { + CommonAPI::DBus::DBusProxyHelper, + CommonAPI::DBus::DBusSerializableArguments> >::callMethodWithReply( + *this, + "getParentCategories", + "u", + category, + callStatus + , categories); +} +std::future POIContentManagerDBusProxy::getParentCategoriesAsync(const POIServiceTypes::CategoryID& category, GetParentCategoriesAsyncCallback callback) { + return CommonAPI::DBus::DBusProxyHelper, + CommonAPI::DBus::DBusSerializableArguments> >::callMethodAsync( + *this, + "getParentCategories", + "u", + category, + std::move(callback)); +} +/** + * Creates a category by name and return an unique id. + */ +void POIContentManagerDBusProxy::createCategory(const POIServiceTypes::CAMCategory& category, CommonAPI::CallStatus& callStatus, POIServiceTypes::CategoryID& unique_id) { + CommonAPI::DBus::DBusProxyHelper, + CommonAPI::DBus::DBusSerializableArguments >::callMethodWithReply( + *this, + "createCategory", + "((au(yv)ss(yv))a(usia(is(yv)))a(us))", + category, + callStatus + , unique_id); +} +std::future POIContentManagerDBusProxy::createCategoryAsync(const POIServiceTypes::CAMCategory& category, CreateCategoryAsyncCallback callback) { + return CommonAPI::DBus::DBusProxyHelper, + CommonAPI::DBus::DBusSerializableArguments >::callMethodAsync( + *this, + "createCategory", + "((au(yv)ss(yv))a(usia(is(yv)))a(us))", + category, + std::move(callback)); +} +/** + * Removes a list of categories. Because of required time to remove it from the + * database, a signal is emitted when the deletion is done. + */ +void POIContentManagerDBusProxy::removeCategories(const std::vector& categories, CommonAPI::CallStatus& callStatus) { + CommonAPI::DBus::DBusProxyHelper>, + CommonAPI::DBus::DBusSerializableArguments<> >::callMethodWithReply( + *this, + "removeCategories", + "au", + categories, + callStatus + ); +} +std::future POIContentManagerDBusProxy::removeCategoriesAsync(const std::vector& categories, RemoveCategoriesAsyncCallback callback) { + return CommonAPI::DBus::DBusProxyHelper>, + CommonAPI::DBus::DBusSerializableArguments<> >::callMethodAsync( + *this, + "removeCategories", + "au", + categories, + std::move(callback)); +} +/** + * Adds a list of POIs to a category. Because of required time to add it to the + * database, a signal is emitted when the update is done, that gives the id of + * the elements added + */ +void POIContentManagerDBusProxy::addPOIs(const POIServiceTypes::CategoryID& unique_id, const std::vector& poiList, CommonAPI::CallStatus& callStatus) { + CommonAPI::DBus::DBusProxyHelper>, + CommonAPI::DBus::DBusSerializableArguments<> >::callMethodWithReply( + *this, + "addPOIs", + "ua(s(ddi)a(ui(yv)))", + unique_id, poiList, + callStatus + ); +} +std::future POIContentManagerDBusProxy::addPOIsAsync(const POIServiceTypes::CategoryID& unique_id, const std::vector& poiList, AddPOIsAsyncCallback callback) { + return CommonAPI::DBus::DBusProxyHelper>, + CommonAPI::DBus::DBusSerializableArguments<> >::callMethodAsync( + *this, + "addPOIs", + "ua(s(ddi)a(ui(yv)))", + unique_id, poiList, + std::move(callback)); +} +/** + * Removes a list of POIs to a category. Because of required time to remove it + * from the database, a signal is emitted when the update is done. + */ +void POIContentManagerDBusProxy::removePOIs(const std::vector& ids, CommonAPI::CallStatus& callStatus) { + CommonAPI::DBus::DBusProxyHelper>, + CommonAPI::DBus::DBusSerializableArguments<> >::callMethodWithReply( + *this, + "removePOIs", + "au", + ids, + callStatus + ); +} +std::future POIContentManagerDBusProxy::removePOIsAsync(const std::vector& ids, RemovePOIsAsyncCallback callback) { + return CommonAPI::DBus::DBusProxyHelper>, + CommonAPI::DBus::DBusSerializableArguments<> >::callMethodAsync( + *this, + "removePOIs", + "au", + ids, + std::move(callback)); +} +/** + * This method is sent by the POI service component to inform all the CAM that a + * new POI search was started. + It provides all the relevant search + * parameters. Of course the CAM will only be aware of the search if it registers + * one of the search categories. + */ +void POIContentManagerDBusProxy::poiSearchStarted(const NavigationTypes::Handle& poiSearchHandle, const uint16_t& maxSize, const NavigationTypes::Coordinate3D& location, const std::vector& poiCategories, const std::vector& poiAttributes, const std::string& inputString, const uint16_t& sortOption, CommonAPI::CallStatus& callStatus) { + CommonAPI::DBus::DBusProxyHelper, std::vector, std::string, uint16_t>, + CommonAPI::DBus::DBusSerializableArguments<> >::callMethodWithReply( + *this, + "poiSearchStarted", + "uq(ddi)a(uu)a(uui(yv)ib)sq", + poiSearchHandle, maxSize, location, poiCategories, poiAttributes, inputString, sortOption, + callStatus + ); +} +std::future POIContentManagerDBusProxy::poiSearchStartedAsync(const NavigationTypes::Handle& poiSearchHandle, const uint16_t& maxSize, const NavigationTypes::Coordinate3D& location, const std::vector& poiCategories, const std::vector& poiAttributes, const std::string& inputString, const uint16_t& sortOption, PoiSearchStartedAsyncCallback callback) { + return CommonAPI::DBus::DBusProxyHelper, std::vector, std::string, uint16_t>, + CommonAPI::DBus::DBusSerializableArguments<> >::callMethodAsync( + *this, + "poiSearchStarted", + "uq(ddi)a(uu)a(uui(yv)ib)sq", + poiSearchHandle, maxSize, location, poiCategories, poiAttributes, inputString, sortOption, + std::move(callback)); +} +/** + * This method cancels the search for the current id. + */ +void POIContentManagerDBusProxy::poiSearchCanceled(const NavigationTypes::Handle& poiSearchHandle, CommonAPI::CallStatus& callStatus) { + CommonAPI::DBus::DBusProxyHelper, + CommonAPI::DBus::DBusSerializableArguments<> >::callMethodWithReply( + *this, + "poiSearchCanceled", + "u", + poiSearchHandle, + callStatus + ); +} +std::future POIContentManagerDBusProxy::poiSearchCanceledAsync(const NavigationTypes::Handle& poiSearchHandle, PoiSearchCanceledAsyncCallback callback) { + return CommonAPI::DBus::DBusProxyHelper, + CommonAPI::DBus::DBusSerializableArguments<> >::callMethodAsync( + *this, + "poiSearchCanceled", + "u", + poiSearchHandle, + std::move(callback)); +} +/** + * This method provides the poi results list found by the CAM. + As the POI + * unique id is managed by the POI component, the CAM only provides the POI name, + * the category and coordinates as well as all the relevant detailed information. + */ +void POIContentManagerDBusProxy::resultListRequested(const uint8_t& camId, const NavigationTypes::Handle& poiSearchHandle, const std::vector& attributes, CommonAPI::CallStatus& callStatus, POIServiceTypes::SearchStatusState& statusValue, uint16_t& resultListSize, std::vector& resultList) { + CommonAPI::DBus::DBusProxyHelper>, + CommonAPI::DBus::DBusSerializableArguments> >::callMethodWithReply( + *this, + "resultListRequested", + "yuau", + camId, poiSearchHandle, attributes, + callStatus + , statusValue, resultListSize, resultList); +} +std::future POIContentManagerDBusProxy::resultListRequestedAsync(const uint8_t& camId, const NavigationTypes::Handle& poiSearchHandle, const std::vector& attributes, ResultListRequestedAsyncCallback callback) { + return CommonAPI::DBus::DBusProxyHelper>, + CommonAPI::DBus::DBusSerializableArguments> >::callMethodAsync( + *this, + "resultListRequested", + "yuau", + camId, poiSearchHandle, attributes, + std::move(callback)); +} +/** + * This method retrieves the details associated to one or more POI. + It + * contains the name, the parent categories, the list of attributes, the icons, + * ... . + */ +void POIContentManagerDBusProxy::poiDetailsRequested(const std::vector& source_id, CommonAPI::CallStatus& callStatus, std::vector& results) { + CommonAPI::DBus::DBusProxyHelper>, + CommonAPI::DBus::DBusSerializableArguments> >::callMethodWithReply( + *this, + "poiDetailsRequested", + "au", + source_id, + callStatus + , results); +} +std::future POIContentManagerDBusProxy::poiDetailsRequestedAsync(const std::vector& source_id, PoiDetailsRequestedAsyncCallback callback) { + return CommonAPI::DBus::DBusProxyHelper>, + CommonAPI::DBus::DBusSerializableArguments> >::callMethodAsync( + *this, + "poiDetailsRequested", + "au", + source_id, + std::move(callback)); +} + + + +void POIContentManagerDBusProxy::getOwnVersion(uint16_t& ownVersionMajor, uint16_t& ownVersionMinor) const { + ownVersionMajor = 1; + ownVersionMinor = 0; +} + +} // namespace poiservice +} // namespace navigation +} // namespace genivi +} // namespace org diff --git a/api/franca/navigation/src-gen/org/genivi/navigation/poiservice/POIContentManagerDBusProxy.h b/api/franca/navigation/src-gen/org/genivi/navigation/poiservice/POIContentManagerDBusProxy.h new file mode 100644 index 0000000..de06d31 --- /dev/null +++ b/api/franca/navigation/src-gen/org/genivi/navigation/poiservice/POIContentManagerDBusProxy.h @@ -0,0 +1,173 @@ +/* +* This file was generated by the CommonAPI Generators. +* Used org.genivi.commonapi.core 2.1.6.v20140519. +* Used org.franca.core 0.8.11.201401091023. +* +* 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 interface offers methods that implement the POI search functionality of a + * navigation system. + */ +#ifndef ORG_GENIVI_NAVIGATION_POISERVICE_POI_Content_Manager_DBUS_PROXY_H_ +#define ORG_GENIVI_NAVIGATION_POISERVICE_POI_Content_Manager_DBUS_PROXY_H_ + +#include + +#if !defined (COMMONAPI_INTERNAL_COMPILATION) +#define COMMONAPI_INTERNAL_COMPILATION +#endif + +#include +#include +#include + +#undef COMMONAPI_INTERNAL_COMPILATION + +#include + +namespace org { +namespace genivi { +namespace navigation { +namespace poiservice { + +class POIContentManagerDBusProxy: virtual public POIContentManagerProxyBase, virtual public CommonAPI::DBus::DBusProxy { + public: + POIContentManagerDBusProxy( + const std::shared_ptr& factory, + const std::string& commonApiAddress, + const std::string& interfaceName, + const std::string& busName, + const std::string& objectPath, + const std::shared_ptr& dbusProxyconnection); + + virtual ~POIContentManagerDBusProxy() { } + + + virtual ConfigurationChangedEvent& getConfigurationChangedEvent(); + virtual CategoriesRemovedEvent& getCategoriesRemovedEvent(); + virtual POIAddedEvent& getPOIAddedEvent(); + virtual POIRemovedEvent& getPOIRemovedEvent(); + + /** + * This method returns the API version implemented by the content access module. + */ + virtual void getVersion(CommonAPI::CallStatus& callStatus, NavigationTypes::Version& version); + virtual std::future getVersionAsync(GetVersionAsyncCallback callback); + /** + * Set the current language set for the search by poi provider module. + + * The language defines the poi and categories name and details language. If the + * language is not supported, the default details will be returned in the native + * language. + */ + virtual void setLocale(const std::string& languageCode, const std::string& countryCode, const std::string& scriptCode, CommonAPI::CallStatus& callStatus); + virtual std::future setLocaleAsync(const std::string& languageCode, const std::string& countryCode, const std::string& scriptCode, SetLocaleAsyncCallback callback); + /** + * Get the current language set for the search by poi provider module. + */ + virtual void getLocale(CommonAPI::CallStatus& callStatus, std::string& languageCode, std::string& countryCode, std::string& scriptCode); + virtual std::future getLocaleAsync(GetLocaleAsyncCallback callback); + /** + * Get the supported set of locales for the search by poi provider module. + */ + virtual void getSupportedLocales(CommonAPI::CallStatus& callStatus, std::vector& localeList); + virtual std::future getSupportedLocalesAsync(GetSupportedLocalesAsyncCallback callback); + /** + * This method retrieves the list od POI categories available (pre-defined and + * custom). + */ + virtual void getAvailableCategories(CommonAPI::CallStatus& callStatus, std::vector& categories); + virtual std::future getAvailableCategoriesAsync(GetAvailableCategoriesAsyncCallback callback); + /** + * Get the root category id. That would be ALL_CATEGORIES. + */ + virtual void getRootCategory(CommonAPI::CallStatus& callStatus, POIServiceTypes::CategoryID& category); + virtual std::future getRootCategoryAsync(GetRootCategoryAsyncCallback callback); + /** + * Get the children categories id and type (top level) from the a parent unique id. + */ + virtual void getChildrenCategories(const POIServiceTypes::CategoryID& category, CommonAPI::CallStatus& callStatus, std::vector& categories); + virtual std::future getChildrenCategoriesAsync(const POIServiceTypes::CategoryID& category, GetChildrenCategoriesAsyncCallback callback); + /** + * Get the parent categories id and type (top level) from the a unique id. + */ + virtual void getParentCategories(const POIServiceTypes::CategoryID& category, CommonAPI::CallStatus& callStatus, std::vector& categories); + virtual std::future getParentCategoriesAsync(const POIServiceTypes::CategoryID& category, GetParentCategoriesAsyncCallback callback); + /** + * Creates a category by name and return an unique id. + */ + virtual void createCategory(const POIServiceTypes::CAMCategory& category, CommonAPI::CallStatus& callStatus, POIServiceTypes::CategoryID& unique_id); + virtual std::future createCategoryAsync(const POIServiceTypes::CAMCategory& category, CreateCategoryAsyncCallback callback); + /** + * Removes a list of categories. Because of required time to remove it from the + * database, a signal is emitted when the deletion is done. + */ + virtual void removeCategories(const std::vector& categories, CommonAPI::CallStatus& callStatus); + virtual std::future removeCategoriesAsync(const std::vector& categories, RemoveCategoriesAsyncCallback callback); + /** + * Adds a list of POIs to a category. Because of required time to add it to the + * database, a signal is emitted when the update is done, that gives the id of + * the elements added + */ + virtual void addPOIs(const POIServiceTypes::CategoryID& unique_id, const std::vector& poiList, CommonAPI::CallStatus& callStatus); + virtual std::future addPOIsAsync(const POIServiceTypes::CategoryID& unique_id, const std::vector& poiList, AddPOIsAsyncCallback callback); + /** + * Removes a list of POIs to a category. Because of required time to remove it + * from the database, a signal is emitted when the update is done. + */ + virtual void removePOIs(const std::vector& ids, CommonAPI::CallStatus& callStatus); + virtual std::future removePOIsAsync(const std::vector& ids, RemovePOIsAsyncCallback callback); + /** + * This method is sent by the POI service component to inform all the CAM that a + * new POI search was started. + It provides all the relevant search + * parameters. Of course the CAM will only be aware of the search if it registers + * one of the search categories. + */ + virtual void poiSearchStarted(const NavigationTypes::Handle& poiSearchHandle, const uint16_t& maxSize, const NavigationTypes::Coordinate3D& location, const std::vector& poiCategories, const std::vector& poiAttributes, const std::string& inputString, const uint16_t& sortOption, CommonAPI::CallStatus& callStatus); + virtual std::future poiSearchStartedAsync(const NavigationTypes::Handle& poiSearchHandle, const uint16_t& maxSize, const NavigationTypes::Coordinate3D& location, const std::vector& poiCategories, const std::vector& poiAttributes, const std::string& inputString, const uint16_t& sortOption, PoiSearchStartedAsyncCallback callback); + /** + * This method cancels the search for the current id. + */ + virtual void poiSearchCanceled(const NavigationTypes::Handle& poiSearchHandle, CommonAPI::CallStatus& callStatus); + virtual std::future poiSearchCanceledAsync(const NavigationTypes::Handle& poiSearchHandle, PoiSearchCanceledAsyncCallback callback); + /** + * This method provides the poi results list found by the CAM. + As the POI + * unique id is managed by the POI component, the CAM only provides the POI name, + * the category and coordinates as well as all the relevant detailed information. + */ + virtual void resultListRequested(const uint8_t& camId, const NavigationTypes::Handle& poiSearchHandle, const std::vector& attributes, CommonAPI::CallStatus& callStatus, POIServiceTypes::SearchStatusState& statusValue, uint16_t& resultListSize, std::vector& resultList); + virtual std::future resultListRequestedAsync(const uint8_t& camId, const NavigationTypes::Handle& poiSearchHandle, const std::vector& attributes, ResultListRequestedAsyncCallback callback); + /** + * This method retrieves the details associated to one or more POI. + It + * contains the name, the parent categories, the list of attributes, the icons, + * ... . + */ + virtual void poiDetailsRequested(const std::vector& source_id, CommonAPI::CallStatus& callStatus, std::vector& results); + virtual std::future poiDetailsRequestedAsync(const std::vector& source_id, PoiDetailsRequestedAsyncCallback callback); + + + virtual void getOwnVersion(uint16_t& ownVersionMajor, uint16_t& ownVersionMinor) const; + + private: + + CommonAPI::DBus::DBusEvent configurationChanged_; + CommonAPI::DBus::DBusEvent categoriesRemoved_; + CommonAPI::DBus::DBusEvent pOIAdded_; + CommonAPI::DBus::DBusEvent pOIRemoved_; + +}; + + + +} // namespace poiservice +} // namespace navigation +} // namespace genivi +} // namespace org + +#endif // ORG_GENIVI_NAVIGATION_POISERVICE_POI_Content_Manager_DBUS_PROXY_H_ diff --git a/api/franca/navigation/src-gen/org/genivi/navigation/poiservice/POIContentManagerDBusStubAdapter.cpp b/api/franca/navigation/src-gen/org/genivi/navigation/poiservice/POIContentManagerDBusStubAdapter.cpp new file mode 100644 index 0000000..d5a4da3 --- /dev/null +++ b/api/franca/navigation/src-gen/org/genivi/navigation/poiservice/POIContentManagerDBusStubAdapter.cpp @@ -0,0 +1,559 @@ +/* +* This file was generated by the CommonAPI Generators. +* Used org.genivi.commonapi.core 2.1.6.v20140519. +* Used org.franca.core 0.8.11.201401091023. +* +* 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 "POIContentManagerDBusStubAdapter.h" +#include + +namespace org { +namespace genivi { +namespace navigation { +namespace poiservice { + +std::shared_ptr createPOIContentManagerDBusStubAdapter( + const std::shared_ptr& factory, + const std::string& commonApiAddress, + const std::string& interfaceName, + const std::string& busName, + const std::string& objectPath, + const std::shared_ptr& dbusProxyConnection, + const std::shared_ptr& stubBase) { + return std::make_shared(factory, commonApiAddress, interfaceName, busName, objectPath, dbusProxyConnection, stubBase); +} + +INITIALIZER(registerPOIContentManagerDBusStubAdapter) { + CommonAPI::DBus::DBusFactory::registerAdapterFactoryMethod(POIContentManager::getInterfaceId(), + &createPOIContentManagerDBusStubAdapter); +} + + + +POIContentManagerDBusStubAdapterInternal::~POIContentManagerDBusStubAdapterInternal() { + deactivateManagedInstances(); + POIContentManagerDBusStubAdapterHelper::deinit(); +} + +void POIContentManagerDBusStubAdapterInternal::deactivateManagedInstances() { + +} + +const char* POIContentManagerDBusStubAdapterInternal::getMethodsDBusIntrospectionXmlData() const { + static const std::string introspectionData = + "\n" + "" + "\n" + /** + * guidanceStatusChanged = This signal is sent to the clients when one or more + * configuration settings changes. + */ + "\n" + "\n" + "\n" + /** + * CategoriesRemoved = This signal is emitted when a list of categories and + * associated content has been removed from the database. + */ + "\n" + "\n" + "\n" + /** + * POIAdded = This signal is emitted when a list of POIs and associated content + * has been added to the database. It returns the ids. + */ + "\n" + "\n" + "\n" + /** + * POIRemoved = This signal is emitted when a list of POIs and associated content + * has been removed from the database. + */ + "\n" + "\n" + "\n" + /** + * This method returns the API version implemented by the content access module. + */ + "\n" + "\n" + "\n" + /** + * Set the current language set for the search by poi provider module. + + * The language defines the poi and categories name and details language. If the + * language is not supported, the default details will be returned in the native + * language. + */ + "\n" + "\n" + "\n" + "\n" + "\n" + /** + * Get the current language set for the search by poi provider module. + */ + "\n" + "\n" + "\n" + "\n" + "\n" + /** + * Get the supported set of locales for the search by poi provider module. + */ + "\n" + "\n" + "\n" + /** + * This method retrieves the list od POI categories available (pre-defined and + * custom). + */ + "\n" + "\n" + "\n" + /** + * Get the root category id. That would be ALL_CATEGORIES. + */ + "\n" + "\n" + "\n" + /** + * Get the children categories id and type (top level) from the a parent unique id. + */ + "\n" + "\n" + "\n" + "\n" + /** + * Get the parent categories id and type (top level) from the a unique id. + */ + "\n" + "\n" + "\n" + "\n" + /** + * Creates a category by name and return an unique id. + */ + "\n" + "\n" + "\n" + "\n" + /** + * Removes a list of categories. Because of required time to remove it from the + * database, a signal is emitted when the deletion is done. + */ + "\n" + "\n" + "\n" + /** + * Adds a list of POIs to a category. Because of required time to add it to the + * database, a signal is emitted when the update is done, that gives the id of + * the elements added + */ + "\n" + "\n" + "\n" + "\n" + /** + * Removes a list of POIs to a category. Because of required time to remove it + * from the database, a signal is emitted when the update is done. + */ + "\n" + "\n" + "\n" + /** + * This method is sent by the POI service component to inform all the CAM that a + * new POI search was started. + It provides all the relevant search + * parameters. Of course the CAM will only be aware of the search if it registers + * one of the search categories. + */ + "\n" + "\n" + "\n" + "\n" + "\n" + "\n" + "\n" + "\n" + "\n" + /** + * This method cancels the search for the current id. + */ + "\n" + "\n" + "\n" + /** + * This method provides the poi results list found by the CAM. + As the POI + * unique id is managed by the POI component, the CAM only provides the POI name, + * the category and coordinates as well as all the relevant detailed information. + */ + "\n" + "\n" + "\n" + "\n" + "\n" + "\n" + "\n" + "\n" + /** + * This method retrieves the details associated to one or more POI. + It + * contains the name, the parent categories, the list of attributes, the icons, + * ... . + */ + "\n" + "\n" + "\n" + "\n" + + ; + return introspectionData.c_str(); +} + +CommonAPI::DBus::DBusGetAttributeStubDispatcher< + POIContentManagerStub, + CommonAPI::Version + > POIContentManagerDBusStubAdapterInternal::getPOIContentManagerInterfaceVersionStubDispatcher(&POIContentManagerStub::getInterfaceVersion, "uu"); + + + +/** + * This method returns the API version implemented by the content access module. + */ +CommonAPI::DBus::DBusMethodWithReplyStubDispatcher< + POIContentManagerStub, + std::tuple<>, + std::tuple + > POIContentManagerDBusStubAdapterInternal::getVersionStubDispatcher(&POIContentManagerStub::getVersion, "(qqqs)"); +/** + * Set the current language set for the search by poi provider module. + + * The language defines the poi and categories name and details language. If the + * language is not supported, the default details will be returned in the native + * language. + */ +CommonAPI::DBus::DBusMethodWithReplyStubDispatcher< + POIContentManagerStub, + std::tuple, + std::tuple<> + > POIContentManagerDBusStubAdapterInternal::setLocaleStubDispatcher(&POIContentManagerStub::setLocale, ""); +/** + * Get the current language set for the search by poi provider module. + */ +CommonAPI::DBus::DBusMethodWithReplyStubDispatcher< + POIContentManagerStub, + std::tuple<>, + std::tuple + > POIContentManagerDBusStubAdapterInternal::getLocaleStubDispatcher(&POIContentManagerStub::getLocale, "sss"); +/** + * Get the supported set of locales for the search by poi provider module. + */ +CommonAPI::DBus::DBusMethodWithReplyStubDispatcher< + POIContentManagerStub, + std::tuple<>, + std::tuple> + > POIContentManagerDBusStubAdapterInternal::getSupportedLocalesStubDispatcher(&POIContentManagerStub::getSupportedLocales, "a(sss)"); +/** + * This method retrieves the list od POI categories available (pre-defined and + * custom). + */ +CommonAPI::DBus::DBusMethodWithReplyStubDispatcher< + POIContentManagerStub, + std::tuple<>, + std::tuple> + > POIContentManagerDBusStubAdapterInternal::getAvailableCategoriesStubDispatcher(&POIContentManagerStub::getAvailableCategories, "a(usb)"); +/** + * Get the root category id. That would be ALL_CATEGORIES. + */ +CommonAPI::DBus::DBusMethodWithReplyStubDispatcher< + POIContentManagerStub, + std::tuple<>, + std::tuple + > POIContentManagerDBusStubAdapterInternal::getRootCategoryStubDispatcher(&POIContentManagerStub::getRootCategory, "u"); +/** + * Get the children categories id and type (top level) from the a parent unique id. + */ +CommonAPI::DBus::DBusMethodWithReplyStubDispatcher< + POIContentManagerStub, + std::tuple, + std::tuple> + > POIContentManagerDBusStubAdapterInternal::getChildrenCategoriesStubDispatcher(&POIContentManagerStub::getChildrenCategories, "a(ub)"); +/** + * Get the parent categories id and type (top level) from the a unique id. + */ +CommonAPI::DBus::DBusMethodWithReplyStubDispatcher< + POIContentManagerStub, + std::tuple, + std::tuple> + > POIContentManagerDBusStubAdapterInternal::getParentCategoriesStubDispatcher(&POIContentManagerStub::getParentCategories, "a(ub)"); +/** + * Creates a category by name and return an unique id. + */ +CommonAPI::DBus::DBusMethodWithReplyStubDispatcher< + POIContentManagerStub, + std::tuple, + std::tuple + > POIContentManagerDBusStubAdapterInternal::createCategoryStubDispatcher(&POIContentManagerStub::createCategory, "u"); +/** + * Removes a list of categories. Because of required time to remove it from the + * database, a signal is emitted when the deletion is done. + */ +CommonAPI::DBus::DBusMethodWithReplyStubDispatcher< + POIContentManagerStub, + std::tuple>, + std::tuple<> + > POIContentManagerDBusStubAdapterInternal::removeCategoriesStubDispatcher(&POIContentManagerStub::removeCategories, ""); +/** + * Adds a list of POIs to a category. Because of required time to add it to the + * database, a signal is emitted when the update is done, that gives the id of + * the elements added + */ +CommonAPI::DBus::DBusMethodWithReplyStubDispatcher< + POIContentManagerStub, + std::tuple>, + std::tuple<> + > POIContentManagerDBusStubAdapterInternal::addPOIsStubDispatcher(&POIContentManagerStub::addPOIs, ""); +/** + * Removes a list of POIs to a category. Because of required time to remove it + * from the database, a signal is emitted when the update is done. + */ +CommonAPI::DBus::DBusMethodWithReplyStubDispatcher< + POIContentManagerStub, + std::tuple>, + std::tuple<> + > POIContentManagerDBusStubAdapterInternal::removePOIsStubDispatcher(&POIContentManagerStub::removePOIs, ""); +/** + * This method is sent by the POI service component to inform all the CAM that a + * new POI search was started. + It provides all the relevant search + * parameters. Of course the CAM will only be aware of the search if it registers + * one of the search categories. + */ +CommonAPI::DBus::DBusMethodWithReplyStubDispatcher< + POIContentManagerStub, + std::tuple, std::vector, std::string, uint16_t>, + std::tuple<> + > POIContentManagerDBusStubAdapterInternal::poiSearchStartedStubDispatcher(&POIContentManagerStub::poiSearchStarted, ""); +/** + * This method cancels the search for the current id. + */ +CommonAPI::DBus::DBusMethodWithReplyStubDispatcher< + POIContentManagerStub, + std::tuple, + std::tuple<> + > POIContentManagerDBusStubAdapterInternal::poiSearchCanceledStubDispatcher(&POIContentManagerStub::poiSearchCanceled, ""); +/** + * This method provides the poi results list found by the CAM. + As the POI + * unique id is managed by the POI component, the CAM only provides the POI name, + * the category and coordinates as well as all the relevant detailed information. + */ +CommonAPI::DBus::DBusMethodWithReplyStubDispatcher< + POIContentManagerStub, + std::tuple>, + std::tuple> + > POIContentManagerDBusStubAdapterInternal::resultListRequestedStubDispatcher(&POIContentManagerStub::resultListRequested, "iqa(usu(ddi)qa(ui(yv)))"); +/** + * This method retrieves the details associated to one or more POI. + It + * contains the name, the parent categories, the list of attributes, the icons, + * ... . + */ +CommonAPI::DBus::DBusMethodWithReplyStubDispatcher< + POIContentManagerStub, + std::tuple>, + std::tuple> + > POIContentManagerDBusStubAdapterInternal::poiDetailsRequestedStubDispatcher(&POIContentManagerStub::poiDetailsRequested, "a((us(ddi))aua(ui(yv)))"); + + + +/** + * guidanceStatusChanged = This signal is sent to the clients when one or more + * configuration settings changes. + */ +void POIContentManagerDBusStubAdapterInternal::fireConfigurationChangedEvent(const std::vector& changedSettings) { + CommonAPI::DBus::DBusStubSignalHelper>> + ::sendSignal( + *this, + "ConfigurationChanged", + "aq", + changedSettings + ); +} +/** + * CategoriesRemoved = This signal is emitted when a list of categories and + * associated content has been removed from the database. + */ +void POIContentManagerDBusStubAdapterInternal::fireCategoriesRemovedEvent(const std::vector& categories) { + CommonAPI::DBus::DBusStubSignalHelper>> + ::sendSignal( + *this, + "CategoriesRemoved", + "au", + categories + ); +} +/** + * POIAdded = This signal is emitted when a list of POIs and associated content + * has been added to the database. It returns the ids. + */ +void POIContentManagerDBusStubAdapterInternal::firePOIAddedEvent(const std::vector& pois) { + CommonAPI::DBus::DBusStubSignalHelper>> + ::sendSignal( + *this, + "POIAdded", + "au", + pois + ); +} +/** + * POIRemoved = This signal is emitted when a list of POIs and associated content + * has been removed from the database. + */ +void POIContentManagerDBusStubAdapterInternal::firePOIRemovedEvent(const std::vector& pois) { + CommonAPI::DBus::DBusStubSignalHelper>> + ::sendSignal( + *this, + "POIRemoved", + "au", + pois + ); +} + + +const POIContentManagerDBusStubAdapterHelper::StubDispatcherTable& POIContentManagerDBusStubAdapterInternal::getStubDispatcherTable() { + return stubDispatcherTable_; +} + +const CommonAPI::DBus::StubAttributeTable& POIContentManagerDBusStubAdapterInternal::getStubAttributeTable() { + return stubAttributeTable_; +} + +POIContentManagerDBusStubAdapterInternal::POIContentManagerDBusStubAdapterInternal( + const std::shared_ptr& factory, + const std::string& commonApiAddress, + const std::string& dbusInterfaceName, + const std::string& dbusBusName, + const std::string& dbusObjectPath, + const std::shared_ptr& dbusConnection, + const std::shared_ptr& stub): + CommonAPI::DBus::DBusStubAdapter( + factory, + commonApiAddress, + dbusInterfaceName, + dbusBusName, + dbusObjectPath, + dbusConnection, + false), + POIContentManagerDBusStubAdapterHelper( + factory, + commonApiAddress, + dbusInterfaceName, + dbusBusName, + dbusObjectPath, + dbusConnection, + std::dynamic_pointer_cast(stub), + false), + stubDispatcherTable_({ + /** + * This method returns the API version implemented by the content access module. + */ + { { "getVersion", "" }, &org::genivi::navigation::poiservice::POIContentManagerDBusStubAdapterInternal::getVersionStubDispatcher }, + /** + * Set the current language set for the search by poi provider module. + + * The language defines the poi and categories name and details language. If the + * language is not supported, the default details will be returned in the native + * language. + */ + { { "setLocale", "sss" }, &org::genivi::navigation::poiservice::POIContentManagerDBusStubAdapterInternal::setLocaleStubDispatcher }, + /** + * Get the current language set for the search by poi provider module. + */ + { { "getLocale", "" }, &org::genivi::navigation::poiservice::POIContentManagerDBusStubAdapterInternal::getLocaleStubDispatcher }, + /** + * Get the supported set of locales for the search by poi provider module. + */ + { { "getSupportedLocales", "" }, &org::genivi::navigation::poiservice::POIContentManagerDBusStubAdapterInternal::getSupportedLocalesStubDispatcher }, + /** + * This method retrieves the list od POI categories available (pre-defined and + * custom). + */ + { { "getAvailableCategories", "" }, &org::genivi::navigation::poiservice::POIContentManagerDBusStubAdapterInternal::getAvailableCategoriesStubDispatcher }, + /** + * Get the root category id. That would be ALL_CATEGORIES. + */ + { { "getRootCategory", "" }, &org::genivi::navigation::poiservice::POIContentManagerDBusStubAdapterInternal::getRootCategoryStubDispatcher }, + /** + * Get the children categories id and type (top level) from the a parent unique id. + */ + { { "getChildrenCategories", "u" }, &org::genivi::navigation::poiservice::POIContentManagerDBusStubAdapterInternal::getChildrenCategoriesStubDispatcher }, + /** + * Get the parent categories id and type (top level) from the a unique id. + */ + { { "getParentCategories", "u" }, &org::genivi::navigation::poiservice::POIContentManagerDBusStubAdapterInternal::getParentCategoriesStubDispatcher }, + /** + * Creates a category by name and return an unique id. + */ + { { "createCategory", "((au(yv)ss(yv))a(usia(is(yv)))a(us))" }, &org::genivi::navigation::poiservice::POIContentManagerDBusStubAdapterInternal::createCategoryStubDispatcher }, + /** + * Removes a list of categories. Because of required time to remove it from the + * database, a signal is emitted when the deletion is done. + */ + { { "removeCategories", "au" }, &org::genivi::navigation::poiservice::POIContentManagerDBusStubAdapterInternal::removeCategoriesStubDispatcher }, + /** + * Adds a list of POIs to a category. Because of required time to add it to the + * database, a signal is emitted when the update is done, that gives the id of + * the elements added + */ + { { "addPOIs", "ua(s(ddi)a(ui(yv)))" }, &org::genivi::navigation::poiservice::POIContentManagerDBusStubAdapterInternal::addPOIsStubDispatcher }, + /** + * Removes a list of POIs to a category. Because of required time to remove it + * from the database, a signal is emitted when the update is done. + */ + { { "removePOIs", "au" }, &org::genivi::navigation::poiservice::POIContentManagerDBusStubAdapterInternal::removePOIsStubDispatcher }, + /** + * This method is sent by the POI service component to inform all the CAM that a + * new POI search was started. + It provides all the relevant search + * parameters. Of course the CAM will only be aware of the search if it registers + * one of the search categories. + */ + { { "poiSearchStarted", "uq(ddi)a(uu)a(uui(yv)ib)sq" }, &org::genivi::navigation::poiservice::POIContentManagerDBusStubAdapterInternal::poiSearchStartedStubDispatcher }, + /** + * This method cancels the search for the current id. + */ + { { "poiSearchCanceled", "u" }, &org::genivi::navigation::poiservice::POIContentManagerDBusStubAdapterInternal::poiSearchCanceledStubDispatcher }, + /** + * This method provides the poi results list found by the CAM. + As the POI + * unique id is managed by the POI component, the CAM only provides the POI name, + * the category and coordinates as well as all the relevant detailed information. + */ + { { "resultListRequested", "yuau" }, &org::genivi::navigation::poiservice::POIContentManagerDBusStubAdapterInternal::resultListRequestedStubDispatcher }, + /** + * This method retrieves the details associated to one or more POI. + It + * contains the name, the parent categories, the list of attributes, the icons, + * ... . + */ + { { "poiDetailsRequested", "au" }, &org::genivi::navigation::poiservice::POIContentManagerDBusStubAdapterInternal::poiDetailsRequestedStubDispatcher } + }), + stubAttributeTable_() { + + stubDispatcherTable_.insert({ { "getInterfaceVersion", "" }, &org::genivi::navigation::poiservice::POIContentManagerDBusStubAdapterInternal::getPOIContentManagerInterfaceVersionStubDispatcher }); +} + +const bool POIContentManagerDBusStubAdapterInternal::hasFreedesktopProperties() { + return false; +} + +} // namespace poiservice +} // namespace navigation +} // namespace genivi +} // namespace org diff --git a/api/franca/navigation/src-gen/org/genivi/navigation/poiservice/POIContentManagerDBusStubAdapter.h b/api/franca/navigation/src-gen/org/genivi/navigation/poiservice/POIContentManagerDBusStubAdapter.h new file mode 100644 index 0000000..1d9efb7 --- /dev/null +++ b/api/franca/navigation/src-gen/org/genivi/navigation/poiservice/POIContentManagerDBusStubAdapter.h @@ -0,0 +1,280 @@ +/* +* This file was generated by the CommonAPI Generators. +* Used org.genivi.commonapi.core 2.1.6.v20140519. +* Used org.franca.core 0.8.11.201401091023. +* +* 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 interface offers methods that implement the POI search functionality of a + * navigation system. + */ +#ifndef ORG_GENIVI_NAVIGATION_POISERVICE_POI_Content_Manager_DBUS_STUB_ADAPTER_H_ +#define ORG_GENIVI_NAVIGATION_POISERVICE_POI_Content_Manager_DBUS_STUB_ADAPTER_H_ + +#include + +#if !defined (COMMONAPI_INTERNAL_COMPILATION) +#define COMMONAPI_INTERNAL_COMPILATION +#endif + +#include +#include +#include +#include + +#undef COMMONAPI_INTERNAL_COMPILATION + +namespace org { +namespace genivi { +namespace navigation { +namespace poiservice { + +typedef CommonAPI::DBus::DBusStubAdapterHelper POIContentManagerDBusStubAdapterHelper; + +class POIContentManagerDBusStubAdapterInternal: public virtual POIContentManagerStubAdapter, public POIContentManagerDBusStubAdapterHelper { + public: + POIContentManagerDBusStubAdapterInternal( + const std::shared_ptr& factory, + const std::string& commonApiAddress, + const std::string& dbusInterfaceName, + const std::string& dbusBusName, + const std::string& dbusObjectPath, + const std::shared_ptr& dbusConnection, + const std::shared_ptr& stub); + + ~POIContentManagerDBusStubAdapterInternal(); + + virtual const bool hasFreedesktopProperties(); + + + /** + * guidanceStatusChanged = This signal is sent to the clients when one or more + * configuration settings changes. + */ + void fireConfigurationChangedEvent(const std::vector& changedSettings); + /** + * CategoriesRemoved = This signal is emitted when a list of categories and + * associated content has been removed from the database. + */ + void fireCategoriesRemovedEvent(const std::vector& categories); + /** + * POIAdded = This signal is emitted when a list of POIs and associated content + * has been added to the database. It returns the ids. + */ + void firePOIAddedEvent(const std::vector& pois); + /** + * POIRemoved = This signal is emitted when a list of POIs and associated content + * has been removed from the database. + */ + void firePOIRemovedEvent(const std::vector& pois); + + + const POIContentManagerDBusStubAdapterHelper::StubDispatcherTable& getStubDispatcherTable(); + const CommonAPI::DBus::StubAttributeTable& getStubAttributeTable(); + + void deactivateManagedInstances(); + + +static CommonAPI::DBus::DBusGetAttributeStubDispatcher< + POIContentManagerStub, + CommonAPI::Version + > getPOIContentManagerInterfaceVersionStubDispatcher; + + + +/** + * This method returns the API version implemented by the content access module. + */ +static CommonAPI::DBus::DBusMethodWithReplyStubDispatcher< + POIContentManagerStub, + std::tuple<>, + std::tuple + > getVersionStubDispatcher; +/** + * Set the current language set for the search by poi provider module. + + * The language defines the poi and categories name and details language. If the + * language is not supported, the default details will be returned in the native + * language. + */ +static CommonAPI::DBus::DBusMethodWithReplyStubDispatcher< + POIContentManagerStub, + std::tuple, + std::tuple<> + > setLocaleStubDispatcher; +/** + * Get the current language set for the search by poi provider module. + */ +static CommonAPI::DBus::DBusMethodWithReplyStubDispatcher< + POIContentManagerStub, + std::tuple<>, + std::tuple + > getLocaleStubDispatcher; +/** + * Get the supported set of locales for the search by poi provider module. + */ +static CommonAPI::DBus::DBusMethodWithReplyStubDispatcher< + POIContentManagerStub, + std::tuple<>, + std::tuple> + > getSupportedLocalesStubDispatcher; +/** + * This method retrieves the list od POI categories available (pre-defined and + * custom). + */ +static CommonAPI::DBus::DBusMethodWithReplyStubDispatcher< + POIContentManagerStub, + std::tuple<>, + std::tuple> + > getAvailableCategoriesStubDispatcher; +/** + * Get the root category id. That would be ALL_CATEGORIES. + */ +static CommonAPI::DBus::DBusMethodWithReplyStubDispatcher< + POIContentManagerStub, + std::tuple<>, + std::tuple + > getRootCategoryStubDispatcher; +/** + * Get the children categories id and type (top level) from the a parent unique id. + */ +static CommonAPI::DBus::DBusMethodWithReplyStubDispatcher< + POIContentManagerStub, + std::tuple, + std::tuple> + > getChildrenCategoriesStubDispatcher; +/** + * Get the parent categories id and type (top level) from the a unique id. + */ +static CommonAPI::DBus::DBusMethodWithReplyStubDispatcher< + POIContentManagerStub, + std::tuple, + std::tuple> + > getParentCategoriesStubDispatcher; +/** + * Creates a category by name and return an unique id. + */ +static CommonAPI::DBus::DBusMethodWithReplyStubDispatcher< + POIContentManagerStub, + std::tuple, + std::tuple + > createCategoryStubDispatcher; +/** + * Removes a list of categories. Because of required time to remove it from the + * database, a signal is emitted when the deletion is done. + */ +static CommonAPI::DBus::DBusMethodWithReplyStubDispatcher< + POIContentManagerStub, + std::tuple>, + std::tuple<> + > removeCategoriesStubDispatcher; +/** + * Adds a list of POIs to a category. Because of required time to add it to the + * database, a signal is emitted when the update is done, that gives the id of + * the elements added + */ +static CommonAPI::DBus::DBusMethodWithReplyStubDispatcher< + POIContentManagerStub, + std::tuple>, + std::tuple<> + > addPOIsStubDispatcher; +/** + * Removes a list of POIs to a category. Because of required time to remove it + * from the database, a signal is emitted when the update is done. + */ +static CommonAPI::DBus::DBusMethodWithReplyStubDispatcher< + POIContentManagerStub, + std::tuple>, + std::tuple<> + > removePOIsStubDispatcher; +/** + * This method is sent by the POI service component to inform all the CAM that a + * new POI search was started. + It provides all the relevant search + * parameters. Of course the CAM will only be aware of the search if it registers + * one of the search categories. + */ +static CommonAPI::DBus::DBusMethodWithReplyStubDispatcher< + POIContentManagerStub, + std::tuple, std::vector, std::string, uint16_t>, + std::tuple<> + > poiSearchStartedStubDispatcher; +/** + * This method cancels the search for the current id. + */ +static CommonAPI::DBus::DBusMethodWithReplyStubDispatcher< + POIContentManagerStub, + std::tuple, + std::tuple<> + > poiSearchCanceledStubDispatcher; +/** + * This method provides the poi results list found by the CAM. + As the POI + * unique id is managed by the POI component, the CAM only provides the POI name, + * the category and coordinates as well as all the relevant detailed information. + */ +static CommonAPI::DBus::DBusMethodWithReplyStubDispatcher< + POIContentManagerStub, + std::tuple>, + std::tuple> + > resultListRequestedStubDispatcher; +/** + * This method retrieves the details associated to one or more POI. + It + * contains the name, the parent categories, the list of attributes, the icons, + * ... . + */ +static CommonAPI::DBus::DBusMethodWithReplyStubDispatcher< + POIContentManagerStub, + std::tuple>, + std::tuple> + > poiDetailsRequestedStubDispatcher; + + + + + protected: + virtual const char* getMethodsDBusIntrospectionXmlData() const; + + private: + POIContentManagerDBusStubAdapterHelper::StubDispatcherTable stubDispatcherTable_; + CommonAPI::DBus::StubAttributeTable stubAttributeTable_; +}; + +class POIContentManagerDBusStubAdapter: public POIContentManagerDBusStubAdapterInternal, public std::enable_shared_from_this { +public: + POIContentManagerDBusStubAdapter( + const std::shared_ptr& factory, + const std::string& commonApiAddress, + const std::string& dbusInterfaceName, + const std::string& dbusBusName, + const std::string& dbusObjectPath, + const std::shared_ptr& dbusConnection, + const std::shared_ptr& stub) : + CommonAPI::DBus::DBusStubAdapter( + factory, + commonApiAddress, + dbusInterfaceName, + dbusBusName, + dbusObjectPath, + dbusConnection, + false), + POIContentManagerDBusStubAdapterInternal( + factory, + commonApiAddress, + dbusInterfaceName, + dbusBusName, + dbusObjectPath, + dbusConnection, + stub) { } +}; + +} // namespace poiservice +} // namespace navigation +} // namespace genivi +} // namespace org + +#endif // ORG_GENIVI_NAVIGATION_POISERVICE_POI_Content_Manager_DBUS_STUB_ADAPTER_H_ diff --git a/api/franca/navigation/src-gen/org/genivi/navigation/poiservice/POIContentManagerProxy.h b/api/franca/navigation/src-gen/org/genivi/navigation/poiservice/POIContentManagerProxy.h new file mode 100644 index 0000000..f58324c --- /dev/null +++ b/api/franca/navigation/src-gen/org/genivi/navigation/poiservice/POIContentManagerProxy.h @@ -0,0 +1,787 @@ +/* +* This file was generated by the CommonAPI Generators. +* Used org.genivi.commonapi.core 2.1.6.v20140519. +* Used org.franca.core 0.8.11.201401091023. +* +* 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 interface offers methods that implement the POI search functionality of a + * navigation system. + */ +#ifndef ORG_GENIVI_NAVIGATION_POISERVICE_POI_Content_Manager_PROXY_H_ +#define ORG_GENIVI_NAVIGATION_POISERVICE_POI_Content_Manager_PROXY_H_ + +#include "POIContentManagerProxyBase.h" + + +#if !defined (COMMONAPI_INTERNAL_COMPILATION) +#define COMMONAPI_INTERNAL_COMPILATION +#endif + + +#undef COMMONAPI_INTERNAL_COMPILATION + +namespace org { +namespace genivi { +namespace navigation { +namespace poiservice { + +template +class POIContentManagerProxy: virtual public POIContentManager, virtual public POIContentManagerProxyBase +, public _AttributeExtensions... { +public: + POIContentManagerProxy(std::shared_ptr delegate); + ~POIContentManagerProxy(); + + typedef POIContentManager InterfaceType; + + + + /** + * guidanceStatusChanged = This signal is sent to the clients when one or more + * configuration settings changes. + */ + /** + * Returns the wrapper class that provides access to the broadcast ConfigurationChanged. + */ + virtual ConfigurationChangedEvent& getConfigurationChangedEvent() { + return delegate_->getConfigurationChangedEvent(); + } + /** + * CategoriesRemoved = This signal is emitted when a list of categories and + * associated content has been removed from the database. + */ + /** + * Returns the wrapper class that provides access to the broadcast CategoriesRemoved. + */ + virtual CategoriesRemovedEvent& getCategoriesRemovedEvent() { + return delegate_->getCategoriesRemovedEvent(); + } + /** + * POIAdded = This signal is emitted when a list of POIs and associated content + * has been added to the database. It returns the ids. + */ + /** + * Returns the wrapper class that provides access to the broadcast POIAdded. + */ + virtual POIAddedEvent& getPOIAddedEvent() { + return delegate_->getPOIAddedEvent(); + } + /** + * POIRemoved = This signal is emitted when a list of POIs and associated content + * has been removed from the database. + */ + /** + * Returns the wrapper class that provides access to the broadcast POIRemoved. + */ + virtual POIRemovedEvent& getPOIRemovedEvent() { + return delegate_->getPOIRemovedEvent(); + } + + /** + * This method returns the API version implemented by the content access module. + * + * Calls getVersion with synchronous semantics. + * + * All non-const parameters will be filled with the returned values. + * The CallStatus will be filled when the method returns and indicate either + * "SUCCESS" or which type of error has occurred. In case of an error, ONLY the CallStatus + * will be set. + */ + virtual void getVersion(CommonAPI::CallStatus& callStatus, NavigationTypes::Version& version); + /** + * Calls getVersion with asynchronous semantics. + * + * The provided callback will be called when the reply to this call arrives or + * an error occurs during the call. The CallStatus will indicate either "SUCCESS" + * or which type of error has occurred. In case of any error, ONLY the CallStatus + * will have a defined value. + * The std::future returned by this method will be fulfilled at arrival of the reply. + * It will provide the same value for CallStatus as will be handed to the callback. + */ + virtual std::future getVersionAsync(GetVersionAsyncCallback callback); + /** + * Set the current language set for the search by poi provider module. + + * The language defines the poi and categories name and details language. If the + * language is not supported, the default details will be returned in the native + * language. + * + * Calls setLocale with synchronous semantics. + * + * All const parameters are input parameters to this method. + * The CallStatus will be filled when the method returns and indicate either + * "SUCCESS" or which type of error has occurred. In case of an error, ONLY the CallStatus + * will be set. + */ + virtual void setLocale(const std::string& languageCode, const std::string& countryCode, const std::string& scriptCode, CommonAPI::CallStatus& callStatus); + /** + * Calls setLocale with asynchronous semantics. + * + * The provided callback will be called when the reply to this call arrives or + * an error occurs during the call. The CallStatus will indicate either "SUCCESS" + * or which type of error has occurred. In case of any error, ONLY the CallStatus + * will have a defined value. + * The std::future returned by this method will be fulfilled at arrival of the reply. + * It will provide the same value for CallStatus as will be handed to the callback. + */ + virtual std::future setLocaleAsync(const std::string& languageCode, const std::string& countryCode, const std::string& scriptCode, SetLocaleAsyncCallback callback); + /** + * Get the current language set for the search by poi provider module. + * + * Calls getLocale with synchronous semantics. + * + * All non-const parameters will be filled with the returned values. + * The CallStatus will be filled when the method returns and indicate either + * "SUCCESS" or which type of error has occurred. In case of an error, ONLY the CallStatus + * will be set. + */ + virtual void getLocale(CommonAPI::CallStatus& callStatus, std::string& languageCode, std::string& countryCode, std::string& scriptCode); + /** + * Calls getLocale with asynchronous semantics. + * + * The provided callback will be called when the reply to this call arrives or + * an error occurs during the call. The CallStatus will indicate either "SUCCESS" + * or which type of error has occurred. In case of any error, ONLY the CallStatus + * will have a defined value. + * The std::future returned by this method will be fulfilled at arrival of the reply. + * It will provide the same value for CallStatus as will be handed to the callback. + */ + virtual std::future getLocaleAsync(GetLocaleAsyncCallback callback); + /** + * Get the supported set of locales for the search by poi provider module. + * + * Calls getSupportedLocales with synchronous semantics. + * + * All non-const parameters will be filled with the returned values. + * The CallStatus will be filled when the method returns and indicate either + * "SUCCESS" or which type of error has occurred. In case of an error, ONLY the CallStatus + * will be set. + */ + virtual void getSupportedLocales(CommonAPI::CallStatus& callStatus, std::vector& localeList); + /** + * Calls getSupportedLocales with asynchronous semantics. + * + * The provided callback will be called when the reply to this call arrives or + * an error occurs during the call. The CallStatus will indicate either "SUCCESS" + * or which type of error has occurred. In case of any error, ONLY the CallStatus + * will have a defined value. + * The std::future returned by this method will be fulfilled at arrival of the reply. + * It will provide the same value for CallStatus as will be handed to the callback. + */ + virtual std::future getSupportedLocalesAsync(GetSupportedLocalesAsyncCallback callback); + /** + * This method retrieves the list od POI categories available (pre-defined and + * custom). + * + * Calls getAvailableCategories with synchronous semantics. + * + * All non-const parameters will be filled with the returned values. + * The CallStatus will be filled when the method returns and indicate either + * "SUCCESS" or which type of error has occurred. In case of an error, ONLY the CallStatus + * will be set. + */ + virtual void getAvailableCategories(CommonAPI::CallStatus& callStatus, std::vector& categories); + /** + * Calls getAvailableCategories with asynchronous semantics. + * + * The provided callback will be called when the reply to this call arrives or + * an error occurs during the call. The CallStatus will indicate either "SUCCESS" + * or which type of error has occurred. In case of any error, ONLY the CallStatus + * will have a defined value. + * The std::future returned by this method will be fulfilled at arrival of the reply. + * It will provide the same value for CallStatus as will be handed to the callback. + */ + virtual std::future getAvailableCategoriesAsync(GetAvailableCategoriesAsyncCallback callback); + /** + * Get the root category id. That would be ALL_CATEGORIES. + * + * Calls getRootCategory with synchronous semantics. + * + * All non-const parameters will be filled with the returned values. + * The CallStatus will be filled when the method returns and indicate either + * "SUCCESS" or which type of error has occurred. In case of an error, ONLY the CallStatus + * will be set. + */ + virtual void getRootCategory(CommonAPI::CallStatus& callStatus, POIServiceTypes::CategoryID& category); + /** + * Calls getRootCategory with asynchronous semantics. + * + * The provided callback will be called when the reply to this call arrives or + * an error occurs during the call. The CallStatus will indicate either "SUCCESS" + * or which type of error has occurred. In case of any error, ONLY the CallStatus + * will have a defined value. + * The std::future returned by this method will be fulfilled at arrival of the reply. + * It will provide the same value for CallStatus as will be handed to the callback. + */ + virtual std::future getRootCategoryAsync(GetRootCategoryAsyncCallback callback); + /** + * Get the children categories id and type (top level) from the a parent unique id. + * + * Calls getChildrenCategories with synchronous semantics. + * + * All const parameters are input parameters to this method. + * All non-const parameters will be filled with the returned values. + * The CallStatus will be filled when the method returns and indicate either + * "SUCCESS" or which type of error has occurred. In case of an error, ONLY the CallStatus + * will be set. + */ + virtual void getChildrenCategories(const POIServiceTypes::CategoryID& category, CommonAPI::CallStatus& callStatus, std::vector& categories); + /** + * Calls getChildrenCategories with asynchronous semantics. + * + * The provided callback will be called when the reply to this call arrives or + * an error occurs during the call. The CallStatus will indicate either "SUCCESS" + * or which type of error has occurred. In case of any error, ONLY the CallStatus + * will have a defined value. + * The std::future returned by this method will be fulfilled at arrival of the reply. + * It will provide the same value for CallStatus as will be handed to the callback. + */ + virtual std::future getChildrenCategoriesAsync(const POIServiceTypes::CategoryID& category, GetChildrenCategoriesAsyncCallback callback); + /** + * Get the parent categories id and type (top level) from the a unique id. + * + * Calls getParentCategories with synchronous semantics. + * + * All const parameters are input parameters to this method. + * All non-const parameters will be filled with the returned values. + * The CallStatus will be filled when the method returns and indicate either + * "SUCCESS" or which type of error has occurred. In case of an error, ONLY the CallStatus + * will be set. + */ + virtual void getParentCategories(const POIServiceTypes::CategoryID& category, CommonAPI::CallStatus& callStatus, std::vector& categories); + /** + * Calls getParentCategories with asynchronous semantics. + * + * The provided callback will be called when the reply to this call arrives or + * an error occurs during the call. The CallStatus will indicate either "SUCCESS" + * or which type of error has occurred. In case of any error, ONLY the CallStatus + * will have a defined value. + * The std::future returned by this method will be fulfilled at arrival of the reply. + * It will provide the same value for CallStatus as will be handed to the callback. + */ + virtual std::future getParentCategoriesAsync(const POIServiceTypes::CategoryID& category, GetParentCategoriesAsyncCallback callback); + /** + * Creates a category by name and return an unique id. + * + * Calls createCategory with synchronous semantics. + * + * All const parameters are input parameters to this method. + * All non-const parameters will be filled with the returned values. + * The CallStatus will be filled when the method returns and indicate either + * "SUCCESS" or which type of error has occurred. In case of an error, ONLY the CallStatus + * will be set. + */ + virtual void createCategory(const POIServiceTypes::CAMCategory& category, CommonAPI::CallStatus& callStatus, POIServiceTypes::CategoryID& unique_id); + /** + * Calls createCategory with asynchronous semantics. + * + * The provided callback will be called when the reply to this call arrives or + * an error occurs during the call. The CallStatus will indicate either "SUCCESS" + * or which type of error has occurred. In case of any error, ONLY the CallStatus + * will have a defined value. + * The std::future returned by this method will be fulfilled at arrival of the reply. + * It will provide the same value for CallStatus as will be handed to the callback. + */ + virtual std::future createCategoryAsync(const POIServiceTypes::CAMCategory& category, CreateCategoryAsyncCallback callback); + /** + * Removes a list of categories. Because of required time to remove it from the + * database, a signal is emitted when the deletion is done. + * + * Calls removeCategories with synchronous semantics. + * + * All const parameters are input parameters to this method. + * The CallStatus will be filled when the method returns and indicate either + * "SUCCESS" or which type of error has occurred. In case of an error, ONLY the CallStatus + * will be set. + */ + virtual void removeCategories(const std::vector& categories, CommonAPI::CallStatus& callStatus); + /** + * Calls removeCategories with asynchronous semantics. + * + * The provided callback will be called when the reply to this call arrives or + * an error occurs during the call. The CallStatus will indicate either "SUCCESS" + * or which type of error has occurred. In case of any error, ONLY the CallStatus + * will have a defined value. + * The std::future returned by this method will be fulfilled at arrival of the reply. + * It will provide the same value for CallStatus as will be handed to the callback. + */ + virtual std::future removeCategoriesAsync(const std::vector& categories, RemoveCategoriesAsyncCallback callback); + /** + * Adds a list of POIs to a category. Because of required time to add it to the + * database, a signal is emitted when the update is done, that gives the id of + * the elements added + * + * Calls addPOIs with synchronous semantics. + * + * All const parameters are input parameters to this method. + * The CallStatus will be filled when the method returns and indicate either + * "SUCCESS" or which type of error has occurred. In case of an error, ONLY the CallStatus + * will be set. + */ + virtual void addPOIs(const POIServiceTypes::CategoryID& unique_id, const std::vector& poiList, CommonAPI::CallStatus& callStatus); + /** + * Calls addPOIs with asynchronous semantics. + * + * The provided callback will be called when the reply to this call arrives or + * an error occurs during the call. The CallStatus will indicate either "SUCCESS" + * or which type of error has occurred. In case of any error, ONLY the CallStatus + * will have a defined value. + * The std::future returned by this method will be fulfilled at arrival of the reply. + * It will provide the same value for CallStatus as will be handed to the callback. + */ + virtual std::future addPOIsAsync(const POIServiceTypes::CategoryID& unique_id, const std::vector& poiList, AddPOIsAsyncCallback callback); + /** + * Removes a list of POIs to a category. Because of required time to remove it + * from the database, a signal is emitted when the update is done. + * + * Calls removePOIs with synchronous semantics. + * + * All const parameters are input parameters to this method. + * The CallStatus will be filled when the method returns and indicate either + * "SUCCESS" or which type of error has occurred. In case of an error, ONLY the CallStatus + * will be set. + */ + virtual void removePOIs(const std::vector& ids, CommonAPI::CallStatus& callStatus); + /** + * Calls removePOIs with asynchronous semantics. + * + * The provided callback will be called when the reply to this call arrives or + * an error occurs during the call. The CallStatus will indicate either "SUCCESS" + * or which type of error has occurred. In case of any error, ONLY the CallStatus + * will have a defined value. + * The std::future returned by this method will be fulfilled at arrival of the reply. + * It will provide the same value for CallStatus as will be handed to the callback. + */ + virtual std::future removePOIsAsync(const std::vector& ids, RemovePOIsAsyncCallback callback); + /** + * This method is sent by the POI service component to inform all the CAM that a + * new POI search was started. + It provides all the relevant search + * parameters. Of course the CAM will only be aware of the search if it registers + * one of the search categories. + * + * Calls poiSearchStarted with synchronous semantics. + * + * All const parameters are input parameters to this method. + * The CallStatus will be filled when the method returns and indicate either + * "SUCCESS" or which type of error has occurred. In case of an error, ONLY the CallStatus + * will be set. + */ + virtual void poiSearchStarted(const NavigationTypes::Handle& poiSearchHandle, const uint16_t& maxSize, const NavigationTypes::Coordinate3D& location, const std::vector& poiCategories, const std::vector& poiAttributes, const std::string& inputString, const uint16_t& sortOption, CommonAPI::CallStatus& callStatus); + /** + * Calls poiSearchStarted with asynchronous semantics. + * + * The provided callback will be called when the reply to this call arrives or + * an error occurs during the call. The CallStatus will indicate either "SUCCESS" + * or which type of error has occurred. In case of any error, ONLY the CallStatus + * will have a defined value. + * The std::future returned by this method will be fulfilled at arrival of the reply. + * It will provide the same value for CallStatus as will be handed to the callback. + */ + virtual std::future poiSearchStartedAsync(const NavigationTypes::Handle& poiSearchHandle, const uint16_t& maxSize, const NavigationTypes::Coordinate3D& location, const std::vector& poiCategories, const std::vector& poiAttributes, const std::string& inputString, const uint16_t& sortOption, PoiSearchStartedAsyncCallback callback); + /** + * This method cancels the search for the current id. + * + * Calls poiSearchCanceled with synchronous semantics. + * + * All const parameters are input parameters to this method. + * The CallStatus will be filled when the method returns and indicate either + * "SUCCESS" or which type of error has occurred. In case of an error, ONLY the CallStatus + * will be set. + */ + virtual void poiSearchCanceled(const NavigationTypes::Handle& poiSearchHandle, CommonAPI::CallStatus& callStatus); + /** + * Calls poiSearchCanceled with asynchronous semantics. + * + * The provided callback will be called when the reply to this call arrives or + * an error occurs during the call. The CallStatus will indicate either "SUCCESS" + * or which type of error has occurred. In case of any error, ONLY the CallStatus + * will have a defined value. + * The std::future returned by this method will be fulfilled at arrival of the reply. + * It will provide the same value for CallStatus as will be handed to the callback. + */ + virtual std::future poiSearchCanceledAsync(const NavigationTypes::Handle& poiSearchHandle, PoiSearchCanceledAsyncCallback callback); + /** + * This method provides the poi results list found by the CAM. + As the POI + * unique id is managed by the POI component, the CAM only provides the POI name, + * the category and coordinates as well as all the relevant detailed information. + * + * Calls resultListRequested with synchronous semantics. + * + * All const parameters are input parameters to this method. + * All non-const parameters will be filled with the returned values. + * The CallStatus will be filled when the method returns and indicate either + * "SUCCESS" or which type of error has occurred. In case of an error, ONLY the CallStatus + * will be set. + */ + virtual void resultListRequested(const uint8_t& camId, const NavigationTypes::Handle& poiSearchHandle, const std::vector& attributes, CommonAPI::CallStatus& callStatus, POIServiceTypes::SearchStatusState& statusValue, uint16_t& resultListSize, std::vector& resultList); + /** + * Calls resultListRequested with asynchronous semantics. + * + * The provided callback will be called when the reply to this call arrives or + * an error occurs during the call. The CallStatus will indicate either "SUCCESS" + * or which type of error has occurred. In case of any error, ONLY the CallStatus + * will have a defined value. + * The std::future returned by this method will be fulfilled at arrival of the reply. + * It will provide the same value for CallStatus as will be handed to the callback. + */ + virtual std::future resultListRequestedAsync(const uint8_t& camId, const NavigationTypes::Handle& poiSearchHandle, const std::vector& attributes, ResultListRequestedAsyncCallback callback); + /** + * This method retrieves the details associated to one or more POI. + It + * contains the name, the parent categories, the list of attributes, the icons, + * ... . + * + * Calls poiDetailsRequested with synchronous semantics. + * + * All const parameters are input parameters to this method. + * All non-const parameters will be filled with the returned values. + * The CallStatus will be filled when the method returns and indicate either + * "SUCCESS" or which type of error has occurred. In case of an error, ONLY the CallStatus + * will be set. + */ + virtual void poiDetailsRequested(const std::vector& source_id, CommonAPI::CallStatus& callStatus, std::vector& results); + /** + * Calls poiDetailsRequested with asynchronous semantics. + * + * The provided callback will be called when the reply to this call arrives or + * an error occurs during the call. The CallStatus will indicate either "SUCCESS" + * or which type of error has occurred. In case of any error, ONLY the CallStatus + * will have a defined value. + * The std::future returned by this method will be fulfilled at arrival of the reply. + * It will provide the same value for CallStatus as will be handed to the callback. + */ + virtual std::future poiDetailsRequestedAsync(const std::vector& source_id, PoiDetailsRequestedAsyncCallback callback); + + + /** + * Returns the CommonAPI address of the remote partner this proxy communicates with. + */ + virtual std::string getAddress() const; + + /** + * Returns the domain of the remote partner this proxy communicates with. + */ + virtual const std::string& getDomain() const; + + /** + * Returns the service ID of the remote partner this proxy communicates with. + */ + virtual const std::string& getServiceId() const; + + /** + * Returns the instance ID of the remote partner this proxy communicates with. + */ + virtual const std::string& getInstanceId() const; + + /** + * Returns true if the remote partner for this proxy is currently known to be available. + */ + virtual bool isAvailable() const; + + /** + * Returns true if the remote partner for this proxy is available. + */ + virtual bool isAvailableBlocking() const; + + /** + * Returns the wrapper class that is used to (de-)register for notifications about + * the availability of the remote partner of this proxy. + */ + virtual CommonAPI::ProxyStatusEvent& getProxyStatusEvent(); + + /** + * Returns the wrapper class that is used to access version information of the remote + * partner of this proxy. + */ + virtual CommonAPI::InterfaceVersionAttribute& getInterfaceVersionAttribute(); + + private: + std::shared_ptr delegate_; +}; + +#ifdef WIN32 + typedef POIContentManagerProxy> POIContentManagerProxyDefault; +#else + typedef POIContentManagerProxy<> POIContentManagerProxyDefault; +#endif + + +// +// POIContentManagerProxy Implementation +// +template +POIContentManagerProxy<_AttributeExtensions...>::POIContentManagerProxy(std::shared_ptr delegate): + _AttributeExtensions(*(std::dynamic_pointer_cast(delegate)))..., + delegate_(std::dynamic_pointer_cast(delegate)) { +} + +template +POIContentManagerProxy<_AttributeExtensions...>::~POIContentManagerProxy() { +} + +/** + * This method returns the API version implemented by the content access module. + */ +template +void POIContentManagerProxy<_AttributeExtensions...>::getVersion(CommonAPI::CallStatus& callStatus, NavigationTypes::Version& version) { + delegate_->getVersion(callStatus, version); +} + +template +std::future POIContentManagerProxy<_AttributeExtensions...>::getVersionAsync(GetVersionAsyncCallback callback) { + return delegate_->getVersionAsync(callback); +} +/** + * Set the current language set for the search by poi provider module. + + * The language defines the poi and categories name and details language. If the + * language is not supported, the default details will be returned in the native + * language. + */ +template +void POIContentManagerProxy<_AttributeExtensions...>::setLocale(const std::string& languageCode, const std::string& countryCode, const std::string& scriptCode, CommonAPI::CallStatus& callStatus) { + delegate_->setLocale(languageCode, countryCode, scriptCode, callStatus); +} + +template +std::future POIContentManagerProxy<_AttributeExtensions...>::setLocaleAsync(const std::string& languageCode, const std::string& countryCode, const std::string& scriptCode, SetLocaleAsyncCallback callback) { + return delegate_->setLocaleAsync(languageCode, countryCode, scriptCode, callback); +} +/** + * Get the current language set for the search by poi provider module. + */ +template +void POIContentManagerProxy<_AttributeExtensions...>::getLocale(CommonAPI::CallStatus& callStatus, std::string& languageCode, std::string& countryCode, std::string& scriptCode) { + delegate_->getLocale(callStatus, languageCode, countryCode, scriptCode); +} + +template +std::future POIContentManagerProxy<_AttributeExtensions...>::getLocaleAsync(GetLocaleAsyncCallback callback) { + return delegate_->getLocaleAsync(callback); +} +/** + * Get the supported set of locales for the search by poi provider module. + */ +template +void POIContentManagerProxy<_AttributeExtensions...>::getSupportedLocales(CommonAPI::CallStatus& callStatus, std::vector& localeList) { + delegate_->getSupportedLocales(callStatus, localeList); +} + +template +std::future POIContentManagerProxy<_AttributeExtensions...>::getSupportedLocalesAsync(GetSupportedLocalesAsyncCallback callback) { + return delegate_->getSupportedLocalesAsync(callback); +} +/** + * This method retrieves the list od POI categories available (pre-defined and + * custom). + */ +template +void POIContentManagerProxy<_AttributeExtensions...>::getAvailableCategories(CommonAPI::CallStatus& callStatus, std::vector& categories) { + delegate_->getAvailableCategories(callStatus, categories); +} + +template +std::future POIContentManagerProxy<_AttributeExtensions...>::getAvailableCategoriesAsync(GetAvailableCategoriesAsyncCallback callback) { + return delegate_->getAvailableCategoriesAsync(callback); +} +/** + * Get the root category id. That would be ALL_CATEGORIES. + */ +template +void POIContentManagerProxy<_AttributeExtensions...>::getRootCategory(CommonAPI::CallStatus& callStatus, POIServiceTypes::CategoryID& category) { + delegate_->getRootCategory(callStatus, category); +} + +template +std::future POIContentManagerProxy<_AttributeExtensions...>::getRootCategoryAsync(GetRootCategoryAsyncCallback callback) { + return delegate_->getRootCategoryAsync(callback); +} +/** + * Get the children categories id and type (top level) from the a parent unique id. + */ +template +void POIContentManagerProxy<_AttributeExtensions...>::getChildrenCategories(const POIServiceTypes::CategoryID& category, CommonAPI::CallStatus& callStatus, std::vector& categories) { + delegate_->getChildrenCategories(category, callStatus, categories); +} + +template +std::future POIContentManagerProxy<_AttributeExtensions...>::getChildrenCategoriesAsync(const POIServiceTypes::CategoryID& category, GetChildrenCategoriesAsyncCallback callback) { + return delegate_->getChildrenCategoriesAsync(category, callback); +} +/** + * Get the parent categories id and type (top level) from the a unique id. + */ +template +void POIContentManagerProxy<_AttributeExtensions...>::getParentCategories(const POIServiceTypes::CategoryID& category, CommonAPI::CallStatus& callStatus, std::vector& categories) { + delegate_->getParentCategories(category, callStatus, categories); +} + +template +std::future POIContentManagerProxy<_AttributeExtensions...>::getParentCategoriesAsync(const POIServiceTypes::CategoryID& category, GetParentCategoriesAsyncCallback callback) { + return delegate_->getParentCategoriesAsync(category, callback); +} +/** + * Creates a category by name and return an unique id. + */ +template +void POIContentManagerProxy<_AttributeExtensions...>::createCategory(const POIServiceTypes::CAMCategory& category, CommonAPI::CallStatus& callStatus, POIServiceTypes::CategoryID& unique_id) { + delegate_->createCategory(category, callStatus, unique_id); +} + +template +std::future POIContentManagerProxy<_AttributeExtensions...>::createCategoryAsync(const POIServiceTypes::CAMCategory& category, CreateCategoryAsyncCallback callback) { + return delegate_->createCategoryAsync(category, callback); +} +/** + * Removes a list of categories. Because of required time to remove it from the + * database, a signal is emitted when the deletion is done. + */ +template +void POIContentManagerProxy<_AttributeExtensions...>::removeCategories(const std::vector& categories, CommonAPI::CallStatus& callStatus) { + delegate_->removeCategories(categories, callStatus); +} + +template +std::future POIContentManagerProxy<_AttributeExtensions...>::removeCategoriesAsync(const std::vector& categories, RemoveCategoriesAsyncCallback callback) { + return delegate_->removeCategoriesAsync(categories, callback); +} +/** + * Adds a list of POIs to a category. Because of required time to add it to the + * database, a signal is emitted when the update is done, that gives the id of + * the elements added + */ +template +void POIContentManagerProxy<_AttributeExtensions...>::addPOIs(const POIServiceTypes::CategoryID& unique_id, const std::vector& poiList, CommonAPI::CallStatus& callStatus) { + delegate_->addPOIs(unique_id, poiList, callStatus); +} + +template +std::future POIContentManagerProxy<_AttributeExtensions...>::addPOIsAsync(const POIServiceTypes::CategoryID& unique_id, const std::vector& poiList, AddPOIsAsyncCallback callback) { + return delegate_->addPOIsAsync(unique_id, poiList, callback); +} +/** + * Removes a list of POIs to a category. Because of required time to remove it + * from the database, a signal is emitted when the update is done. + */ +template +void POIContentManagerProxy<_AttributeExtensions...>::removePOIs(const std::vector& ids, CommonAPI::CallStatus& callStatus) { + delegate_->removePOIs(ids, callStatus); +} + +template +std::future POIContentManagerProxy<_AttributeExtensions...>::removePOIsAsync(const std::vector& ids, RemovePOIsAsyncCallback callback) { + return delegate_->removePOIsAsync(ids, callback); +} +/** + * This method is sent by the POI service component to inform all the CAM that a + * new POI search was started. + It provides all the relevant search + * parameters. Of course the CAM will only be aware of the search if it registers + * one of the search categories. + */ +template +void POIContentManagerProxy<_AttributeExtensions...>::poiSearchStarted(const NavigationTypes::Handle& poiSearchHandle, const uint16_t& maxSize, const NavigationTypes::Coordinate3D& location, const std::vector& poiCategories, const std::vector& poiAttributes, const std::string& inputString, const uint16_t& sortOption, CommonAPI::CallStatus& callStatus) { + delegate_->poiSearchStarted(poiSearchHandle, maxSize, location, poiCategories, poiAttributes, inputString, sortOption, callStatus); +} + +template +std::future POIContentManagerProxy<_AttributeExtensions...>::poiSearchStartedAsync(const NavigationTypes::Handle& poiSearchHandle, const uint16_t& maxSize, const NavigationTypes::Coordinate3D& location, const std::vector& poiCategories, const std::vector& poiAttributes, const std::string& inputString, const uint16_t& sortOption, PoiSearchStartedAsyncCallback callback) { + return delegate_->poiSearchStartedAsync(poiSearchHandle, maxSize, location, poiCategories, poiAttributes, inputString, sortOption, callback); +} +/** + * This method cancels the search for the current id. + */ +template +void POIContentManagerProxy<_AttributeExtensions...>::poiSearchCanceled(const NavigationTypes::Handle& poiSearchHandle, CommonAPI::CallStatus& callStatus) { + delegate_->poiSearchCanceled(poiSearchHandle, callStatus); +} + +template +std::future POIContentManagerProxy<_AttributeExtensions...>::poiSearchCanceledAsync(const NavigationTypes::Handle& poiSearchHandle, PoiSearchCanceledAsyncCallback callback) { + return delegate_->poiSearchCanceledAsync(poiSearchHandle, callback); +} +/** + * This method provides the poi results list found by the CAM. + As the POI + * unique id is managed by the POI component, the CAM only provides the POI name, + * the category and coordinates as well as all the relevant detailed information. + */ +template +void POIContentManagerProxy<_AttributeExtensions...>::resultListRequested(const uint8_t& camId, const NavigationTypes::Handle& poiSearchHandle, const std::vector& attributes, CommonAPI::CallStatus& callStatus, POIServiceTypes::SearchStatusState& statusValue, uint16_t& resultListSize, std::vector& resultList) { + delegate_->resultListRequested(camId, poiSearchHandle, attributes, callStatus, statusValue, resultListSize, resultList); +} + +template +std::future POIContentManagerProxy<_AttributeExtensions...>::resultListRequestedAsync(const uint8_t& camId, const NavigationTypes::Handle& poiSearchHandle, const std::vector& attributes, ResultListRequestedAsyncCallback callback) { + return delegate_->resultListRequestedAsync(camId, poiSearchHandle, attributes, callback); +} +/** + * This method retrieves the details associated to one or more POI. + It + * contains the name, the parent categories, the list of attributes, the icons, + * ... . + */ +template +void POIContentManagerProxy<_AttributeExtensions...>::poiDetailsRequested(const std::vector& source_id, CommonAPI::CallStatus& callStatus, std::vector& results) { + delegate_->poiDetailsRequested(source_id, callStatus, results); +} + +template +std::future POIContentManagerProxy<_AttributeExtensions...>::poiDetailsRequestedAsync(const std::vector& source_id, PoiDetailsRequestedAsyncCallback callback) { + return delegate_->poiDetailsRequestedAsync(source_id, callback); +} + +template +std::string POIContentManagerProxy<_AttributeExtensions...>::getAddress() const { + return delegate_->getAddress(); +} + +template +const std::string& POIContentManagerProxy<_AttributeExtensions...>::getDomain() const { + return delegate_->getDomain(); +} + +template +const std::string& POIContentManagerProxy<_AttributeExtensions...>::getServiceId() const { + return delegate_->getServiceId(); +} + +template +const std::string& POIContentManagerProxy<_AttributeExtensions...>::getInstanceId() const { + return delegate_->getInstanceId(); +} + +template +bool POIContentManagerProxy<_AttributeExtensions...>::isAvailable() const { + return delegate_->isAvailable(); +} + +template +bool POIContentManagerProxy<_AttributeExtensions...>::isAvailableBlocking() const { + return delegate_->isAvailableBlocking(); +} + +template +CommonAPI::ProxyStatusEvent& POIContentManagerProxy<_AttributeExtensions...>::getProxyStatusEvent() { + return delegate_->getProxyStatusEvent(); +} + +template +CommonAPI::InterfaceVersionAttribute& POIContentManagerProxy<_AttributeExtensions...>::getInterfaceVersionAttribute() { + return delegate_->getInterfaceVersionAttribute(); +} + + +} // namespace poiservice +} // namespace navigation +} // namespace genivi +} // namespace org + + +#endif // ORG_GENIVI_NAVIGATION_POISERVICE_POI_Content_Manager_PROXY_H_ diff --git a/api/franca/navigation/src-gen/org/genivi/navigation/poiservice/POIContentManagerProxyBase.h b/api/franca/navigation/src-gen/org/genivi/navigation/poiservice/POIContentManagerProxyBase.h new file mode 100644 index 0000000..1be6adc --- /dev/null +++ b/api/franca/navigation/src-gen/org/genivi/navigation/poiservice/POIContentManagerProxyBase.h @@ -0,0 +1,198 @@ +/* +* This file was generated by the CommonAPI Generators. +* Used org.genivi.commonapi.core 2.1.6.v20140519. +* Used org.franca.core 0.8.11.201401091023. +* +* 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 interface offers methods that implement the POI search functionality of a + * navigation system. + */ +#ifndef ORG_GENIVI_NAVIGATION_POISERVICE_POI_Content_Manager_PROXY_BASE_H_ +#define ORG_GENIVI_NAVIGATION_POISERVICE_POI_Content_Manager_PROXY_BASE_H_ + +#include "POIContentManager.h" + + +#include +#include + +#if !defined (COMMONAPI_INTERNAL_COMPILATION) +#define COMMONAPI_INTERNAL_COMPILATION +#endif + +#include +#include +#include +#include +#include +#include + +#include +#include +#include +#include + +#undef COMMONAPI_INTERNAL_COMPILATION + +namespace org { +namespace genivi { +namespace navigation { +namespace poiservice { + +class POIContentManagerProxyBase: virtual public CommonAPI::Proxy { + public: + typedef CommonAPI::Event> ConfigurationChangedEvent; + typedef CommonAPI::Event> CategoriesRemovedEvent; + typedef CommonAPI::Event> POIAddedEvent; + typedef CommonAPI::Event> POIRemovedEvent; + + typedef std::function GetVersionAsyncCallback; + typedef std::function SetLocaleAsyncCallback; + typedef std::function GetLocaleAsyncCallback; + typedef std::function&)> GetSupportedLocalesAsyncCallback; + typedef std::function&)> GetAvailableCategoriesAsyncCallback; + typedef std::function GetRootCategoryAsyncCallback; + typedef std::function&)> GetChildrenCategoriesAsyncCallback; + typedef std::function&)> GetParentCategoriesAsyncCallback; + typedef std::function CreateCategoryAsyncCallback; + typedef std::function RemoveCategoriesAsyncCallback; + typedef std::function AddPOIsAsyncCallback; + typedef std::function RemovePOIsAsyncCallback; + typedef std::function PoiSearchStartedAsyncCallback; + typedef std::function PoiSearchCanceledAsyncCallback; + typedef std::function&)> ResultListRequestedAsyncCallback; + typedef std::function&)> PoiDetailsRequestedAsyncCallback; + + + /** + * guidanceStatusChanged = This signal is sent to the clients when one or more + * configuration settings changes. + */ + virtual ConfigurationChangedEvent& getConfigurationChangedEvent() = 0; + /** + * CategoriesRemoved = This signal is emitted when a list of categories and + * associated content has been removed from the database. + */ + virtual CategoriesRemovedEvent& getCategoriesRemovedEvent() = 0; + /** + * POIAdded = This signal is emitted when a list of POIs and associated content + * has been added to the database. It returns the ids. + */ + virtual POIAddedEvent& getPOIAddedEvent() = 0; + /** + * POIRemoved = This signal is emitted when a list of POIs and associated content + * has been removed from the database. + */ + virtual POIRemovedEvent& getPOIRemovedEvent() = 0; + + /** + * This method returns the API version implemented by the content access module. + */ + virtual void getVersion(CommonAPI::CallStatus& callStatus, NavigationTypes::Version& version) = 0; + virtual std::future getVersionAsync(GetVersionAsyncCallback callback) = 0; + /** + * Set the current language set for the search by poi provider module. + + * The language defines the poi and categories name and details language. If the + * language is not supported, the default details will be returned in the native + * language. + */ + virtual void setLocale(const std::string& languageCode, const std::string& countryCode, const std::string& scriptCode, CommonAPI::CallStatus& callStatus) = 0; + virtual std::future setLocaleAsync(const std::string& languageCode, const std::string& countryCode, const std::string& scriptCode, SetLocaleAsyncCallback callback) = 0; + /** + * Get the current language set for the search by poi provider module. + */ + virtual void getLocale(CommonAPI::CallStatus& callStatus, std::string& languageCode, std::string& countryCode, std::string& scriptCode) = 0; + virtual std::future getLocaleAsync(GetLocaleAsyncCallback callback) = 0; + /** + * Get the supported set of locales for the search by poi provider module. + */ + virtual void getSupportedLocales(CommonAPI::CallStatus& callStatus, std::vector& localeList) = 0; + virtual std::future getSupportedLocalesAsync(GetSupportedLocalesAsyncCallback callback) = 0; + /** + * This method retrieves the list od POI categories available (pre-defined and + * custom). + */ + virtual void getAvailableCategories(CommonAPI::CallStatus& callStatus, std::vector& categories) = 0; + virtual std::future getAvailableCategoriesAsync(GetAvailableCategoriesAsyncCallback callback) = 0; + /** + * Get the root category id. That would be ALL_CATEGORIES. + */ + virtual void getRootCategory(CommonAPI::CallStatus& callStatus, POIServiceTypes::CategoryID& category) = 0; + virtual std::future getRootCategoryAsync(GetRootCategoryAsyncCallback callback) = 0; + /** + * Get the children categories id and type (top level) from the a parent unique id. + */ + virtual void getChildrenCategories(const POIServiceTypes::CategoryID& category, CommonAPI::CallStatus& callStatus, std::vector& categories) = 0; + virtual std::future getChildrenCategoriesAsync(const POIServiceTypes::CategoryID& category, GetChildrenCategoriesAsyncCallback callback) = 0; + /** + * Get the parent categories id and type (top level) from the a unique id. + */ + virtual void getParentCategories(const POIServiceTypes::CategoryID& category, CommonAPI::CallStatus& callStatus, std::vector& categories) = 0; + virtual std::future getParentCategoriesAsync(const POIServiceTypes::CategoryID& category, GetParentCategoriesAsyncCallback callback) = 0; + /** + * Creates a category by name and return an unique id. + */ + virtual void createCategory(const POIServiceTypes::CAMCategory& category, CommonAPI::CallStatus& callStatus, POIServiceTypes::CategoryID& unique_id) = 0; + virtual std::future createCategoryAsync(const POIServiceTypes::CAMCategory& category, CreateCategoryAsyncCallback callback) = 0; + /** + * Removes a list of categories. Because of required time to remove it from the + * database, a signal is emitted when the deletion is done. + */ + virtual void removeCategories(const std::vector& categories, CommonAPI::CallStatus& callStatus) = 0; + virtual std::future removeCategoriesAsync(const std::vector& categories, RemoveCategoriesAsyncCallback callback) = 0; + /** + * Adds a list of POIs to a category. Because of required time to add it to the + * database, a signal is emitted when the update is done, that gives the id of + * the elements added + */ + virtual void addPOIs(const POIServiceTypes::CategoryID& unique_id, const std::vector& poiList, CommonAPI::CallStatus& callStatus) = 0; + virtual std::future addPOIsAsync(const POIServiceTypes::CategoryID& unique_id, const std::vector& poiList, AddPOIsAsyncCallback callback) = 0; + /** + * Removes a list of POIs to a category. Because of required time to remove it + * from the database, a signal is emitted when the update is done. + */ + virtual void removePOIs(const std::vector& ids, CommonAPI::CallStatus& callStatus) = 0; + virtual std::future removePOIsAsync(const std::vector& ids, RemovePOIsAsyncCallback callback) = 0; + /** + * This method is sent by the POI service component to inform all the CAM that a + * new POI search was started. + It provides all the relevant search + * parameters. Of course the CAM will only be aware of the search if it registers + * one of the search categories. + */ + virtual void poiSearchStarted(const NavigationTypes::Handle& poiSearchHandle, const uint16_t& maxSize, const NavigationTypes::Coordinate3D& location, const std::vector& poiCategories, const std::vector& poiAttributes, const std::string& inputString, const uint16_t& sortOption, CommonAPI::CallStatus& callStatus) = 0; + virtual std::future poiSearchStartedAsync(const NavigationTypes::Handle& poiSearchHandle, const uint16_t& maxSize, const NavigationTypes::Coordinate3D& location, const std::vector& poiCategories, const std::vector& poiAttributes, const std::string& inputString, const uint16_t& sortOption, PoiSearchStartedAsyncCallback callback) = 0; + /** + * This method cancels the search for the current id. + */ + virtual void poiSearchCanceled(const NavigationTypes::Handle& poiSearchHandle, CommonAPI::CallStatus& callStatus) = 0; + virtual std::future poiSearchCanceledAsync(const NavigationTypes::Handle& poiSearchHandle, PoiSearchCanceledAsyncCallback callback) = 0; + /** + * This method provides the poi results list found by the CAM. + As the POI + * unique id is managed by the POI component, the CAM only provides the POI name, + * the category and coordinates as well as all the relevant detailed information. + */ + virtual void resultListRequested(const uint8_t& camId, const NavigationTypes::Handle& poiSearchHandle, const std::vector& attributes, CommonAPI::CallStatus& callStatus, POIServiceTypes::SearchStatusState& statusValue, uint16_t& resultListSize, std::vector& resultList) = 0; + virtual std::future resultListRequestedAsync(const uint8_t& camId, const NavigationTypes::Handle& poiSearchHandle, const std::vector& attributes, ResultListRequestedAsyncCallback callback) = 0; + /** + * This method retrieves the details associated to one or more POI. + It + * contains the name, the parent categories, the list of attributes, the icons, + * ... . + */ + virtual void poiDetailsRequested(const std::vector& source_id, CommonAPI::CallStatus& callStatus, std::vector& results) = 0; + virtual std::future poiDetailsRequestedAsync(const std::vector& source_id, PoiDetailsRequestedAsyncCallback callback) = 0; +}; + +} // namespace poiservice +} // namespace navigation +} // namespace genivi +} // namespace org + +#endif // ORG_GENIVI_NAVIGATION_POISERVICE_POI_Content_Manager_PROXY_BASE_H_ diff --git a/api/franca/navigation/src-gen/org/genivi/navigation/poiservice/POIContentManagerStub.h b/api/franca/navigation/src-gen/org/genivi/navigation/poiservice/POIContentManagerStub.h new file mode 100644 index 0000000..f851d97 --- /dev/null +++ b/api/franca/navigation/src-gen/org/genivi/navigation/poiservice/POIContentManagerStub.h @@ -0,0 +1,252 @@ +/* +* This file was generated by the CommonAPI Generators. +* Used org.genivi.commonapi.core 2.1.6.v20140519. +* Used org.franca.core 0.8.11.201401091023. +* +* 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 interface offers methods that implement the POI search functionality of a + * navigation system. + */ +#ifndef ORG_GENIVI_NAVIGATION_POISERVICE_POI_Content_Manager_STUB_H_ +#define ORG_GENIVI_NAVIGATION_POISERVICE_POI_Content_Manager_STUB_H_ + + + +#include +#include + +#include "POIContentManager.h" + +#if !defined (COMMONAPI_INTERNAL_COMPILATION) +#define COMMONAPI_INTERNAL_COMPILATION +#endif + +#include +#include +#include +#include +#include +#include +#include + +#include + +#undef COMMONAPI_INTERNAL_COMPILATION + +namespace org { +namespace genivi { +namespace navigation { +namespace poiservice { + +/** + * Receives messages from remote and handles all dispatching of deserialized calls + * to a stub for the service POIContentManager. Also provides means to send broadcasts + * and attribute-changed-notifications of observable attributes as defined by this service. + * An application developer should not need to bother with this class. + */ +class POIContentManagerStubAdapter: virtual public CommonAPI::StubAdapter, public POIContentManager { + public: + + /** + * Sends a broadcast event for ConfigurationChanged. Should not be called directly. + * Instead, the "fireEvent" methods of the stub should be used. + */ + virtual void fireConfigurationChangedEvent(const std::vector& changedSettings) = 0; + /** + * Sends a broadcast event for CategoriesRemoved. Should not be called directly. + * Instead, the "fireEvent" methods of the stub should be used. + */ + virtual void fireCategoriesRemovedEvent(const std::vector& categories) = 0; + /** + * Sends a broadcast event for POIAdded. Should not be called directly. + * Instead, the "fireEvent" methods of the stub should be used. + */ + virtual void firePOIAddedEvent(const std::vector& pois) = 0; + /** + * Sends a broadcast event for POIRemoved. Should not be called directly. + * Instead, the "fireEvent" methods of the stub should be used. + */ + virtual void firePOIRemovedEvent(const std::vector& pois) = 0; + + + virtual void deactivateManagedInstances() = 0; +protected: + /** + * Defines properties for storing the ClientIds of clients / proxies that have + * subscribed to the selective broadcasts + */ +}; + + +/** + * Defines the necessary callbacks to handle remote set events related to the attributes + * defined in the IDL description for POIContentManager. + * For each attribute two callbacks are defined: + * - a verification callback that allows to verify the requested value and to prevent setting + * e.g. an invalid value ("onRemoteSet"). + * - an action callback to do local work after the attribute value has been changed + * ("onRemoteChanged"). + * + * This class and the one below are the ones an application developer needs to have + * a look at if he wants to implement a service. + */ +class POIContentManagerStubRemoteEvent { + public: + virtual ~POIContentManagerStubRemoteEvent() { } + +}; + + +/** + * Defines the interface that must be implemented by any class that should provide + * the service POIContentManager to remote clients. + * This class and the one above are the ones an application developer needs to have + * a look at if he wants to implement a service. + */ +class POIContentManagerStub: public virtual CommonAPI::Stub { +public: + virtual ~POIContentManagerStub() { } + virtual const CommonAPI::Version& getInterfaceVersion(std::shared_ptr clientId) = 0; + + + /** + * This method returns the API version implemented by the content access module. + */ + /// This is the method that will be called on remote calls on the method getVersion. + virtual void getVersion(const std::shared_ptr clientId, NavigationTypes::Version& version) = 0; + /** + * Set the current language set for the search by poi provider module. + + * The language defines the poi and categories name and details language. If the + * language is not supported, the default details will be returned in the native + * language. + */ + /// This is the method that will be called on remote calls on the method setLocale. + virtual void setLocale(const std::shared_ptr clientId, std::string languageCode, std::string countryCode, std::string scriptCode) = 0; + /** + * Get the current language set for the search by poi provider module. + */ + /// This is the method that will be called on remote calls on the method getLocale. + virtual void getLocale(const std::shared_ptr clientId, std::string& languageCode, std::string& countryCode, std::string& scriptCode) = 0; + /** + * Get the supported set of locales for the search by poi provider module. + */ + /// This is the method that will be called on remote calls on the method getSupportedLocales. + virtual void getSupportedLocales(const std::shared_ptr clientId, std::vector& localeList) = 0; + /** + * This method retrieves the list od POI categories available (pre-defined and + * custom). + */ + /// This is the method that will be called on remote calls on the method getAvailableCategories. + virtual void getAvailableCategories(const std::shared_ptr clientId, std::vector& categories) = 0; + /** + * Get the root category id. That would be ALL_CATEGORIES. + */ + /// This is the method that will be called on remote calls on the method getRootCategory. + virtual void getRootCategory(const std::shared_ptr clientId, POIServiceTypes::CategoryID& category) = 0; + /** + * Get the children categories id and type (top level) from the a parent unique id. + */ + /// This is the method that will be called on remote calls on the method getChildrenCategories. + virtual void getChildrenCategories(const std::shared_ptr clientId, POIServiceTypes::CategoryID category, std::vector& categories) = 0; + /** + * Get the parent categories id and type (top level) from the a unique id. + */ + /// This is the method that will be called on remote calls on the method getParentCategories. + virtual void getParentCategories(const std::shared_ptr clientId, POIServiceTypes::CategoryID category, std::vector& categories) = 0; + /** + * Creates a category by name and return an unique id. + */ + /// This is the method that will be called on remote calls on the method createCategory. + virtual void createCategory(const std::shared_ptr clientId, POIServiceTypes::CAMCategory category, POIServiceTypes::CategoryID& unique_id) = 0; + /** + * Removes a list of categories. Because of required time to remove it from the + * database, a signal is emitted when the deletion is done. + */ + /// This is the method that will be called on remote calls on the method removeCategories. + virtual void removeCategories(const std::shared_ptr clientId, std::vector categories) = 0; + /** + * Adds a list of POIs to a category. Because of required time to add it to the + * database, a signal is emitted when the update is done, that gives the id of + * the elements added + */ + /// This is the method that will be called on remote calls on the method addPOIs. + virtual void addPOIs(const std::shared_ptr clientId, POIServiceTypes::CategoryID unique_id, std::vector poiList) = 0; + /** + * Removes a list of POIs to a category. Because of required time to remove it + * from the database, a signal is emitted when the update is done. + */ + /// This is the method that will be called on remote calls on the method removePOIs. + virtual void removePOIs(const std::shared_ptr clientId, std::vector ids) = 0; + /** + * This method is sent by the POI service component to inform all the CAM that a + * new POI search was started. + It provides all the relevant search + * parameters. Of course the CAM will only be aware of the search if it registers + * one of the search categories. + */ + /// This is the method that will be called on remote calls on the method poiSearchStarted. + virtual void poiSearchStarted(const std::shared_ptr clientId, NavigationTypes::Handle poiSearchHandle, uint16_t maxSize, NavigationTypes::Coordinate3D location, std::vector poiCategories, std::vector poiAttributes, std::string inputString, uint16_t sortOption) = 0; + /** + * This method cancels the search for the current id. + */ + /// This is the method that will be called on remote calls on the method poiSearchCanceled. + virtual void poiSearchCanceled(const std::shared_ptr clientId, NavigationTypes::Handle poiSearchHandle) = 0; + /** + * This method provides the poi results list found by the CAM. + As the POI + * unique id is managed by the POI component, the CAM only provides the POI name, + * the category and coordinates as well as all the relevant detailed information. + */ + /// This is the method that will be called on remote calls on the method resultListRequested. + virtual void resultListRequested(const std::shared_ptr clientId, uint8_t camId, NavigationTypes::Handle poiSearchHandle, std::vector attributes, POIServiceTypes::SearchStatusState& statusValue, uint16_t& resultListSize, std::vector& resultList) = 0; + /** + * This method retrieves the details associated to one or more POI. + It + * contains the name, the parent categories, the list of attributes, the icons, + * ... . + */ + /// This is the method that will be called on remote calls on the method poiDetailsRequested. + virtual void poiDetailsRequested(const std::shared_ptr clientId, std::vector source_id, std::vector& results) = 0; + /** + * guidanceStatusChanged = This signal is sent to the clients when one or more + * configuration settings changes. + */ + /// Sends a broadcast event for ConfigurationChanged. + virtual void fireConfigurationChangedEvent(const std::vector& changedSettings) = 0; + /** + * CategoriesRemoved = This signal is emitted when a list of categories and + * associated content has been removed from the database. + */ + /// Sends a broadcast event for CategoriesRemoved. + virtual void fireCategoriesRemovedEvent(const std::vector& categories) = 0; + /** + * POIAdded = This signal is emitted when a list of POIs and associated content + * has been added to the database. It returns the ids. + */ + /// Sends a broadcast event for POIAdded. + virtual void firePOIAddedEvent(const std::vector& pois) = 0; + /** + * POIRemoved = This signal is emitted when a list of POIs and associated content + * has been removed from the database. + */ + /// Sends a broadcast event for POIRemoved. + virtual void firePOIRemovedEvent(const std::vector& pois) = 0; + + using CommonAPI::Stub::initStubAdapter; + typedef CommonAPI::Stub::StubAdapterType StubAdapterType; + typedef CommonAPI::Stub::RemoteEventHandlerType RemoteEventHandlerType; + typedef POIContentManagerStubRemoteEvent RemoteEventType; + typedef POIContentManager StubInterface; +}; + +} // namespace poiservice +} // namespace navigation +} // namespace genivi +} // namespace org + +#endif // ORG_GENIVI_NAVIGATION_POISERVICE_POI_Content_Manager_STUB_H_ diff --git a/api/franca/navigation/src-gen/org/genivi/navigation/poiservice/POIContentManagerStubDefault.cpp b/api/franca/navigation/src-gen/org/genivi/navigation/poiservice/POIContentManagerStubDefault.cpp new file mode 100644 index 0000000..a161181 --- /dev/null +++ b/api/franca/navigation/src-gen/org/genivi/navigation/poiservice/POIContentManagerStubDefault.cpp @@ -0,0 +1,265 @@ +/* +* This file was generated by the CommonAPI Generators. +* Used org.genivi.commonapi.core 2.1.6.v20140519. +* Used org.franca.core 0.8.11.201401091023. +* +* 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 + +namespace org { +namespace genivi { +namespace navigation { +namespace poiservice { + +POIContentManagerStubDefault::POIContentManagerStubDefault(): + remoteEventHandler_(this), + interfaceVersion_(POIContentManager::getInterfaceVersion()) { +} + +const CommonAPI::Version& POIContentManagerStubDefault::getInterfaceVersion(std::shared_ptr clientId) { + return interfaceVersion_; +} + +POIContentManagerStubRemoteEvent* POIContentManagerStubDefault::initStubAdapter(const std::shared_ptr& stubAdapter) { + CommonAPI::Stub::stubAdapter_ = stubAdapter; + return &remoteEventHandler_; +} + + +/** + * This method returns the API version implemented by the content access module. + */ +void POIContentManagerStubDefault::getVersion(const std::shared_ptr clientId, NavigationTypes::Version& version) { + // Call old style methods in default + getVersion(version); +} +void POIContentManagerStubDefault::getVersion(NavigationTypes::Version& version) { + // No operation in default +} + +/** + * Set the current language set for the search by poi provider module. + + * The language defines the poi and categories name and details language. If the + * language is not supported, the default details will be returned in the native + * language. + */ +void POIContentManagerStubDefault::setLocale(const std::shared_ptr clientId, std::string languageCode, std::string countryCode, std::string scriptCode) { + // Call old style methods in default + setLocale(languageCode, countryCode, scriptCode); +} +void POIContentManagerStubDefault::setLocale(std::string languageCode, std::string countryCode, std::string scriptCode) { + // No operation in default +} + +/** + * Get the current language set for the search by poi provider module. + */ +void POIContentManagerStubDefault::getLocale(const std::shared_ptr clientId, std::string& languageCode, std::string& countryCode, std::string& scriptCode) { + // Call old style methods in default + getLocale(languageCode, countryCode, scriptCode); +} +void POIContentManagerStubDefault::getLocale(std::string& languageCode, std::string& countryCode, std::string& scriptCode) { + // No operation in default +} + +/** + * Get the supported set of locales for the search by poi provider module. + */ +void POIContentManagerStubDefault::getSupportedLocales(const std::shared_ptr clientId, std::vector& localeList) { + // Call old style methods in default + getSupportedLocales(localeList); +} +void POIContentManagerStubDefault::getSupportedLocales(std::vector& localeList) { + // No operation in default +} + +/** + * This method retrieves the list od POI categories available (pre-defined and + * custom). + */ +void POIContentManagerStubDefault::getAvailableCategories(const std::shared_ptr clientId, std::vector& categories) { + // Call old style methods in default + getAvailableCategories(categories); +} +void POIContentManagerStubDefault::getAvailableCategories(std::vector& categories) { + // No operation in default +} + +/** + * Get the root category id. That would be ALL_CATEGORIES. + */ +void POIContentManagerStubDefault::getRootCategory(const std::shared_ptr clientId, POIServiceTypes::CategoryID& category) { + // Call old style methods in default + getRootCategory(category); +} +void POIContentManagerStubDefault::getRootCategory(POIServiceTypes::CategoryID& category) { + // No operation in default +} + +/** + * Get the children categories id and type (top level) from the a parent unique id. + */ +void POIContentManagerStubDefault::getChildrenCategories(const std::shared_ptr clientId, POIServiceTypes::CategoryID category, std::vector& categories) { + // Call old style methods in default + getChildrenCategories(category, categories); +} +void POIContentManagerStubDefault::getChildrenCategories(POIServiceTypes::CategoryID category, std::vector& categories) { + // No operation in default +} + +/** + * Get the parent categories id and type (top level) from the a unique id. + */ +void POIContentManagerStubDefault::getParentCategories(const std::shared_ptr clientId, POIServiceTypes::CategoryID category, std::vector& categories) { + // Call old style methods in default + getParentCategories(category, categories); +} +void POIContentManagerStubDefault::getParentCategories(POIServiceTypes::CategoryID category, std::vector& categories) { + // No operation in default +} + +/** + * Creates a category by name and return an unique id. + */ +void POIContentManagerStubDefault::createCategory(const std::shared_ptr clientId, POIServiceTypes::CAMCategory category, POIServiceTypes::CategoryID& unique_id) { + // Call old style methods in default + createCategory(category, unique_id); +} +void POIContentManagerStubDefault::createCategory(POIServiceTypes::CAMCategory category, POIServiceTypes::CategoryID& unique_id) { + // No operation in default +} + +/** + * Removes a list of categories. Because of required time to remove it from the + * database, a signal is emitted when the deletion is done. + */ +void POIContentManagerStubDefault::removeCategories(const std::shared_ptr clientId, std::vector categories) { + // Call old style methods in default + removeCategories(categories); +} +void POIContentManagerStubDefault::removeCategories(std::vector categories) { + // No operation in default +} + +/** + * Adds a list of POIs to a category. Because of required time to add it to the + * database, a signal is emitted when the update is done, that gives the id of + * the elements added + */ +void POIContentManagerStubDefault::addPOIs(const std::shared_ptr clientId, POIServiceTypes::CategoryID unique_id, std::vector poiList) { + // Call old style methods in default + addPOIs(unique_id, poiList); +} +void POIContentManagerStubDefault::addPOIs(POIServiceTypes::CategoryID unique_id, std::vector poiList) { + // No operation in default +} + +/** + * Removes a list of POIs to a category. Because of required time to remove it + * from the database, a signal is emitted when the update is done. + */ +void POIContentManagerStubDefault::removePOIs(const std::shared_ptr clientId, std::vector ids) { + // Call old style methods in default + removePOIs(ids); +} +void POIContentManagerStubDefault::removePOIs(std::vector ids) { + // No operation in default +} + +/** + * This method is sent by the POI service component to inform all the CAM that a + * new POI search was started. + It provides all the relevant search + * parameters. Of course the CAM will only be aware of the search if it registers + * one of the search categories. + */ +void POIContentManagerStubDefault::poiSearchStarted(const std::shared_ptr clientId, NavigationTypes::Handle poiSearchHandle, uint16_t maxSize, NavigationTypes::Coordinate3D location, std::vector poiCategories, std::vector poiAttributes, std::string inputString, uint16_t sortOption) { + // Call old style methods in default + poiSearchStarted(poiSearchHandle, maxSize, location, poiCategories, poiAttributes, inputString, sortOption); +} +void POIContentManagerStubDefault::poiSearchStarted(NavigationTypes::Handle poiSearchHandle, uint16_t maxSize, NavigationTypes::Coordinate3D location, std::vector poiCategories, std::vector poiAttributes, std::string inputString, uint16_t sortOption) { + // No operation in default +} + +/** + * This method cancels the search for the current id. + */ +void POIContentManagerStubDefault::poiSearchCanceled(const std::shared_ptr clientId, NavigationTypes::Handle poiSearchHandle) { + // Call old style methods in default + poiSearchCanceled(poiSearchHandle); +} +void POIContentManagerStubDefault::poiSearchCanceled(NavigationTypes::Handle poiSearchHandle) { + // No operation in default +} + +/** + * This method provides the poi results list found by the CAM. + As the POI + * unique id is managed by the POI component, the CAM only provides the POI name, + * the category and coordinates as well as all the relevant detailed information. + */ +void POIContentManagerStubDefault::resultListRequested(const std::shared_ptr clientId, uint8_t camId, NavigationTypes::Handle poiSearchHandle, std::vector attributes, POIServiceTypes::SearchStatusState& statusValue, uint16_t& resultListSize, std::vector& resultList) { + // Call old style methods in default + resultListRequested(camId, poiSearchHandle, attributes, statusValue, resultListSize, resultList); +} +void POIContentManagerStubDefault::resultListRequested(uint8_t camId, NavigationTypes::Handle poiSearchHandle, std::vector attributes, POIServiceTypes::SearchStatusState& statusValue, uint16_t& resultListSize, std::vector& resultList) { + // No operation in default +} + +/** + * This method retrieves the details associated to one or more POI. + It + * contains the name, the parent categories, the list of attributes, the icons, + * ... . + */ +void POIContentManagerStubDefault::poiDetailsRequested(const std::shared_ptr clientId, std::vector source_id, std::vector& results) { + // Call old style methods in default + poiDetailsRequested(source_id, results); +} +void POIContentManagerStubDefault::poiDetailsRequested(std::vector source_id, std::vector& results) { + // No operation in default +} + + +/** + * guidanceStatusChanged = This signal is sent to the clients when one or more + * configuration settings changes. + */ +void POIContentManagerStubDefault::fireConfigurationChangedEvent(const std::vector& changedSettings) { + stubAdapter_->fireConfigurationChangedEvent(changedSettings); +} +/** + * CategoriesRemoved = This signal is emitted when a list of categories and + * associated content has been removed from the database. + */ +void POIContentManagerStubDefault::fireCategoriesRemovedEvent(const std::vector& categories) { + stubAdapter_->fireCategoriesRemovedEvent(categories); +} +/** + * POIAdded = This signal is emitted when a list of POIs and associated content + * has been added to the database. It returns the ids. + */ +void POIContentManagerStubDefault::firePOIAddedEvent(const std::vector& pois) { + stubAdapter_->firePOIAddedEvent(pois); +} +/** + * POIRemoved = This signal is emitted when a list of POIs and associated content + * has been removed from the database. + */ +void POIContentManagerStubDefault::firePOIRemovedEvent(const std::vector& pois) { + stubAdapter_->firePOIRemovedEvent(pois); +} + + +POIContentManagerStubDefault::RemoteEventHandler::RemoteEventHandler(POIContentManagerStubDefault* defaultStub): + defaultStub_(defaultStub) { +} + +} // namespace poiservice +} // namespace navigation +} // namespace genivi +} // namespace org diff --git a/api/franca/navigation/src-gen/org/genivi/navigation/poiservice/POIContentManagerStubDefault.h b/api/franca/navigation/src-gen/org/genivi/navigation/poiservice/POIContentManagerStubDefault.h new file mode 100644 index 0000000..5008eed --- /dev/null +++ b/api/franca/navigation/src-gen/org/genivi/navigation/poiservice/POIContentManagerStubDefault.h @@ -0,0 +1,204 @@ +/* +* This file was generated by the CommonAPI Generators. +* Used org.genivi.commonapi.core 2.1.6.v20140519. +* Used org.franca.core 0.8.11.201401091023. +* +* 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 interface offers methods that implement the POI search functionality of a + * navigation system. + */ +#ifndef ORG_GENIVI_NAVIGATION_POISERVICE_POI_Content_Manager_STUB_DEFAULT_H_ +#define ORG_GENIVI_NAVIGATION_POISERVICE_POI_Content_Manager_STUB_DEFAULT_H_ + + +#include +#include + +namespace org { +namespace genivi { +namespace navigation { +namespace poiservice { + +/** + * Provides a default implementation for POIContentManagerStubRemoteEvent and + * POIContentManagerStub. 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 POIContentManagerStubDefault : public virtual POIContentManagerStub { +public: + POIContentManagerStubDefault(); + + POIContentManagerStubRemoteEvent* initStubAdapter(const std::shared_ptr& stubAdapter); + + const CommonAPI::Version& getInterfaceVersion(std::shared_ptr clientId); + + + /** + * This method returns the API version implemented by the content access module. + */ + virtual void getVersion(const std::shared_ptr clientId, NavigationTypes::Version& version); + virtual void getVersion(NavigationTypes::Version& version); + + /** + * Set the current language set for the search by poi provider module. + + * The language defines the poi and categories name and details language. If the + * language is not supported, the default details will be returned in the native + * language. + */ + virtual void setLocale(const std::shared_ptr clientId, std::string languageCode, std::string countryCode, std::string scriptCode); + virtual void setLocale(std::string languageCode, std::string countryCode, std::string scriptCode); + + /** + * Get the current language set for the search by poi provider module. + */ + virtual void getLocale(const std::shared_ptr clientId, std::string& languageCode, std::string& countryCode, std::string& scriptCode); + virtual void getLocale(std::string& languageCode, std::string& countryCode, std::string& scriptCode); + + /** + * Get the supported set of locales for the search by poi provider module. + */ + virtual void getSupportedLocales(const std::shared_ptr clientId, std::vector& localeList); + virtual void getSupportedLocales(std::vector& localeList); + + /** + * This method retrieves the list od POI categories available (pre-defined and + * custom). + */ + virtual void getAvailableCategories(const std::shared_ptr clientId, std::vector& categories); + virtual void getAvailableCategories(std::vector& categories); + + /** + * Get the root category id. That would be ALL_CATEGORIES. + */ + virtual void getRootCategory(const std::shared_ptr clientId, POIServiceTypes::CategoryID& category); + virtual void getRootCategory(POIServiceTypes::CategoryID& category); + + /** + * Get the children categories id and type (top level) from the a parent unique id. + */ + virtual void getChildrenCategories(const std::shared_ptr clientId, POIServiceTypes::CategoryID category, std::vector& categories); + virtual void getChildrenCategories(POIServiceTypes::CategoryID category, std::vector& categories); + + /** + * Get the parent categories id and type (top level) from the a unique id. + */ + virtual void getParentCategories(const std::shared_ptr clientId, POIServiceTypes::CategoryID category, std::vector& categories); + virtual void getParentCategories(POIServiceTypes::CategoryID category, std::vector& categories); + + /** + * Creates a category by name and return an unique id. + */ + virtual void createCategory(const std::shared_ptr clientId, POIServiceTypes::CAMCategory category, POIServiceTypes::CategoryID& unique_id); + virtual void createCategory(POIServiceTypes::CAMCategory category, POIServiceTypes::CategoryID& unique_id); + + /** + * Removes a list of categories. Because of required time to remove it from the + * database, a signal is emitted when the deletion is done. + */ + virtual void removeCategories(const std::shared_ptr clientId, std::vector categories); + virtual void removeCategories(std::vector categories); + + /** + * Adds a list of POIs to a category. Because of required time to add it to the + * database, a signal is emitted when the update is done, that gives the id of + * the elements added + */ + virtual void addPOIs(const std::shared_ptr clientId, POIServiceTypes::CategoryID unique_id, std::vector poiList); + virtual void addPOIs(POIServiceTypes::CategoryID unique_id, std::vector poiList); + + /** + * Removes a list of POIs to a category. Because of required time to remove it + * from the database, a signal is emitted when the update is done. + */ + virtual void removePOIs(const std::shared_ptr clientId, std::vector ids); + virtual void removePOIs(std::vector ids); + + /** + * This method is sent by the POI service component to inform all the CAM that a + * new POI search was started. + It provides all the relevant search + * parameters. Of course the CAM will only be aware of the search if it registers + * one of the search categories. + */ + virtual void poiSearchStarted(const std::shared_ptr clientId, NavigationTypes::Handle poiSearchHandle, uint16_t maxSize, NavigationTypes::Coordinate3D location, std::vector poiCategories, std::vector poiAttributes, std::string inputString, uint16_t sortOption); + virtual void poiSearchStarted(NavigationTypes::Handle poiSearchHandle, uint16_t maxSize, NavigationTypes::Coordinate3D location, std::vector poiCategories, std::vector poiAttributes, std::string inputString, uint16_t sortOption); + + /** + * This method cancels the search for the current id. + */ + virtual void poiSearchCanceled(const std::shared_ptr clientId, NavigationTypes::Handle poiSearchHandle); + virtual void poiSearchCanceled(NavigationTypes::Handle poiSearchHandle); + + /** + * This method provides the poi results list found by the CAM. + As the POI + * unique id is managed by the POI component, the CAM only provides the POI name, + * the category and coordinates as well as all the relevant detailed information. + */ + virtual void resultListRequested(const std::shared_ptr clientId, uint8_t camId, NavigationTypes::Handle poiSearchHandle, std::vector attributes, POIServiceTypes::SearchStatusState& statusValue, uint16_t& resultListSize, std::vector& resultList); + virtual void resultListRequested(uint8_t camId, NavigationTypes::Handle poiSearchHandle, std::vector attributes, POIServiceTypes::SearchStatusState& statusValue, uint16_t& resultListSize, std::vector& resultList); + + /** + * This method retrieves the details associated to one or more POI. + It + * contains the name, the parent categories, the list of attributes, the icons, + * ... . + */ + virtual void poiDetailsRequested(const std::shared_ptr clientId, std::vector source_id, std::vector& results); + virtual void poiDetailsRequested(std::vector source_id, std::vector& results); + + + /** + * guidanceStatusChanged = This signal is sent to the clients when one or more + * configuration settings changes. + */ + virtual void fireConfigurationChangedEvent(const std::vector& changedSettings); + /** + * CategoriesRemoved = This signal is emitted when a list of categories and + * associated content has been removed from the database. + */ + virtual void fireCategoriesRemovedEvent(const std::vector& categories); + /** + * POIAdded = This signal is emitted when a list of POIs and associated content + * has been added to the database. It returns the ids. + */ + virtual void firePOIAddedEvent(const std::vector& pois); + /** + * POIRemoved = This signal is emitted when a list of POIs and associated content + * has been removed from the database. + */ + virtual void firePOIRemovedEvent(const std::vector& pois); + + +protected: + class RemoteEventHandler: public virtual POIContentManagerStubRemoteEvent { + public: + RemoteEventHandler(POIContentManagerStubDefault* defaultStub); + + + private: + POIContentManagerStubDefault* defaultStub_; + }; +private: + POIContentManagerStubDefault::RemoteEventHandler remoteEventHandler_; + + + CommonAPI::Version interfaceVersion_; +}; + +} // namespace poiservice +} // namespace navigation +} // namespace genivi +} // namespace org + +#endif // ORG_GENIVI_NAVIGATION_POISERVICE_POI_Content_Manager_STUB_DEFAULT_H_ diff --git a/api/franca/navigation/src-gen/org/genivi/navigation/poiservice/POIServiceTypes.cpp b/api/franca/navigation/src-gen/org/genivi/navigation/poiservice/POIServiceTypes.cpp new file mode 100644 index 0000000..021a56e --- /dev/null +++ b/api/franca/navigation/src-gen/org/genivi/navigation/poiservice/POIServiceTypes.cpp @@ -0,0 +1,722 @@ +/* +* This file was generated by the CommonAPI Generators. +* Used org.genivi.commonapi.core 2.1.6.v20140519. +* Used org.franca.core 0.8.11.201401091023. +* +* 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 "POIServiceTypes.h" + + +namespace org { +namespace genivi { +namespace navigation { +namespace poiservice { +namespace POIServiceTypes { + + + + + + + + + + + + + +Details::Details(const std::vector& parentsIdValue, const Icon& iconsValue, const std::string& nameValue, const std::string& shortDescValue, const Media& mediaValue): + parentsId(parentsIdValue), + icons(iconsValue), + name(nameValue), + shortDesc(shortDescValue), + media(mediaValue) +{ +} + + +bool operator==(const Details& lhs, const Details& rhs) { + if (&lhs == &rhs) + return true; + + return + lhs.parentsId == rhs.parentsId && + lhs.icons == rhs.icons && + lhs.name == rhs.name && + lhs.shortDesc == rhs.shortDesc && + lhs.media == rhs.media + ; +} + +void Details::readFromInputStream(CommonAPI::InputStream& inputStream) { + inputStream >> parentsId; + inputStream >> icons; + inputStream >> name; + inputStream >> shortDesc; + inputStream >> media; +} + +void Details::writeToOutputStream(CommonAPI::OutputStream& outputStream) const { + outputStream << parentsId; + outputStream << icons; + outputStream << name; + outputStream << shortDesc; + outputStream << media; +} + +Operator::Operator(const OperatorType& typeValue, const std::string& nameValue, const AttributeValue& valueValue): + type(typeValue), + name(nameValue), + value(valueValue) +{ +} + + +bool operator==(const Operator& lhs, const Operator& rhs) { + if (&lhs == &rhs) + return true; + + return + lhs.type == rhs.type && + lhs.name == rhs.name && + lhs.value == rhs.value + ; +} + +void Operator::readFromInputStream(CommonAPI::InputStream& inputStream) { + inputStream >> type; + inputStream >> name; + inputStream >> value; +} + +void Operator::writeToOutputStream(CommonAPI::OutputStream& outputStream) const { + outputStream << type; + outputStream << name; + outputStream << value; +} + +CategoryAttribute::CategoryAttribute(const AttributeID& idValue, const std::string& nameValue, const AttributeType& typeValue, const std::vector& operatorsValue): + id(idValue), + name(nameValue), + type(typeValue), + operators(operatorsValue) +{ +} + + +bool operator==(const CategoryAttribute& lhs, const CategoryAttribute& rhs) { + if (&lhs == &rhs) + return true; + + return + lhs.id == rhs.id && + lhs.name == rhs.name && + lhs.type == rhs.type && + lhs.operators == rhs.operators + ; +} + +void CategoryAttribute::readFromInputStream(CommonAPI::InputStream& inputStream) { + inputStream >> id; + inputStream >> name; + inputStream >> type; + inputStream >> operators; +} + +void CategoryAttribute::writeToOutputStream(CommonAPI::OutputStream& outputStream) const { + outputStream << id; + outputStream << name; + outputStream << type; + outputStream << operators; +} + +CategorySortOption::CategorySortOption(const CategoryID& idValue, const std::string& nameValue): + id(idValue), + name(nameValue) +{ +} + + +bool operator==(const CategorySortOption& lhs, const CategorySortOption& rhs) { + if (&lhs == &rhs) + return true; + + return + lhs.id == rhs.id && + lhs.name == rhs.name + ; +} + +void CategorySortOption::readFromInputStream(CommonAPI::InputStream& inputStream) { + inputStream >> id; + inputStream >> name; +} + +void CategorySortOption::writeToOutputStream(CommonAPI::OutputStream& outputStream) const { + outputStream << id; + outputStream << name; +} + +CAMCategory::CAMCategory(const Details& detailsValue, const std::vector& attributesValue, const std::vector& sortOptionsValue): + details(detailsValue), + attributes(attributesValue), + sortOptions(sortOptionsValue) +{ +} + + +bool operator==(const CAMCategory& lhs, const CAMCategory& rhs) { + if (&lhs == &rhs) + return true; + + return + lhs.details == rhs.details && + lhs.attributes == rhs.attributes && + lhs.sortOptions == rhs.sortOptions + ; +} + +void CAMCategory::readFromInputStream(CommonAPI::InputStream& inputStream) { + inputStream >> details; + inputStream >> attributes; + inputStream >> sortOptions; +} + +void CAMCategory::writeToOutputStream(CommonAPI::OutputStream& outputStream) const { + outputStream << details; + outputStream << attributes; + outputStream << sortOptions; +} + +CAMCategoryUpdate::CAMCategoryUpdate(const CategoryID& idValue, const std::vector& attributesValue, const std::vector& sortOptionsValue): + id(idValue), + attributes(attributesValue), + sortOptions(sortOptionsValue) +{ +} + + +bool operator==(const CAMCategoryUpdate& lhs, const CAMCategoryUpdate& rhs) { + if (&lhs == &rhs) + return true; + + return + lhs.id == rhs.id && + lhs.attributes == rhs.attributes && + lhs.sortOptions == rhs.sortOptions + ; +} + +void CAMCategoryUpdate::readFromInputStream(CommonAPI::InputStream& inputStream) { + inputStream >> id; + inputStream >> attributes; + inputStream >> sortOptions; +} + +void CAMCategoryUpdate::writeToOutputStream(CommonAPI::OutputStream& outputStream) const { + outputStream << id; + outputStream << attributes; + outputStream << sortOptions; +} + +PoiAttribute::PoiAttribute(const AttributeID& idValue, const AttributeType& typeValue, const AttributeValue& valueValue): + id(idValue), + type(typeValue), + value(valueValue) +{ +} + + +bool operator==(const PoiAttribute& lhs, const PoiAttribute& rhs) { + if (&lhs == &rhs) + return true; + + return + lhs.id == rhs.id && + lhs.type == rhs.type && + lhs.value == rhs.value + ; +} + +void PoiAttribute::readFromInputStream(CommonAPI::InputStream& inputStream) { + inputStream >> id; + inputStream >> type; + inputStream >> value; +} + +void PoiAttribute::writeToOutputStream(CommonAPI::OutputStream& outputStream) const { + outputStream << id; + outputStream << type; + outputStream << value; +} + +CategoryAndRadius::CategoryAndRadius(const CategoryID& idValue, const uint32_t& radiusValue): + id(idValue), + radius(radiusValue) +{ +} + + +bool operator==(const CategoryAndRadius& lhs, const CategoryAndRadius& rhs) { + if (&lhs == &rhs) + return true; + + return + lhs.id == rhs.id && + lhs.radius == rhs.radius + ; +} + +void CategoryAndRadius::readFromInputStream(CommonAPI::InputStream& inputStream) { + inputStream >> id; + inputStream >> radius; +} + +void CategoryAndRadius::writeToOutputStream(CommonAPI::OutputStream& outputStream) const { + outputStream << id; + outputStream << radius; +} + +PoiDetails::PoiDetails(const POI_ID& idValue, const std::string& nameValue, const NavigationTypes::Coordinate3D& locationValue): + id(idValue), + name(nameValue), + location(locationValue) +{ +} + + +bool operator==(const PoiDetails& lhs, const PoiDetails& rhs) { + if (&lhs == &rhs) + return true; + + return + lhs.id == rhs.id && + lhs.name == rhs.name && + lhs.location == rhs.location + ; +} + +void PoiDetails::readFromInputStream(CommonAPI::InputStream& inputStream) { + inputStream >> id; + inputStream >> name; + inputStream >> location; +} + +void PoiDetails::writeToOutputStream(CommonAPI::OutputStream& outputStream) const { + outputStream << id; + outputStream << name; + outputStream << location; +} + +SearchResultDetails::SearchResultDetails(const PoiDetails& detailsValue, const std::vector& categoriesValue, const std::vector& attributesValue): + details(detailsValue), + categories(categoriesValue), + attributes(attributesValue) +{ +} + + +bool operator==(const SearchResultDetails& lhs, const SearchResultDetails& rhs) { + if (&lhs == &rhs) + return true; + + return + lhs.details == rhs.details && + lhs.categories == rhs.categories && + lhs.attributes == rhs.attributes + ; +} + +void SearchResultDetails::readFromInputStream(CommonAPI::InputStream& inputStream) { + inputStream >> details; + inputStream >> categories; + inputStream >> attributes; +} + +void SearchResultDetails::writeToOutputStream(CommonAPI::OutputStream& outputStream) const { + outputStream << details; + outputStream << categories; + outputStream << attributes; +} + +SearchResult::SearchResult(const POI_ID& idValue, const uint32_t& distanceValue, const uint16_t& routeStatusValue, const std::vector& attributesValue): + id(idValue), + distance(distanceValue), + routeStatus(routeStatusValue), + attributes(attributesValue) +{ +} + + +bool operator==(const SearchResult& lhs, const SearchResult& rhs) { + if (&lhs == &rhs) + return true; + + return + lhs.id == rhs.id && + lhs.distance == rhs.distance && + lhs.routeStatus == rhs.routeStatus && + lhs.attributes == rhs.attributes + ; +} + +void SearchResult::readFromInputStream(CommonAPI::InputStream& inputStream) { + inputStream >> id; + inputStream >> distance; + inputStream >> routeStatus; + inputStream >> attributes; +} + +void SearchResult::writeToOutputStream(CommonAPI::OutputStream& outputStream) const { + outputStream << id; + outputStream << distance; + outputStream << routeStatus; + outputStream << attributes; +} + +PoiCAMDetails::PoiCAMDetails(const POI_ID& sourceIdValue, const std::string& nameValue, const CategoryID& categoryValue, const NavigationTypes::Coordinate3D& locationValue, const uint16_t& distanceValue, const std::vector& attributesValue): + sourceId(sourceIdValue), + name(nameValue), + category(categoryValue), + location(locationValue), + distance(distanceValue), + attributes(attributesValue) +{ +} + + +bool operator==(const PoiCAMDetails& lhs, const PoiCAMDetails& rhs) { + if (&lhs == &rhs) + return true; + + return + lhs.sourceId == rhs.sourceId && + lhs.name == rhs.name && + lhs.category == rhs.category && + lhs.location == rhs.location && + lhs.distance == rhs.distance && + lhs.attributes == rhs.attributes + ; +} + +void PoiCAMDetails::readFromInputStream(CommonAPI::InputStream& inputStream) { + inputStream >> sourceId; + inputStream >> name; + inputStream >> category; + inputStream >> location; + inputStream >> distance; + inputStream >> attributes; +} + +void PoiCAMDetails::writeToOutputStream(CommonAPI::OutputStream& outputStream) const { + outputStream << sourceId; + outputStream << name; + outputStream << category; + outputStream << location; + outputStream << distance; + outputStream << attributes; +} + +AttributeDetails::AttributeDetails(const AttributeID& idValue, const CategoryID& categoryIdValue, const AttributeType& typeValue, const AttributeValue& valueValue, const OperatorType& operValue, const bool& mandatoryValue): + id(idValue), + categoryId(categoryIdValue), + type(typeValue), + value(valueValue), + oper(operValue), + mandatory(mandatoryValue) +{ +} + + +bool operator==(const AttributeDetails& lhs, const AttributeDetails& rhs) { + if (&lhs == &rhs) + return true; + + return + lhs.id == rhs.id && + lhs.categoryId == rhs.categoryId && + lhs.type == rhs.type && + lhs.value == rhs.value && + lhs.oper == rhs.oper && + lhs.mandatory == rhs.mandatory + ; +} + +void AttributeDetails::readFromInputStream(CommonAPI::InputStream& inputStream) { + inputStream >> id; + inputStream >> categoryId; + inputStream >> type; + inputStream >> value; + inputStream >> oper; + inputStream >> mandatory; +} + +void AttributeDetails::writeToOutputStream(CommonAPI::OutputStream& outputStream) const { + outputStream << id; + outputStream << categoryId; + outputStream << type; + outputStream << value; + outputStream << oper; + outputStream << mandatory; +} + +CategoryDetails::CategoryDetails(const CategoryID& uniqueIdValue, const std::vector& parentsIdValue, const Icon& iconsValue, const std::string& nameValue, const bool& topLevelValue, const std::string& descriptionValue, const Media& mediaValue): + uniqueId(uniqueIdValue), + parentsId(parentsIdValue), + icons(iconsValue), + name(nameValue), + topLevel(topLevelValue), + description(descriptionValue), + media(mediaValue) +{ +} + + +bool operator==(const CategoryDetails& lhs, const CategoryDetails& rhs) { + if (&lhs == &rhs) + return true; + + return + lhs.uniqueId == rhs.uniqueId && + lhs.parentsId == rhs.parentsId && + lhs.icons == rhs.icons && + lhs.name == rhs.name && + lhs.topLevel == rhs.topLevel && + lhs.description == rhs.description && + lhs.media == rhs.media + ; +} + +void CategoryDetails::readFromInputStream(CommonAPI::InputStream& inputStream) { + inputStream >> uniqueId; + inputStream >> parentsId; + inputStream >> icons; + inputStream >> name; + inputStream >> topLevel; + inputStream >> description; + inputStream >> media; +} + +void CategoryDetails::writeToOutputStream(CommonAPI::OutputStream& outputStream) const { + outputStream << uniqueId; + outputStream << parentsId; + outputStream << icons; + outputStream << name; + outputStream << topLevel; + outputStream << description; + outputStream << media; +} + +Category::Category(const CategoryDetails& detailsValue, const std::vector& attributesValue, const std::vector& sortOptionsValue): + details(detailsValue), + attributes(attributesValue), + sortOptions(sortOptionsValue) +{ +} + + +bool operator==(const Category& lhs, const Category& rhs) { + if (&lhs == &rhs) + return true; + + return + lhs.details == rhs.details && + lhs.attributes == rhs.attributes && + lhs.sortOptions == rhs.sortOptions + ; +} + +void Category::readFromInputStream(CommonAPI::InputStream& inputStream) { + inputStream >> details; + inputStream >> attributes; + inputStream >> sortOptions; +} + +void Category::writeToOutputStream(CommonAPI::OutputStream& outputStream) const { + outputStream << details; + outputStream << attributes; + outputStream << sortOptions; +} + +CategoryAndLevel::CategoryAndLevel(const CategoryID& uniqueIdValue, const bool& topLevelValue): + uniqueId(uniqueIdValue), + topLevel(topLevelValue) +{ +} + + +bool operator==(const CategoryAndLevel& lhs, const CategoryAndLevel& rhs) { + if (&lhs == &rhs) + return true; + + return + lhs.uniqueId == rhs.uniqueId && + lhs.topLevel == rhs.topLevel + ; +} + +void CategoryAndLevel::readFromInputStream(CommonAPI::InputStream& inputStream) { + inputStream >> uniqueId; + inputStream >> topLevel; +} + +void CategoryAndLevel::writeToOutputStream(CommonAPI::OutputStream& outputStream) const { + outputStream << uniqueId; + outputStream << topLevel; +} + +CategoryAndName::CategoryAndName(const CategoryID& uniqueIdValue, const std::string& nameValue, const bool& topLevelValue): + uniqueId(uniqueIdValue), + name(nameValue), + topLevel(topLevelValue) +{ +} + + +bool operator==(const CategoryAndName& lhs, const CategoryAndName& rhs) { + if (&lhs == &rhs) + return true; + + return + lhs.uniqueId == rhs.uniqueId && + lhs.name == rhs.name && + lhs.topLevel == rhs.topLevel + ; +} + +void CategoryAndName::readFromInputStream(CommonAPI::InputStream& inputStream) { + inputStream >> uniqueId; + inputStream >> name; + inputStream >> topLevel; +} + +void CategoryAndName::writeToOutputStream(CommonAPI::OutputStream& outputStream) const { + outputStream << uniqueId; + outputStream << name; + outputStream << topLevel; +} + +CategoryAndReason::CategoryAndReason(const CategoryID& unique_idValue, const uint16_t& reasonValue): + unique_id(unique_idValue), + reason(reasonValue) +{ +} + + +bool operator==(const CategoryAndReason& lhs, const CategoryAndReason& rhs) { + if (&lhs == &rhs) + return true; + + return + lhs.unique_id == rhs.unique_id && + lhs.reason == rhs.reason + ; +} + +void CategoryAndReason::readFromInputStream(CommonAPI::InputStream& inputStream) { + inputStream >> unique_id; + inputStream >> reason; +} + +void CategoryAndReason::writeToOutputStream(CommonAPI::OutputStream& outputStream) const { + outputStream << unique_id; + outputStream << reason; +} + +CategoryAndStatus::CategoryAndStatus(const CategoryID& uniqueIdValue, const bool& statusValue): + uniqueId(uniqueIdValue), + status(statusValue) +{ +} + + +bool operator==(const CategoryAndStatus& lhs, const CategoryAndStatus& rhs) { + if (&lhs == &rhs) + return true; + + return + lhs.uniqueId == rhs.uniqueId && + lhs.status == rhs.status + ; +} + +void CategoryAndStatus::readFromInputStream(CommonAPI::InputStream& inputStream) { + inputStream >> uniqueId; + inputStream >> status; +} + +void CategoryAndStatus::writeToOutputStream(CommonAPI::OutputStream& outputStream) const { + outputStream << uniqueId; + outputStream << status; +} + +PoiAddedDetails::PoiAddedDetails(const std::string& nameValue, const NavigationTypes::Coordinate3D& locationValue, const std::vector& attributesValue): + name(nameValue), + location(locationValue), + attributes(attributesValue) +{ +} + + +bool operator==(const PoiAddedDetails& lhs, const PoiAddedDetails& rhs) { + if (&lhs == &rhs) + return true; + + return + lhs.name == rhs.name && + lhs.location == rhs.location && + lhs.attributes == rhs.attributes + ; +} + +void PoiAddedDetails::readFromInputStream(CommonAPI::InputStream& inputStream) { + inputStream >> name; + inputStream >> location; + inputStream >> attributes; +} + +void PoiAddedDetails::writeToOutputStream(CommonAPI::OutputStream& outputStream) const { + outputStream << name; + outputStream << location; + outputStream << attributes; +} + +Locales::Locales(const std::string& languageCodeValue, const std::string& countryCodeValue, const std::string& scriptCodeValue): + languageCode(languageCodeValue), + countryCode(countryCodeValue), + scriptCode(scriptCodeValue) +{ +} + + +bool operator==(const Locales& lhs, const Locales& rhs) { + if (&lhs == &rhs) + return true; + + return + lhs.languageCode == rhs.languageCode && + lhs.countryCode == rhs.countryCode && + lhs.scriptCode == rhs.scriptCode + ; +} + +void Locales::readFromInputStream(CommonAPI::InputStream& inputStream) { + inputStream >> languageCode; + inputStream >> countryCode; + inputStream >> scriptCode; +} + +void Locales::writeToOutputStream(CommonAPI::OutputStream& outputStream) const { + outputStream << languageCode; + outputStream << countryCode; + outputStream << scriptCode; +} + +} // namespace POIServiceTypes +} // namespace poiservice +} // namespace navigation +} // namespace genivi +} // namespace org diff --git a/api/franca/navigation/src-gen/org/genivi/navigation/poiservice/POIServiceTypes.h b/api/franca/navigation/src-gen/org/genivi/navigation/poiservice/POIServiceTypes.h new file mode 100644 index 0000000..3ab3eec --- /dev/null +++ b/api/franca/navigation/src-gen/org/genivi/navigation/poiservice/POIServiceTypes.h @@ -0,0 +1,1227 @@ +/* +* This file was generated by the CommonAPI Generators. +* Used org.genivi.commonapi.core 2.1.6.v20140519. +* Used org.franca.core 0.8.11.201401091023. +* +* 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 ORG_GENIVI_NAVIGATION_POISERVICE_POI_Service_Types_H_ +#define ORG_GENIVI_NAVIGATION_POISERVICE_POI_Service_Types_H_ + + +#include + +#if !defined (COMMONAPI_INTERNAL_COMPILATION) +#define COMMONAPI_INTERNAL_COMPILATION +#endif + +#include +#include +#include +#include +#include +#include +#include +#include + +#undef COMMONAPI_INTERNAL_COMPILATION + +namespace org { +namespace genivi { +namespace navigation { +namespace poiservice { + +namespace POIServiceTypes { + /** + * Unique ID for a POI results + */ + /** + * Unique ID for a POI results + */ + typedef uint32_t POI_ID; + /** + * Unique ID for a POI Categories + */ + /** + * Unique ID for a POI Categories + */ + typedef uint32_t CategoryID; + /** + * Unique ID for a POI Icon Resource + */ + /** + * Unique ID for a POI Icon Resource + */ + typedef uint32_t ResourceID; + typedef uint32_t AttributeID; + /** + * Current state of the search + */ + enum class SearchStatusState: int32_t { + INVALID, + NOT_STARTED, + SEARCHING, + FINISHED + }; + + // Definition of a comparator still is necessary for GCC 4.4.1, topic is fixed since 4.5.1 + struct SearchStatusStateComparator; + /** + * Type of Attribute + */ + enum class AttributeType: int32_t { + INTEGER, + BOOLEAN, + COORDINATE + }; + + // Definition of a comparator still is necessary for GCC 4.4.1, topic is fixed since 4.5.1 + struct AttributeTypeComparator; + /** + * Type of Operator + */ + enum class OperatorType: int32_t { + INVALID, + MORE_THAN, + LESS_THAN, + EQUAL + }; + + // Definition of a comparator still is necessary for GCC 4.4.1, topic is fixed since 4.5.1 + struct OperatorTypeComparator; + /** + * Reason of update + */ + enum class UpdateReason: int32_t { + ADDED, + REMOVED, + ATTR_ADDED, + ATTR_MODIFIED, + ATTR_REMOVED + }; + + // Definition of a comparator still is necessary for GCC 4.4.1, topic is fixed since 4.5.1 + struct UpdateReasonComparator; + /** + * Different types of resources for icons + */ + /** + * Different types of resources for icons + */ + typedef CommonAPI::Variant, std::string> Icon; + /** + * Differtent type of media + */ + /** + * Differtent type of media + */ + typedef CommonAPI::Variant, std::string> Media; + /** + * values for attributes. + */ + /** + * values for attributes. + */ + typedef CommonAPI::Variant, std::vector, std::vector, std::vector> AttributeValue; + /** + * + */ + /** + * + */ + struct Details: CommonAPI::SerializableStruct { + /** + * list of parent categories unique id. + */ + std::vector parentsId; + /** + * visual icons set. + */ + Icon icons; + /** + * name. + */ + std::string name; + /** + * short category description (optional). + */ + std::string shortDesc; + /** + * media associated (html web site, audio, video, ...) (optional). + */ + Media media; + + Details() = default; + Details(const std::vector& parentsId, const Icon& icons, const std::string& name, const std::string& shortDesc, const Media& media); + + + virtual void readFromInputStream(CommonAPI::InputStream& inputStream); + virtual void writeToOutputStream(CommonAPI::OutputStream& outputStream) const; + + static inline void writeToTypeOutputStream(CommonAPI::TypeOutputStream& typeOutputStream) { + typeOutputStream.beginWriteVectorType(); + typeOutputStream.writeUInt32Type();typeOutputStream.endWriteVectorType(); + typeOutputStream.writeVariantType(); + typeOutputStream.writeStringType(); + typeOutputStream.writeStringType(); + typeOutputStream.writeVariantType(); + } + }; + /** + * + */ + /** + * + */ + struct Operator: CommonAPI::SerializableStruct { + /** + * enum(INVALID,MORE_THAN,LESS_THAN,EQUAL, ....). + */ + OperatorType type; + /** + * localized display name. + */ + std::string name; + /** + * value to use if this comparator is selected. + */ + AttributeValue value; + + Operator() = default; + Operator(const OperatorType& type, const std::string& name, const AttributeValue& value); + + + virtual void readFromInputStream(CommonAPI::InputStream& inputStream); + virtual void writeToOutputStream(CommonAPI::OutputStream& outputStream) const; + + static inline void writeToTypeOutputStream(CommonAPI::TypeOutputStream& typeOutputStream) { + typeOutputStream.writeInt32Type(); + typeOutputStream.writeStringType(); + typeOutputStream.writeVariantType(); + } + }; + /** + * Describes an attribte which is associcated to an category. Use more than one + * operator to specify choice options i.e. differtent accpeted credid cards + * + used in categor details and update category + */ + /** + * Describes an attribte which is associcated to an category. Use more than one + * operator to specify choice options i.e. differtent accpeted credid cards + * + used in categor details and update category + */ + struct CategoryAttribute: CommonAPI::SerializableStruct { + /** + * id of attribute . + */ + AttributeID id; + /** + * localized display name. + */ + std::string name; + /** + * enum(INVALID,STRING,INTEGER,COORDINATES ...). + */ + AttributeType type; + /** + * + */ + std::vector operators; + + CategoryAttribute() = default; + CategoryAttribute(const AttributeID& id, const std::string& name, const AttributeType& type, const std::vector& operators); + + + virtual void readFromInputStream(CommonAPI::InputStream& inputStream); + virtual void writeToOutputStream(CommonAPI::OutputStream& outputStream) const; + + static inline void writeToTypeOutputStream(CommonAPI::TypeOutputStream& typeOutputStream) { + typeOutputStream.writeUInt32Type(); + typeOutputStream.writeStringType(); + typeOutputStream.writeInt32Type(); + typeOutputStream.beginWriteVectorType(); + typeOutputStream.beginWriteStructType(); + typeOutputStream.writeInt32Type();typeOutputStream.writeStringType();typeOutputStream.writeVariantType(); + typeOutputStream.endWriteStructType();typeOutputStream.endWriteVectorType(); + } + }; + /** + * + */ + /** + * + */ + struct CategorySortOption: CommonAPI::SerializableStruct { + /** + * enum(SORT_DEFAULT,SORT_BY_DISTANCE,SORT_BY_TIME,ATTRIBUTE_CUSTOM, ... ). + */ + CategoryID id; + /** + * localized name to be displayed by application. + */ + std::string name; + + CategorySortOption() = default; + CategorySortOption(const CategoryID& id, const std::string& name); + + + virtual void readFromInputStream(CommonAPI::InputStream& inputStream); + virtual void writeToOutputStream(CommonAPI::OutputStream& outputStream) const; + + static inline void writeToTypeOutputStream(CommonAPI::TypeOutputStream& typeOutputStream) { + typeOutputStream.writeUInt32Type(); + typeOutputStream.writeStringType(); + } + }; + /** + * + */ + /** + * + */ + struct CAMCategory: CommonAPI::SerializableStruct { + /** + * struct(list of parents_id, icons, name, short_desc, media). + */ + Details details; + /** + * array[struct(name, type, array[struct(operator_id, operator_name)])]. + */ + std::vector attributes; + /** + * array[struct(id, name)]. + */ + std::vector sortOptions; + + CAMCategory() = default; + CAMCategory(const Details& details, const std::vector& attributes, const std::vector& sortOptions); + + + virtual void readFromInputStream(CommonAPI::InputStream& inputStream); + virtual void writeToOutputStream(CommonAPI::OutputStream& outputStream) const; + + static inline void writeToTypeOutputStream(CommonAPI::TypeOutputStream& typeOutputStream) { + typeOutputStream.beginWriteStructType(); + typeOutputStream.beginWriteVectorType(); + typeOutputStream.writeUInt32Type();typeOutputStream.endWriteVectorType(); + typeOutputStream.writeVariantType();typeOutputStream.writeStringType();typeOutputStream.writeStringType();typeOutputStream.writeVariantType(); + typeOutputStream.endWriteStructType(); + typeOutputStream.beginWriteVectorType(); + typeOutputStream.beginWriteStructType(); + typeOutputStream.writeUInt32Type();typeOutputStream.writeStringType();typeOutputStream.writeInt32Type();typeOutputStream.beginWriteVectorType(); + typeOutputStream.beginWriteStructType(); + typeOutputStream.writeInt32Type();typeOutputStream.writeStringType();typeOutputStream.writeVariantType(); + typeOutputStream.endWriteStructType();typeOutputStream.endWriteVectorType(); + + typeOutputStream.endWriteStructType();typeOutputStream.endWriteVectorType(); + typeOutputStream.beginWriteVectorType(); + typeOutputStream.beginWriteStructType(); + typeOutputStream.writeUInt32Type();typeOutputStream.writeStringType(); + typeOutputStream.endWriteStructType();typeOutputStream.endWriteVectorType(); + } + }; + /** + * + */ + /** + * + */ + struct CAMCategoryUpdate: CommonAPI::SerializableStruct { + /** + * enum(INVALID,ALL_CATEGORIES,AIRPORT,RESTAURANT,HOTEL,GAZ_STATION,CAR_PARK, + * ...). Note: A POI category is a unique ID. It could be a predefined category + * or a custom one defined by a POI plug-in + */ + CategoryID id; + /** + * array[struct(name, type, array[struct(operator_id, operator_name)])]. + */ + std::vector attributes; + /** + * array[struct(id, name)]. + */ + std::vector sortOptions; + + CAMCategoryUpdate() = default; + CAMCategoryUpdate(const CategoryID& id, const std::vector& attributes, const std::vector& sortOptions); + + + virtual void readFromInputStream(CommonAPI::InputStream& inputStream); + virtual void writeToOutputStream(CommonAPI::OutputStream& outputStream) const; + + static inline void writeToTypeOutputStream(CommonAPI::TypeOutputStream& typeOutputStream) { + typeOutputStream.writeUInt32Type(); + typeOutputStream.beginWriteVectorType(); + typeOutputStream.beginWriteStructType(); + typeOutputStream.writeUInt32Type();typeOutputStream.writeStringType();typeOutputStream.writeInt32Type();typeOutputStream.beginWriteVectorType(); + typeOutputStream.beginWriteStructType(); + typeOutputStream.writeInt32Type();typeOutputStream.writeStringType();typeOutputStream.writeVariantType(); + typeOutputStream.endWriteStructType();typeOutputStream.endWriteVectorType(); + + typeOutputStream.endWriteStructType();typeOutputStream.endWriteVectorType(); + typeOutputStream.beginWriteVectorType(); + typeOutputStream.beginWriteStructType(); + typeOutputStream.writeUInt32Type();typeOutputStream.writeStringType(); + typeOutputStream.endWriteStructType();typeOutputStream.endWriteVectorType(); + } + }; + /** + * Attribute associcated to an POI used in addPOI and POI Search Result(both CAM + * and Service) + */ + /** + * Attribute associcated to an POI used in addPOI and POI Search Result(both CAM + * and Service) + */ + struct PoiAttribute: CommonAPI::SerializableStruct { + /** + * attribute unique id (see data model) + */ + AttributeID id; + /** + * enum(INVALID,STRING,INTEGER,COORDINATES ...) + */ + AttributeType type; + /** + * The value depends on the attribute specifications and type + */ + AttributeValue value; + + PoiAttribute() = default; + PoiAttribute(const AttributeID& id, const AttributeType& type, const AttributeValue& value); + + + virtual void readFromInputStream(CommonAPI::InputStream& inputStream); + virtual void writeToOutputStream(CommonAPI::OutputStream& outputStream) const; + + static inline void writeToTypeOutputStream(CommonAPI::TypeOutputStream& typeOutputStream) { + typeOutputStream.writeUInt32Type(); + typeOutputStream.writeInt32Type(); + typeOutputStream.writeVariantType(); + } + }; + /** + * + */ + /** + * + */ + struct CategoryAndRadius: CommonAPI::SerializableStruct { + /** + * enum(INVALID,ALL_CATEGORIES,AIRPORT,RESTAURANT,HOTEL,GAZ_STATION,CAR_PARK, + * ...). Note: A POI category is a unique ID. It could be a predefined category + * or a custom one defined by a POI plug-in + */ + CategoryID id; + /** + * activation or search radius around the position (in 10 meters) for the + * category. If value is 0 (zero), the default radius (defined for a category) is + * applied. + */ + uint32_t radius; + + CategoryAndRadius() = default; + CategoryAndRadius(const CategoryID& id, const uint32_t& radius); + + + virtual void readFromInputStream(CommonAPI::InputStream& inputStream); + virtual void writeToOutputStream(CommonAPI::OutputStream& outputStream) const; + + static inline void writeToTypeOutputStream(CommonAPI::TypeOutputStream& typeOutputStream) { + typeOutputStream.writeUInt32Type(); + typeOutputStream.writeUInt32Type(); + } + }; + /** + * + */ + /** + * + */ + struct PoiDetails: CommonAPI::SerializableStruct { + /** + * POI id + */ + POI_ID id; + /** + * POI name + */ + std::string name; + /** + * POI location. + */ + NavigationTypes::Coordinate3D location; + + PoiDetails() = default; + PoiDetails(const POI_ID& id, const std::string& name, const NavigationTypes::Coordinate3D& location); + + + virtual void readFromInputStream(CommonAPI::InputStream& inputStream); + virtual void writeToOutputStream(CommonAPI::OutputStream& outputStream) const; + + static inline void writeToTypeOutputStream(CommonAPI::TypeOutputStream& typeOutputStream) { + typeOutputStream.writeUInt32Type(); + typeOutputStream.writeStringType(); + typeOutputStream.beginWriteStructType(); + typeOutputStream.writeDoubleType();typeOutputStream.writeDoubleType();typeOutputStream.writeInt32Type(); + typeOutputStream.endWriteStructType(); + } + }; + /** + * + */ + /** + * + */ + struct SearchResultDetails: CommonAPI::SerializableStruct { + /** + * struct(id,name,latitude,longitude,altitude). + */ + PoiDetails details; + /** + * array[unique_id]. + */ + std::vector categories; + /** + * array[struct(name,type,value)]. + */ + std::vector attributes; + + SearchResultDetails() = default; + SearchResultDetails(const PoiDetails& details, const std::vector& categories, const std::vector& attributes); + + + virtual void readFromInputStream(CommonAPI::InputStream& inputStream); + virtual void writeToOutputStream(CommonAPI::OutputStream& outputStream) const; + + static inline void writeToTypeOutputStream(CommonAPI::TypeOutputStream& typeOutputStream) { + typeOutputStream.beginWriteStructType(); + typeOutputStream.writeUInt32Type();typeOutputStream.writeStringType();typeOutputStream.beginWriteStructType(); + typeOutputStream.writeDoubleType();typeOutputStream.writeDoubleType();typeOutputStream.writeInt32Type(); + typeOutputStream.endWriteStructType(); + typeOutputStream.endWriteStructType(); + typeOutputStream.beginWriteVectorType(); + typeOutputStream.writeUInt32Type();typeOutputStream.endWriteVectorType(); + typeOutputStream.beginWriteVectorType(); + typeOutputStream.beginWriteStructType(); + typeOutputStream.writeUInt32Type();typeOutputStream.writeInt32Type();typeOutputStream.writeVariantType(); + typeOutputStream.endWriteStructType();typeOutputStream.endWriteVectorType(); + } + }; + /** + * + */ + /** + * + */ + struct SearchResult: CommonAPI::SerializableStruct { + /** + * POI id + */ + POI_ID id; + /** + * distance in meters to poi from center of the search or from vehicle if search + * along + */ + uint32_t distance; + /** + * enum(OFF_ROUTE,ON_ROUTE,INSIDE_CORRIDOR, ... ) + */ + uint16_t routeStatus; + /** + * List of attributes requested. It could be empty + */ + std::vector attributes; + + SearchResult() = default; + SearchResult(const POI_ID& id, const uint32_t& distance, const uint16_t& routeStatus, const std::vector& attributes); + + + virtual void readFromInputStream(CommonAPI::InputStream& inputStream); + virtual void writeToOutputStream(CommonAPI::OutputStream& outputStream) const; + + static inline void writeToTypeOutputStream(CommonAPI::TypeOutputStream& typeOutputStream) { + typeOutputStream.writeUInt32Type(); + typeOutputStream.writeUInt32Type(); + typeOutputStream.writeUInt16Type(); + typeOutputStream.beginWriteVectorType(); + typeOutputStream.beginWriteStructType(); + typeOutputStream.writeUInt32Type();typeOutputStream.writeInt32Type();typeOutputStream.writeVariantType(); + typeOutputStream.endWriteStructType();typeOutputStream.endWriteVectorType(); + } + }; + /** + * + */ + /** + * + */ + struct PoiCAMDetails: CommonAPI::SerializableStruct { + /** + * POI unique id as known by the content access module. This id will be used by + * POI service to request POI details. + */ + POI_ID sourceId; + /** + * POI name. + */ + std::string name; + /** + * POI category unique id. + */ + CategoryID category; + /** + * POI location. + */ + NavigationTypes::Coordinate3D location; + /** + * distance in meters to poi from center of the search. + */ + uint16_t distance; + /** + * List of attributes requested. It could be empty. + */ + std::vector attributes; + + PoiCAMDetails() = default; + PoiCAMDetails(const POI_ID& sourceId, const std::string& name, const CategoryID& category, const NavigationTypes::Coordinate3D& location, const uint16_t& distance, const std::vector& attributes); + + + virtual void readFromInputStream(CommonAPI::InputStream& inputStream); + virtual void writeToOutputStream(CommonAPI::OutputStream& outputStream) const; + + static inline void writeToTypeOutputStream(CommonAPI::TypeOutputStream& typeOutputStream) { + typeOutputStream.writeUInt32Type(); + typeOutputStream.writeStringType(); + typeOutputStream.writeUInt32Type(); + typeOutputStream.beginWriteStructType(); + typeOutputStream.writeDoubleType();typeOutputStream.writeDoubleType();typeOutputStream.writeInt32Type(); + typeOutputStream.endWriteStructType(); + typeOutputStream.writeUInt16Type(); + typeOutputStream.beginWriteVectorType(); + typeOutputStream.beginWriteStructType(); + typeOutputStream.writeUInt32Type();typeOutputStream.writeInt32Type();typeOutputStream.writeVariantType(); + typeOutputStream.endWriteStructType();typeOutputStream.endWriteVectorType(); + } + }; + /** + * used in setAttrbutes and CAM startPOISearch + */ + /** + * used in setAttrbutes and CAM startPOISearch + */ + struct AttributeDetails: CommonAPI::SerializableStruct { + /** + * id of attribute . + */ + AttributeID id; + /** + * enum(INVALID,ALL_CATEGORIES,AIRPORT,RESTAURANT,HOTEL,GAZ_STATION,CAR_PARK, + * ...). Note: A POI category is a unique ID. It could be a predefined category + * or a custom one defined by a POI plug-in + */ + CategoryID categoryId; + /** + * enum(INVALID,STRING,INTEGER,COORDINATES ...). + */ + AttributeType type; + /** + * value or partial value. The value depends on the attribute specifications and + * type. + */ + AttributeValue value; + /** + * enum(INVALID,MORE_THAN,LESS_THAN,EQUAL, ....). + */ + OperatorType oper; + /** + * true if the attribute is mandatory for the search and false for optional. + */ + bool mandatory; + + AttributeDetails() = default; + AttributeDetails(const AttributeID& id, const CategoryID& categoryId, const AttributeType& type, const AttributeValue& value, const OperatorType& oper, const bool& mandatory); + + + virtual void readFromInputStream(CommonAPI::InputStream& inputStream); + virtual void writeToOutputStream(CommonAPI::OutputStream& outputStream) const; + + static inline void writeToTypeOutputStream(CommonAPI::TypeOutputStream& typeOutputStream) { + typeOutputStream.writeUInt32Type(); + typeOutputStream.writeUInt32Type(); + typeOutputStream.writeInt32Type(); + typeOutputStream.writeVariantType(); + typeOutputStream.writeInt32Type(); + typeOutputStream.writeBoolType(); + } + }; + /** + * Detailed descripton of a category + */ + /** + * Detailed descripton of a category + */ + struct CategoryDetails: CommonAPI::SerializableStruct { + /** + * Category unique id. + */ + CategoryID uniqueId; + /** + * list of parent categories unique id. + */ + std::vector parentsId; + /** + * visual icons set. + */ + Icon icons; + /** + * name. + */ + std::string name; + /** + * true if the category is a pre-defined one (top level), false for customized + * categories created by plug-in. + */ + bool topLevel; + /** + * short category description (optional). + */ + std::string description; + /** + * media associated (html web site, audio, video, ...) (optional). + */ + Media media; + + CategoryDetails() = default; + CategoryDetails(const CategoryID& uniqueId, const std::vector& parentsId, const Icon& icons, const std::string& name, const bool& topLevel, const std::string& description, const Media& media); + + + virtual void readFromInputStream(CommonAPI::InputStream& inputStream); + virtual void writeToOutputStream(CommonAPI::OutputStream& outputStream) const; + + static inline void writeToTypeOutputStream(CommonAPI::TypeOutputStream& typeOutputStream) { + typeOutputStream.writeUInt32Type(); + typeOutputStream.beginWriteVectorType(); + typeOutputStream.writeUInt32Type();typeOutputStream.endWriteVectorType(); + typeOutputStream.writeVariantType(); + typeOutputStream.writeStringType(); + typeOutputStream.writeBoolType(); + typeOutputStream.writeStringType(); + typeOutputStream.writeVariantType(); + } + }; + /** + * Detailed description of a category including attributes and sort options + */ + /** + * Detailed description of a category including attributes and sort options + */ + struct Category: CommonAPI::SerializableStruct { + /** + * struct(unique_id, list of parents_id, icons, name, top_level, short_desc, + * media). + */ + CategoryDetails details; + /** + * array[struct(name, type, array[struct(operator_id, operator_name)]. + */ + std::vector attributes; + /** + * array[struct(id, name)]. + */ + std::vector sortOptions; + + Category() = default; + Category(const CategoryDetails& details, const std::vector& attributes, const std::vector& sortOptions); + + + virtual void readFromInputStream(CommonAPI::InputStream& inputStream); + virtual void writeToOutputStream(CommonAPI::OutputStream& outputStream) const; + + static inline void writeToTypeOutputStream(CommonAPI::TypeOutputStream& typeOutputStream) { + typeOutputStream.beginWriteStructType(); + typeOutputStream.writeUInt32Type();typeOutputStream.beginWriteVectorType(); + typeOutputStream.writeUInt32Type();typeOutputStream.endWriteVectorType(); + typeOutputStream.writeVariantType();typeOutputStream.writeStringType();typeOutputStream.writeBoolType();typeOutputStream.writeStringType();typeOutputStream.writeVariantType(); + typeOutputStream.endWriteStructType(); + typeOutputStream.beginWriteVectorType(); + typeOutputStream.beginWriteStructType(); + typeOutputStream.writeUInt32Type();typeOutputStream.writeStringType();typeOutputStream.writeInt32Type();typeOutputStream.beginWriteVectorType(); + typeOutputStream.beginWriteStructType(); + typeOutputStream.writeInt32Type();typeOutputStream.writeStringType();typeOutputStream.writeVariantType(); + typeOutputStream.endWriteStructType();typeOutputStream.endWriteVectorType(); + + typeOutputStream.endWriteStructType();typeOutputStream.endWriteVectorType(); + typeOutputStream.beginWriteVectorType(); + typeOutputStream.beginWriteStructType(); + typeOutputStream.writeUInt32Type();typeOutputStream.writeStringType(); + typeOutputStream.endWriteStructType();typeOutputStream.endWriteVectorType(); + } + }; + /** + * Pair of catgory and description of level + */ + /** + * Pair of catgory and description of level + */ + struct CategoryAndLevel: CommonAPI::SerializableStruct { + /** + * Category unique id. + */ + CategoryID uniqueId; + /** + * true if the category is a pre-defined one (top level), false for customized + * categories created by plug-in. + */ + bool topLevel; + + CategoryAndLevel() = default; + CategoryAndLevel(const CategoryID& uniqueId, const bool& topLevel); + + + virtual void readFromInputStream(CommonAPI::InputStream& inputStream); + virtual void writeToOutputStream(CommonAPI::OutputStream& outputStream) const; + + static inline void writeToTypeOutputStream(CommonAPI::TypeOutputStream& typeOutputStream) { + typeOutputStream.writeUInt32Type(); + typeOutputStream.writeBoolType(); + } + }; + /** + * pair of category and name + */ + /** + * pair of category and name + */ + struct CategoryAndName: CommonAPI::SerializableStruct { + /** + * Category unique id. + */ + CategoryID uniqueId; + /** + * name. + */ + std::string name; + /** + * true if the category is a pre-defined one (top level), false for customized + * categories created by plug-in. + */ + bool topLevel; + + CategoryAndName() = default; + CategoryAndName(const CategoryID& uniqueId, const std::string& name, const bool& topLevel); + + + virtual void readFromInputStream(CommonAPI::InputStream& inputStream); + virtual void writeToOutputStream(CommonAPI::OutputStream& outputStream) const; + + static inline void writeToTypeOutputStream(CommonAPI::TypeOutputStream& typeOutputStream) { + typeOutputStream.writeUInt32Type(); + typeOutputStream.writeStringType(); + typeOutputStream.writeBoolType(); + } + }; + /** + * pair of category and reson for update + */ + /** + * pair of category and reson for update + */ + struct CategoryAndReason: CommonAPI::SerializableStruct { + /** + * Category unique id. + */ + CategoryID unique_id; + /** + * enum(ADDED,REMOVED,ATTR_ADDED,ATTR_MODIFIED,ATTR_REMOVED, ... ) . + */ + uint16_t reason; + + CategoryAndReason() = default; + CategoryAndReason(const CategoryID& unique_id, const uint16_t& reason); + + + virtual void readFromInputStream(CommonAPI::InputStream& inputStream); + virtual void writeToOutputStream(CommonAPI::OutputStream& outputStream) const; + + static inline void writeToTypeOutputStream(CommonAPI::TypeOutputStream& typeOutputStream) { + typeOutputStream.writeUInt32Type(); + typeOutputStream.writeUInt16Type(); + } + }; + /** + * pair of category and the this category is available + */ + /** + * pair of category and the this category is available + */ + struct CategoryAndStatus: CommonAPI::SerializableStruct { + /** + * Category unique id. + */ + CategoryID uniqueId; + /** + * true if the category is available . + */ + bool status; + + CategoryAndStatus() = default; + CategoryAndStatus(const CategoryID& uniqueId, const bool& status); + + + virtual void readFromInputStream(CommonAPI::InputStream& inputStream); + virtual void writeToOutputStream(CommonAPI::OutputStream& outputStream) const; + + static inline void writeToTypeOutputStream(CommonAPI::TypeOutputStream& typeOutputStream) { + typeOutputStream.writeUInt32Type(); + typeOutputStream.writeBoolType(); + } + }; + /** + * + */ + /** + * + */ + struct PoiAddedDetails: CommonAPI::SerializableStruct { + /** + * POI name + */ + std::string name; + /** + * POI location. + */ + NavigationTypes::Coordinate3D location; + /** + * array[struct(name,type,value)]. + */ + std::vector attributes; + + PoiAddedDetails() = default; + PoiAddedDetails(const std::string& name, const NavigationTypes::Coordinate3D& location, const std::vector& attributes); + + + virtual void readFromInputStream(CommonAPI::InputStream& inputStream); + virtual void writeToOutputStream(CommonAPI::OutputStream& outputStream) const; + + static inline void writeToTypeOutputStream(CommonAPI::TypeOutputStream& typeOutputStream) { + typeOutputStream.writeStringType(); + typeOutputStream.beginWriteStructType(); + typeOutputStream.writeDoubleType();typeOutputStream.writeDoubleType();typeOutputStream.writeInt32Type(); + typeOutputStream.endWriteStructType(); + typeOutputStream.beginWriteVectorType(); + typeOutputStream.beginWriteStructType(); + typeOutputStream.writeUInt32Type();typeOutputStream.writeInt32Type();typeOutputStream.writeVariantType(); + typeOutputStream.endWriteStructType();typeOutputStream.endWriteVectorType(); + } + }; + struct Locales: CommonAPI::SerializableStruct { + /** + * the language used. ISO 639‐3 language code (lower case) + */ + std::string languageCode; + /** + * the country specific variant for the language used. ISO 3166‐1 alpha 3 country + * code (upper case) + */ + std::string countryCode; + /** + * the script specific variant for the language used. ISO 15924 alpha 4 script + * code (upper case) + */ + std::string scriptCode; + + Locales() = default; + Locales(const std::string& languageCode, const std::string& countryCode, const std::string& scriptCode); + + + virtual void readFromInputStream(CommonAPI::InputStream& inputStream); + virtual void writeToOutputStream(CommonAPI::OutputStream& outputStream) const; + + static inline void writeToTypeOutputStream(CommonAPI::TypeOutputStream& typeOutputStream) { + typeOutputStream.writeStringType(); + typeOutputStream.writeStringType(); + typeOutputStream.writeStringType(); + } + }; + +inline CommonAPI::InputStream& operator>>(CommonAPI::InputStream& inputStream, SearchStatusState& enumValue) { + return inputStream.readEnumValue(enumValue); +} + +inline CommonAPI::OutputStream& operator<<(CommonAPI::OutputStream& outputStream, const SearchStatusState& enumValue) { + return outputStream.writeEnumValue(static_cast(enumValue)); +} + +struct SearchStatusStateComparator { + inline bool operator()(const SearchStatusState& lhs, const SearchStatusState& rhs) const { + return static_cast(lhs) < static_cast(rhs); + } +}; + +inline CommonAPI::InputStream& operator>>(CommonAPI::InputStream& inputStream, AttributeType& enumValue) { + return inputStream.readEnumValue(enumValue); +} + +inline CommonAPI::OutputStream& operator<<(CommonAPI::OutputStream& outputStream, const AttributeType& enumValue) { + return outputStream.writeEnumValue(static_cast(enumValue)); +} + +struct AttributeTypeComparator { + inline bool operator()(const AttributeType& lhs, const AttributeType& rhs) const { + return static_cast(lhs) < static_cast(rhs); + } +}; + +inline CommonAPI::InputStream& operator>>(CommonAPI::InputStream& inputStream, OperatorType& enumValue) { + return inputStream.readEnumValue(enumValue); +} + +inline CommonAPI::OutputStream& operator<<(CommonAPI::OutputStream& outputStream, const OperatorType& enumValue) { + return outputStream.writeEnumValue(static_cast(enumValue)); +} + +struct OperatorTypeComparator { + inline bool operator()(const OperatorType& lhs, const OperatorType& rhs) const { + return static_cast(lhs) < static_cast(rhs); + } +}; + +inline CommonAPI::InputStream& operator>>(CommonAPI::InputStream& inputStream, UpdateReason& enumValue) { + return inputStream.readEnumValue(enumValue); +} + +inline CommonAPI::OutputStream& operator<<(CommonAPI::OutputStream& outputStream, const UpdateReason& enumValue) { + return outputStream.writeEnumValue(static_cast(enumValue)); +} + +struct UpdateReasonComparator { + inline bool operator()(const UpdateReason& lhs, const UpdateReason& rhs) const { + return static_cast(lhs) < static_cast(rhs); + } +}; + +bool operator==(const Details& lhs, const Details& rhs); +inline bool operator!=(const Details& lhs, const Details& rhs) { + return !(lhs == rhs); +} +bool operator==(const Operator& lhs, const Operator& rhs); +inline bool operator!=(const Operator& lhs, const Operator& rhs) { + return !(lhs == rhs); +} +bool operator==(const CategoryAttribute& lhs, const CategoryAttribute& rhs); +inline bool operator!=(const CategoryAttribute& lhs, const CategoryAttribute& rhs) { + return !(lhs == rhs); +} +bool operator==(const CategorySortOption& lhs, const CategorySortOption& rhs); +inline bool operator!=(const CategorySortOption& lhs, const CategorySortOption& rhs) { + return !(lhs == rhs); +} +bool operator==(const CAMCategory& lhs, const CAMCategory& rhs); +inline bool operator!=(const CAMCategory& lhs, const CAMCategory& rhs) { + return !(lhs == rhs); +} +bool operator==(const CAMCategoryUpdate& lhs, const CAMCategoryUpdate& rhs); +inline bool operator!=(const CAMCategoryUpdate& lhs, const CAMCategoryUpdate& rhs) { + return !(lhs == rhs); +} +bool operator==(const PoiAttribute& lhs, const PoiAttribute& rhs); +inline bool operator!=(const PoiAttribute& lhs, const PoiAttribute& rhs) { + return !(lhs == rhs); +} +bool operator==(const CategoryAndRadius& lhs, const CategoryAndRadius& rhs); +inline bool operator!=(const CategoryAndRadius& lhs, const CategoryAndRadius& rhs) { + return !(lhs == rhs); +} +bool operator==(const PoiDetails& lhs, const PoiDetails& rhs); +inline bool operator!=(const PoiDetails& lhs, const PoiDetails& rhs) { + return !(lhs == rhs); +} +bool operator==(const SearchResultDetails& lhs, const SearchResultDetails& rhs); +inline bool operator!=(const SearchResultDetails& lhs, const SearchResultDetails& rhs) { + return !(lhs == rhs); +} +bool operator==(const SearchResult& lhs, const SearchResult& rhs); +inline bool operator!=(const SearchResult& lhs, const SearchResult& rhs) { + return !(lhs == rhs); +} +bool operator==(const PoiCAMDetails& lhs, const PoiCAMDetails& rhs); +inline bool operator!=(const PoiCAMDetails& lhs, const PoiCAMDetails& rhs) { + return !(lhs == rhs); +} +bool operator==(const AttributeDetails& lhs, const AttributeDetails& rhs); +inline bool operator!=(const AttributeDetails& lhs, const AttributeDetails& rhs) { + return !(lhs == rhs); +} +bool operator==(const CategoryDetails& lhs, const CategoryDetails& rhs); +inline bool operator!=(const CategoryDetails& lhs, const CategoryDetails& rhs) { + return !(lhs == rhs); +} +bool operator==(const Category& lhs, const Category& rhs); +inline bool operator!=(const Category& lhs, const Category& rhs) { + return !(lhs == rhs); +} +bool operator==(const CategoryAndLevel& lhs, const CategoryAndLevel& rhs); +inline bool operator!=(const CategoryAndLevel& lhs, const CategoryAndLevel& rhs) { + return !(lhs == rhs); +} +bool operator==(const CategoryAndName& lhs, const CategoryAndName& rhs); +inline bool operator!=(const CategoryAndName& lhs, const CategoryAndName& rhs) { + return !(lhs == rhs); +} +bool operator==(const CategoryAndReason& lhs, const CategoryAndReason& rhs); +inline bool operator!=(const CategoryAndReason& lhs, const CategoryAndReason& rhs) { + return !(lhs == rhs); +} +bool operator==(const CategoryAndStatus& lhs, const CategoryAndStatus& rhs); +inline bool operator!=(const CategoryAndStatus& lhs, const CategoryAndStatus& rhs) { + return !(lhs == rhs); +} +bool operator==(const PoiAddedDetails& lhs, const PoiAddedDetails& rhs); +inline bool operator!=(const PoiAddedDetails& lhs, const PoiAddedDetails& rhs) { + return !(lhs == rhs); +} +bool operator==(const Locales& lhs, const Locales& rhs); +inline bool operator!=(const Locales& lhs, const Locales& rhs) { + return !(lhs == rhs); +} + + +static inline const char* getTypeCollectionName() { + static const char* typeCollectionName = "org.genivi.navigation.poiservice.POIServiceTypes"; + return typeCollectionName; +} + +inline CommonAPI::Version getTypeCollectionVersion() { + return CommonAPI::Version(0, 1); +} + +} // namespace POIServiceTypes + +} // namespace poiservice +} // namespace navigation +} // namespace genivi +} // namespace org + +namespace CommonAPI { + + template<> + struct BasicTypeWriter { + inline static void writeType (CommonAPI::TypeOutputStream& typeStream) { + typeStream.writeInt32EnumType(); + } + }; + + template<> + struct InputStreamVectorHelper { + static void beginReadVector(InputStream& inputStream, const std::vector& vectorValue) { + inputStream.beginReadInt32EnumVector(); + } + }; + + template <> + struct OutputStreamVectorHelper { + static void beginWriteVector(OutputStream& outputStream, const std::vector& vectorValue) { + outputStream.beginWriteInt32EnumVector(vectorValue.size()); + } + }; + template<> + struct BasicTypeWriter { + inline static void writeType (CommonAPI::TypeOutputStream& typeStream) { + typeStream.writeInt32EnumType(); + } + }; + + template<> + struct InputStreamVectorHelper { + static void beginReadVector(InputStream& inputStream, const std::vector& vectorValue) { + inputStream.beginReadInt32EnumVector(); + } + }; + + template <> + struct OutputStreamVectorHelper { + static void beginWriteVector(OutputStream& outputStream, const std::vector& vectorValue) { + outputStream.beginWriteInt32EnumVector(vectorValue.size()); + } + }; + template<> + struct BasicTypeWriter { + inline static void writeType (CommonAPI::TypeOutputStream& typeStream) { + typeStream.writeInt32EnumType(); + } + }; + + template<> + struct InputStreamVectorHelper { + static void beginReadVector(InputStream& inputStream, const std::vector& vectorValue) { + inputStream.beginReadInt32EnumVector(); + } + }; + + template <> + struct OutputStreamVectorHelper { + static void beginWriteVector(OutputStream& outputStream, const std::vector& vectorValue) { + outputStream.beginWriteInt32EnumVector(vectorValue.size()); + } + }; + template<> + struct BasicTypeWriter { + inline static void writeType (CommonAPI::TypeOutputStream& typeStream) { + typeStream.writeInt32EnumType(); + } + }; + + template<> + struct InputStreamVectorHelper { + static void beginReadVector(InputStream& inputStream, const std::vector& vectorValue) { + inputStream.beginReadInt32EnumVector(); + } + }; + + template <> + struct OutputStreamVectorHelper { + static void beginWriteVector(OutputStream& outputStream, const std::vector& vectorValue) { + outputStream.beginWriteInt32EnumVector(vectorValue.size()); + } + }; + +} + + +namespace std { + //Hash for SearchStatusState + template<> + struct hash { + inline size_t operator()(const org::genivi::navigation::poiservice::POIServiceTypes::SearchStatusState& searchStatusState) const { + return static_cast(searchStatusState); + } + }; + //Hash for AttributeType + template<> + struct hash { + inline size_t operator()(const org::genivi::navigation::poiservice::POIServiceTypes::AttributeType& attributeType) const { + return static_cast(attributeType); + } + }; + //Hash for OperatorType + template<> + struct hash { + inline size_t operator()(const org::genivi::navigation::poiservice::POIServiceTypes::OperatorType& operatorType) const { + return static_cast(operatorType); + } + }; + //Hash for UpdateReason + template<> + struct hash { + inline size_t operator()(const org::genivi::navigation::poiservice::POIServiceTypes::UpdateReason& updateReason) const { + return static_cast(updateReason); + } + }; +} + +#endif // ORG_GENIVI_NAVIGATION_POISERVICE_POI_Service_Types_H_ diff --git a/src/poi-service/poi-manager-server/poi-manager-server-stub.cpp b/src/poi-service/poi-manager-server/poi-manager-server-stub.cpp index 3f9de45..0da7842 100644 --- a/src/poi-service/poi-manager-server/poi-manager-server-stub.cpp +++ b/src/poi-service/poi-manager-server/poi-manager-server-stub.cpp @@ -40,7 +40,7 @@ sqlRequest::~sqlRequest() sqlRequest::SQL_REQUEST_ERRORS sqlRequest::setDatabase(const char *poiDatabaseFileName) { mp_database = new Database(poiDatabaseFileName); - return sqlRequest::OK; //todo check if database OK + return OK; //todo check if database OK } void sqlRequest::onError() @@ -211,6 +211,10 @@ sqlRequest::SQL_REQUEST_ERRORS sqlRequest::createCategory(POIServiceTypes::CAMCa { sqlRequest::SQL_REQUEST_ERRORS ret; size_t index; + std::string sqlQuery; //SQL request on database + vector > query_result; + vector query_line; + std::ostringstream strStream; //temporary stream used for transformation into string //Check if all the parent categories exist for (index=0;index < category.details.parentsId.size();index++) @@ -222,13 +226,69 @@ sqlRequest::SQL_REQUEST_ERRORS sqlRequest::createCategory(POIServiceTypes::CAMCa //Check if the name doesn't exist into the database to avoid duplications ret = checkIfCategoryNameDoesntExist(category.details.name); - if (ret == OK) + if (ret != OK) + return ret; + + //Get a free id (poicategory) + ret = getFreeCategoryId(unique_id); + if (ret != OK) + return ret; + + //Create the category + sqlQuery = m_SQL_REQUEST_INSERT_CATEGORY; + strStream.str(""); + strStream << unique_id; + sqlQuery += strStream.str(); + sqlQuery += ",'"; + sqlQuery.append(category.details.name); + sqlQuery += "');"; + query_result = mp_database->queryNotUTF(sqlQuery.c_str()); + if (!query_result.empty()) { - //Now create the new category and get the unique id + onError(); //database is not well populated + //todo something with table ? + ret = DATABASE_ACCESS_ERROR; + return ret; + } + //Check the attributes and complete the table if necessary (poiattribute) + for (index=0;index < category.attributes.size();index++) + { + ret = checkIfAttributeExist((category.attributes.at(index)).id); + if (ret == ATTRIBUTE_ID_NOT_EXIST) + { + //Create the attribute + sqlQuery = m_SQL_REQUEST_INSERT_ATTRIBUTE; + strStream.str(""); + strStream << (category.attributes.at(index)).id; + sqlQuery += strStream.str(); + sqlQuery += ",'"; + sqlQuery.append((category.attributes.at(index)).name); + sqlQuery += "');"; + query_result = mp_database->queryNotUTF(sqlQuery.c_str()); + if (!query_result.empty()) + { + onError(); //database is not well populated + //todo something with table ? + ret = DATABASE_ACCESS_ERROR; + return ret; + } + } + else + { + if (ret != OK) + return ret; + } } + //Complete the table of attributes for the category (hasattribute) + + //Complete the table of family categories (poicategorykinship) + + //Complete the table of icons (iconset and isdisplayedas) + + return ret; } @@ -241,10 +301,13 @@ sqlRequest::SQL_REQUEST_ERRORS sqlRequest::checkIfCategoryNameDoesntExist(std::s sqlRequest::SQL_REQUEST_ERRORS ret; bool retSqlRequest; - sqlQuery = m_SQL_CHECK_IF_CATEGORY_NAME_EXIST; + sqlQuery = m_SQL_REQUEST_CHECK_IF_CATEGORY_NAME_EXIST; strStream.str(""); strStream << name; + sqlQuery += "'"; sqlQuery += strStream.str(); + sqlQuery += "'"; + sqlQuery += ")"; sqlQuery += m_SQL_RETURN_BOOL_VALUE; query_result = mp_database->queryNotUTF(sqlQuery.c_str()); if (query_result.empty()) @@ -275,10 +338,11 @@ sqlRequest::SQL_REQUEST_ERRORS sqlRequest::checkIfCategoryIdExist(POIServiceType sqlRequest::SQL_REQUEST_ERRORS ret; bool retSqlRequest; - sqlQuery = m_SQL_CHECK_IF_CATEGORY_ID_EXIST; + sqlQuery = m_SQL_REQUEST_CHECK_IF_CATEGORY_ID_EXIST; strStream.str(""); strStream << unique_id; sqlQuery += strStream.str(); + sqlQuery += ")"; sqlQuery += m_SQL_RETURN_BOOL_VALUE; query_result = mp_database->queryNotUTF(sqlQuery.c_str()); if (query_result.empty()) @@ -304,12 +368,94 @@ sqlRequest::SQL_REQUEST_ERRORS sqlRequest::removeCategory(POIServiceTypes::Categ { sqlRequest::SQL_REQUEST_ERRORS ret; + ret = OK; + return ret; } +sqlRequest::SQL_REQUEST_ERRORS sqlRequest::getFreeCategoryId(POIServiceTypes::CategoryID& unique_id) +{ + sqlRequest::SQL_REQUEST_ERRORS ret; + vector > query_result; + vector query_line; + // retrieve the next free category id + query_result = mp_database->queryNotUTF(m_SQL_REQUEST_GET_AVAILABLE_NEXT_FREE_CATEGORY_ID); + if (query_result.empty()) + { + onError(); //database is not well populated + //todo something with table ? + ret = DATABASE_ACCESS_ERROR; + } + else + { // Id + query_line = query_result.at(0); + fromString(unique_id,query_line[0], std::dec); + ret = OK; + } + return ret; +} + +sqlRequest::SQL_REQUEST_ERRORS sqlRequest::getFreeAttributeId(POIServiceTypes::AttributeID &unique_id) +{ + sqlRequest::SQL_REQUEST_ERRORS ret; + vector > query_result; + vector query_line; + + // retrieve the next free category id + query_result = mp_database->queryNotUTF(m_SQL_REQUEST_GET_AVAILABLE_NEXT_FREE_ATTRIBUTE_ID); + if (query_result.empty()) + { + onError(); //database is not well populated + //todo something with table ? + ret = DATABASE_ACCESS_ERROR; + } + else + { // Id + query_line = query_result.at(0); + fromString(unique_id,query_line[0], std::dec); + ret = OK; + } + + return ret; +} + +sqlRequest::SQL_REQUEST_ERRORS sqlRequest::checkIfAttributeExist(POIServiceTypes::AttributeID unique_id) +{ + std::string sqlQuery; //SQL request on database + vector > query_result; + vector query_line; + std::ostringstream strStream; //temporary stream used for transformation into string + sqlRequest::SQL_REQUEST_ERRORS ret; + bool retSqlRequest; + + sqlQuery = m_SQL_REQUEST_CHECK_IF_ATTRIBUTE_ID_EXIST; + strStream.str(""); + strStream << unique_id; + sqlQuery += strStream.str(); + sqlQuery += ")"; + sqlQuery += m_SQL_RETURN_BOOL_VALUE; + query_result = mp_database->queryNotUTF(sqlQuery.c_str()); + if (query_result.empty()) + { + onError(); //database is not well populated + //todo something with table ? + ret = DATABASE_ACCESS_ERROR; + } + else + { + // read the result of the query + query_line = query_result.at(0); + fromString(retSqlRequest,query_line[0], std::dec); + if (retSqlRequest) + ret = OK; + else + ret = ATTRIBUTE_ID_NOT_EXIST; + } + return ret; +} PoiManagerServerStub::PoiManagerServerStub() { m_version.versionMajor = 1; @@ -405,12 +551,28 @@ void PoiManagerServerStub::getChildrenCategories(const std::shared_ptr clientId, POIServiceTypes::CAMCategory category, POIServiceTypes::CategoryID& unique_id) { - + mp_sqlRequest->createCategory(category,unique_id); + refreshCategoryList(); } void PoiManagerServerStub::removeCategories(const std::shared_ptr clientId, std::vector categories) { + size_t index; + for(index=0;indexremoveCategory(categories.at(index)) != sqlRequest::OK) + break; + } + if (index clientId, POIServiceTypes::CategoryID unique_id, std::vector poiList) @@ -427,6 +589,25 @@ bool PoiManagerServerStub::initDatabase(const char* poiDatabaseFileName) { mp_sqlRequest->setDatabase(poiDatabaseFileName); refreshCategoryList(); //read the database and buffer the category list locally + + POIServiceTypes::CAMCategory category; + POIServiceTypes::CategoryAttribute attribute; + POIServiceTypes::CategoryID unique_id; + + category.details.name = "recreation"; + attribute.id = 2; + attribute.name = "phone"; + category.attributes.push_back(attribute); + attribute.id = 13; + attribute.name = "credit card"; + category.attributes.push_back(attribute); + category.details.parentsId.push_back(0); + mp_sqlRequest->createCategory(category,unique_id); + refreshCategoryList(); //read the database and buffer the category list locally + + mp_sqlRequest->removeCategory(unique_id); + refreshCategoryList(); //read the database and buffer the category list locally + return true; //maybe add some check of the file here } diff --git a/src/poi-service/poi-manager-server/poi-manager-server-stub.h b/src/poi-service/poi-manager-server/poi-manager-server-stub.h index 9880e31..c5bb1f9 100644 --- a/src/poi-service/poi-manager-server/poi-manager-server-stub.h +++ b/src/poi-service/poi-manager-server/poi-manager-server-stub.h @@ -50,6 +50,7 @@ public: CATEGORY_NOT_EXIST, CATEGORY_NAME_ALREADY_EXIST, CATEGORY_ID_NOT_EXIST, + ATTRIBUTE_ID_NOT_EXIST, PARENT_CATEGORY_NOT_EXIST, DATABASE_ACCESS_ERROR, OK @@ -70,12 +71,18 @@ private: const char* m_SQL_REQUEST_GET_CHILD_CATEGORIES = "SELECT childId FROM poicategorykinship WHERE parentId IS "; const char* m_SQL_REQUEST_GET_CATEGORY_ICONS = "SELECT url,format FROM iconset WHERE Id IS (SELECT iconset_Id FROM isdisplayedas WHERE poicategory_Id IS "; const char* m_SQL_REQUEST_GET_AVAILABLE_NEXT_FREE_CATEGORY_ID = "SELECT a.id+1 FROM poicategory a WHERE NOT EXISTS (SELECT * FROM poicategory b WHERE a.id+1 = b.id) ORDER BY a.id"; + const char* m_SQL_REQUEST_GET_AVAILABLE_NEXT_FREE_ATTRIBUTE_ID = "SELECT a.id+1 FROM poiattribute a WHERE NOT EXISTS (SELECT * FROM poicategory b WHERE a.id+1 = b.id) ORDER BY a.id"; const char* m_SQL_REQUEST_GET_AVAILABLE_NEXT_FREE_POI_ID = "SELECT a.id+1 FROM poi a WHERE NOT EXISTS (SELECT * FROM poi b WHERE a.id+1 = b.id) ORDER BY a.id"; - const char* m_SQL_INSERT_CATEGORY = "INSERT INTO poicategory VALUES ("; - const char* m_SQL_DELETE_CATEGORY = "DELETE from poicategory WHERE id = "; - const char* m_SQL_CHECK_IF_CATEGORY_ID_EXIST = "SELECT CASE WHEN EXISTS (SELECT * FROM poicategory WHERE id = "; - const char* m_SQL_CHECK_IF_CATEGORY_NAME_EXIST = "SELECT CASE WHEN EXISTS (SELECT * FROM poicategory WHERE name = "; - const char* m_SQL_RETURN_BOOL_VALUE = "THEN CAST(1 AS BIT) ELSE CAST(0 AS BIT) END"; + const char* m_SQL_REQUEST_INSERT_CATEGORY = "INSERT INTO poicategory VALUES ("; + const char* m_SQL_REQUEST_DELETE_CATEGORY = "DELETE from poicategory WHERE id = "; + const char* m_SQL_REQUEST_CHECK_IF_CATEGORY_ID_EXIST = "SELECT CASE WHEN EXISTS (SELECT * FROM poicategory WHERE id = "; + const char* m_SQL_REQUEST_CHECK_IF_CATEGORY_NAME_EXIST = "SELECT CASE WHEN EXISTS (SELECT * FROM poicategory WHERE name = "; + const char* m_SQL_REQUEST_INSERT_ATTRIBUTE = "INSERT INTO poiattribute VALUES ("; + const char* m_SQL_REQUEST_DELETE_ATTRIBUTE = "DELETE from poiattribute WHERE id = "; + const char* m_SQL_REQUEST_CHECK_IF_ATTRIBUTE_ID_EXIST = "SELECT CASE WHEN EXISTS (SELECT * FROM poiattribute WHERE id = "; + const char* m_SQL_REQUEST_GET_POI_PROVIDER_ID = "(SELECT Id FROM poiprovider WHERE name='OpenStreetMap')"; + const char* m_SQL_RETURN_BOOL_VALUE = " THEN CAST(1 AS BIT) ELSE CAST(0 AS BIT) END;"; + const char* m_SQL_REQUEST_INSERT_BELONGSTO = "INSERT INTO belongsto (Id,poiprovider_Id,poicategory_Id,poi_Id) "; Database *mp_database; // database access @@ -93,6 +100,12 @@ private: SQL_REQUEST_ERRORS checkIfCategoryIdExist(POIServiceTypes::CategoryID unique_id); + SQL_REQUEST_ERRORS checkIfAttributeExist(POIServiceTypes::AttributeID unique_id); + + SQL_REQUEST_ERRORS getFreeCategoryId(POIServiceTypes::CategoryID &unique_id); + + SQL_REQUEST_ERRORS getFreeAttributeId(POIServiceTypes::AttributeID &unique_id); + void getAvailableArea(); NavigationTypes::Coordinate2D m_leftBottomLocation,m_rightTopLocation; diff --git a/src/poi-service/script/build-for-commonapi.sh b/src/poi-service/script/build-for-commonapi.sh new file mode 100755 index 0000000..4a14a26 --- /dev/null +++ b/src/poi-service/script/build-for-commonapi.sh @@ -0,0 +1,77 @@ +#!/bin/bash + +########################################################################### +# @licence app begin@ +# SPDX-License-Identifier: MPL-2.0 +# +# Component Name: poi-server +# Author: Philippe Colliot +# +# Copyright (C) 2013-2014, PCA Peugeot Citroen +# +# License: +# 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/. +# +# @licence end@ +########################################################################### +POI_MANAGER_SERVER=poi-manager-server + +target_root=$PWD/.. +target_bin=$PWD/../bin #by default + +set-path() +{ + TOP_DIR=$target_root + TOP_BIN_DIR=$target_bin + POI_MANAGER_SERVER_SRC_DIR=$TOP_DIR/$POI_MANAGER_SERVER + POI_MANAGER_SERVER_BIN_DIR=$TOP_BIN_DIR/$POI_MANAGER_SERVER +} + +usage() { + echo "Usage: ./build.sh [command]" + echo + echo "command:" + echo " make Build" + echo " clean Clean" + echo " help Print Help" + echo + echo +} + +build() { + + echo '' + echo 'Building poi-manager-server' + + cd $TOP_BIN_DIR + mkdir -p $POI_MANAGER_SERVER + cd $POI_MANAGER_SERVER_BIN_DIR + cmake -DCOMMON_API_PATH_GENERATED_FILES=../../../api/franca/navigation/src-gen -DDBUS_LIB_PATH=/usr/local/lib $POI_MANAGER_SERVER_SRC_DIR && make + +} + +clean() { + echo 'delete' $TOP_BIN_DIR + rm -rf $TOP_BIN_DIR +} + + +set -e + +if [ $# -ge 1 ]; then + if [ $1 = help ]; then + usage + elif [ $1 = make ]; then + set-path + build + elif [ $1 = clean ]; then + set-path + clean + else + usage + fi +else + usage +fi diff --git a/src/poi-service/script/build.sh b/src/poi-service/script/build.sh index c02195e..3fc0f1a 100755 --- a/src/poi-service/script/build.sh +++ b/src/poi-service/script/build.sh @@ -17,7 +17,6 @@ # @licence end@ ########################################################################### POI_SERVER=poi-server -POI_MANAGER_SERVER=poi-manager-server POI_COMMON=poi-common NAVIGATION_CORE=navigation-core MAP_VIEWER=map-viewer @@ -34,8 +33,6 @@ set-path() POI_SERVER_SRC_DIR=$TOP_DIR/$POI_SERVER POI_SERVER_BIN_DIR=$TOP_BIN_DIR/$POI_SERVER - POI_MANAGER_SERVER_SRC_DIR=$TOP_DIR/$POI_MANAGER_SERVER - POI_MANAGER_SERVER_BIN_DIR=$TOP_BIN_DIR/$POI_MANAGER_SERVER POI_COMMON_SRC_DIR=$TOP_DIR/$POI_COMMON } @@ -68,15 +65,6 @@ build() { mkdir -p $POI_SERVER cd $POI_SERVER_BIN_DIR cmake -Dapi_DIR=$API_DIR -Dgenerated_api_DIR=$GENERATED_API_DIR $POI_SERVER_SRC_DIR && make - - echo '' - echo 'Building poi-manager-server' - - cd $TOP_BIN_DIR - mkdir -p $POI_MANAGER_SERVER - cd $POI_MANAGER_SERVER_BIN_DIR - cmake -DCOMMON_API_PATH_GENERATED_FILES=../../../api/franca/navigation/src-gen -DDBUS_LIB_PATH=/usr/local/lib $POI_MANAGER_SERVER_SRC_DIR && make - } clean() { -- cgit v1.2.1