USRP Hardware Driver and USRP Manual  Version: 3.11.0.HEAD-0-ga1b5c4ae
UHD and USRP Manual
zero_copy_flow_ctrl.hpp
Go to the documentation of this file.
1 //
2 // Copyright 2017 Ettus Research
3 // Copyright 2018 Ettus Research, a National Instruments Company
4 //
5 // SPDX-License-Identifier: GPL-3.0-or-later
6 //
7 
8 #ifndef INCLUDED_ZERO_COPY_FLOW_CTRL_HPP
9 #define INCLUDED_ZERO_COPY_FLOW_CTRL_HPP
10 
11 #include <uhd/config.hpp>
13 #include <boost/function.hpp>
14 #include <boost/shared_ptr.hpp>
15 
16 namespace uhd{ namespace transport{
17 
23 typedef boost::function<bool(managed_buffer::sptr buff)> flow_ctrl_func;
24 
28 class UHD_API zero_copy_flow_ctrl : public virtual zero_copy_if {
29 public:
30  typedef boost::shared_ptr<zero_copy_flow_ctrl> sptr;
31 
39  static sptr make(
40  zero_copy_if::sptr transport,
41  flow_ctrl_func send_flow_ctrl,
42  flow_ctrl_func recv_flow_ctrl
43  );
44 };
45 
46 }} //namespace
47 
48 #endif /* INCLUDED_ZERO_COPY_FLOW_CTRL_HPP */
Definition: zero_copy_flow_ctrl.hpp:28
boost::shared_ptr< zero_copy_if > sptr
Definition: zero_copy.hpp:144
Definition: build_info.hpp:14
boost::function< bool(managed_buffer::sptr buff)> flow_ctrl_func
Definition: zero_copy_flow_ctrl.hpp:23
#define UHD_API
Definition: config.h:63
Definition: zero_copy.hpp:142
boost::shared_ptr< zero_copy_flow_ctrl > sptr
Definition: zero_copy_flow_ctrl.hpp:30