Route.cci
Go to the documentation of this file.
1 //
2 // Copyright (c) 2020 Fraunhofer Institute for Applied Information Technology (FIT)
3 // Network Research Group (NET)
4 // Schloss Birlinghoven, 53754 Sankt Augustin, GERMANY
5 // Contact: support@wiback.org
6 //
7 // This file is part of the SENF code tree.
8 // It is licensed under the 3-clause BSD License (aka New BSD License).
9 // See LICENSE.txt in the top level directory for details or visit
10 // https://opensource.org/licenses/BSD-3-Clause
11 //
12 
13 
14 /** \file
15  \brief Route inline non-template implementation */
16 
17 // Custom includes
18 #include "Connectors.hh"
19 #include "Events.hh"
20 
21 #define prefix_ inline
22 //-/////////////////////////////////////////////////////////////////////////////////////////////////
23 
24 //-/////////////////////////////////////////////////////////////////////////////////////////////////
25 // senf::ppi::RouteBase
26 
27 prefix_ senf::ppi::RouteBase::~RouteBase()
28 {}
29 
30 prefix_ bool senf::ppi::RouteBase::hasConnector(connector::Connector const & conn)
31  const
32 {
33  return v_hasConnector(conn);
34 }
35 
36 prefix_ bool senf::ppi::RouteBase::hasEvent(EventDescriptor const & event)
37  const
38 {
39  return v_hasEvent(event);
40 }
41 
42 //-/////////////////////////////////////////////////////////////////////////////////////////////////
43 // protected members
44 
45 prefix_ senf::ppi::RouteBase::RouteBase()
46 {}
47 
48 //-/////////////////////////////////////////////////////////////////////////////////////////////////
49 // senf::ppi::ForwardingRoute
50 
51 prefix_ bool senf::ppi::ForwardingRoute::autoThrottling()
52  const
53 {
54  return autoThrottling_;
55 }
56 
57 prefix_ void senf::ppi::ForwardingRoute::autoThrottling(bool state)
58 {
59  autoThrottling_ = state;
60 }
61 
62 prefix_ bool senf::ppi::ForwardingRoute::throttled()
63  const
64 {
65  return v_throttled();
66 }
67 
68 //-/////////////////////////////////////////////////////////////////////////////////////////////////
69 // protected members
70 
71 prefix_ senf::ppi::ForwardingRoute::ForwardingRoute()
72  : autoThrottling_(true)
73 {}
74 
75 //-/////////////////////////////////////////////////////////////////////////////////////////////////
76 // private members
77 
78 prefix_ void senf::ppi::ForwardingRoute::notifyThrottle()
79 {
80  v_notifyThrottle();
81 }
82 
83 prefix_ void senf::ppi::ForwardingRoute::notifyUnthrottle()
84 {
85  v_notifyUnthrottle();
86 }
87 
88 //-/////////////////////////////////////////////////////////////////////////////////////////////////
89 #undef prefix_
90 
91 
92 // Local Variables:
93 // mode: c++
94 // fill-column: 100
95 // comment-column: 40
96 // c-file-style: "senf"
97 // indent-tabs-mode: nil
98 // ispell-local-dictionary: "american"
99 // compile-command: "scons -u test"
100 // End: