GNU Radio's OsmoSDR Package
osmosdr_sink_c.h
Go to the documentation of this file.
1 /* -*- c++ -*- */
2 /*
3  * Copyright 2012 Dimitri Stolnikov <horiz0n@gmx.net>
4  *
5  * GNU Radio is free software; you can redistribute it and/or modify
6  * it under the terms of the GNU General Public License as published by
7  * the Free Software Foundation; either version 3, or (at your option)
8  * any later version.
9  *
10  * GNU Radio is distributed in the hope that it will be useful,
11  * but WITHOUT ANY WARRANTY; without even the implied warranty of
12  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13  * GNU General Public License for more details.
14  *
15  * You should have received a copy of the GNU General Public License
16  * along with GNU Radio; see the file COPYING. If not, write to
17  * the Free Software Foundation, Inc., 51 Franklin Street,
18  * Boston, MA 02110-1301, USA.
19  */
20 #ifndef INCLUDED_OSMOSDR_SINK_C_H
21 #define INCLUDED_OSMOSDR_SINK_C_H
22 
23 #include <osmosdr/osmosdr_api.h>
24 #include <gnuradio/gr_hier_block2.h>
25 
26 class osmosdr_sink_c;
27 
28 /*
29  * We use boost::shared_ptr's instead of raw pointers for all access
30  * to gr_blocks (and many other data structures). The shared_ptr gets
31  * us transparent reference counting, which greatly simplifies storage
32  * management issues. This is especially helpful in our hybrid
33  * C++ / Python system.
34  *
35  * See http://www.boost.org/libs/smart_ptr/smart_ptr.htm
36  *
37  * As a convention, the _sptr suffix indicates a boost::shared_ptr
38  */
39 typedef boost::shared_ptr<osmosdr_sink_c> osmosdr_sink_c_sptr;
40 
41 /*!
42  * \brief Return a shared_ptr to a new instance of osmosdr_sink_c.
43  *
44  * To avoid accidental use of raw pointers, osmosdr_sink_c's
45  * constructor is private. osmosdr_make_sink_c is the public
46  * interface for creating new instances.
47  */
48 OSMOSDR_API osmosdr_sink_c_sptr osmosdr_make_sink_c ( const std::string & args = "" );
49 
50 /*!
51  * \brief Takes a stream of complex samples.
52  * \ingroup block
53  *
54  * This uses the preferred technique: subclassing gr_hier_block2.
55  */
56 class OSMOSDR_API osmosdr_sink_c : virtual public gr_hier_block2
57 {
58 public:
59 
60 };
61 
62 #endif /* INCLUDED_OSMOSDR_SINK_C_H */