1 // Copyright (C) 2014-2017 Bayerische Motoren Werke Aktiengesellschaft (BMW AG) 2 // This Source Code Form is subject to the terms of the Mozilla Public 3 // License, v. 2.0. If a copy of the MPL was not distributed with this 4 // file, You can obtain one at http://mozilla.org/MPL/2.0/. 5 6 #ifndef VSOMEIP_V3_ROUTING_HOST_ 7 #define VSOMEIP_V3_ROUTING_HOST_ 8 9 #include <memory> 10 11 #include <boost/asio/ip/address.hpp> 12 13 #include <vsomeip/primitive_types.hpp> 14 15 #ifdef ANDROID 16 #include "../../configuration/include/internal_android.hpp" 17 #else 18 #include "../../configuration/include/internal.hpp" 19 #endif // ANDROID 20 21 namespace vsomeip_v3 { 22 23 class endpoint; 24 25 class routing_host { 26 public: 27 virtual ~routing_host() = default; 28 29 virtual void on_message(const byte_t *_data, length_t _length, 30 endpoint *_receiver, 31 const boost::asio::ip::address &_destination = 32 boost::asio::ip::address(), 33 client_t _bound_client = VSOMEIP_ROUTING_CLIENT, 34 credentials_t _credentials = {ANY_UID, ANY_GID}, 35 const boost::asio::ip::address &_remote_address = 36 boost::asio::ip::address(), 37 std::uint16_t _remote_port = 0) = 0; 38 39 virtual client_t get_client() const = 0; 40 }; 41 42 } // namespace vsomeip_v3 43 44 #endif // VSOMEIP_V3_ROUTING_HOST_ 45