summaryrefslogtreecommitdiff
path: root/implementation/routing/include/routing_manager_host.hpp
blob: a80b86dfa1ed5f3a7d28290615a1dd6db7457e01 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
// Copyright (C) 2014-2015 Bayerische Motoren Werke Aktiengesellschaft (BMW AG)
// 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 VSOMEIP_ROUTING_MANAGER_HOST
#define VSOMEIP_ROUTING_MANAGER_HOST

#include <memory>

#include <boost/asio/io_service.hpp>

#include <vsomeip/error.hpp>

namespace vsomeip {

class configuration;
class message;

class routing_manager_host {
public:
    virtual ~routing_manager_host() {
    }

    virtual client_t get_client() const = 0;
    virtual const std::string & get_name() const = 0;
    virtual std::shared_ptr<configuration> get_configuration() const = 0;
    virtual boost::asio::io_service & get_io() = 0;

    virtual void on_availability(service_t _service, instance_t _instance,
    bool _is_available) const = 0;
    virtual void on_event(event_type_e _event) = 0;
    virtual void on_message(std::shared_ptr<message> _message) = 0;
    virtual void on_error(error_code_e _error) = 0;
    virtual bool on_subscription(service_t _service, instance_t _instance, eventgroup_t _eventgroup,
            client_t _client, bool _subscribed) = 0;
};

} // namespace vsomeip

#endif // VSOMEIP_ROUTING_MANAGER_HOST