diff options
author | Eric Blossom | 2010-10-18 20:58:22 -0700 |
---|---|---|
committer | Eric Blossom | 2010-11-10 12:10:46 -0800 |
commit | 31661e655660a77c28cf14fcb5f648ea05505450 (patch) | |
tree | 2ec8bf4cf3735364ca39c7acef71f8798a40dccf /gnuradio-core/src/lib | |
parent | d169bfeee38f883cbf6b7ddf41ce8645a8370549 (diff) | |
download | gnuradio-31661e655660a77c28cf14fcb5f648ea05505450.tar.gz gnuradio-31661e655660a77c28cf14fcb5f648ea05505450.tar.bz2 gnuradio-31661e655660a77c28cf14fcb5f648ea05505450.zip |
Change const vector to const vector ref to ease swigging.
Diffstat (limited to 'gnuradio-core/src/lib')
6 files changed, 22 insertions, 22 deletions
diff --git a/gnuradio-core/src/lib/gengen/gr_add_const_vXX.cc.t b/gnuradio-core/src/lib/gengen/gr_add_const_vXX.cc.t index 2a0a3ba3f..f49be062e 100755 --- a/gnuradio-core/src/lib/gengen/gr_add_const_vXX.cc.t +++ b/gnuradio-core/src/lib/gengen/gr_add_const_vXX.cc.t @@ -30,12 +30,12 @@ #include <gr_io_signature.h> @SPTR_NAME@ -gr_make_@BASE_NAME@ (const std::vector<@I_TYPE@> k) +gr_make_@BASE_NAME@ (const std::vector<@I_TYPE@> &k) { return gnuradio::get_initial_sptr (new @NAME@ (k)); } -@NAME@::@NAME@ (const std::vector<@I_TYPE@> k) +@NAME@::@NAME@ (const std::vector<@I_TYPE@> &k) : gr_sync_block ("@BASE_NAME@", gr_make_io_signature (1, 1, sizeof(@I_TYPE@)*k.size()), gr_make_io_signature (1, 1, sizeof(@O_TYPE@)*k.size())) diff --git a/gnuradio-core/src/lib/gengen/gr_add_const_vXX.h.t b/gnuradio-core/src/lib/gengen/gr_add_const_vXX.h.t index 33b6fc396..574fc686c 100755 --- a/gnuradio-core/src/lib/gengen/gr_add_const_vXX.h.t +++ b/gnuradio-core/src/lib/gengen/gr_add_const_vXX.h.t @@ -1,6 +1,6 @@ /* -*- c++ -*- */ /* - * Copyright 2004,2006 Free Software Foundation, Inc. + * Copyright 2004,2006,2010 Free Software Foundation, Inc. * * This file is part of GNU Radio * @@ -30,7 +30,7 @@ class @NAME@; typedef boost::shared_ptr<@NAME@> @SPTR_NAME@; -@SPTR_NAME@ gr_make_@BASE_NAME@ (const std::vector<@I_TYPE@> k); +@SPTR_NAME@ gr_make_@BASE_NAME@ (const std::vector<@I_TYPE@> &k); /*! * \brief output vector = input vector + constant vector @@ -38,14 +38,14 @@ typedef boost::shared_ptr<@NAME@> @SPTR_NAME@; */ class @NAME@ : public gr_sync_block { - friend @SPTR_NAME@ gr_make_@BASE_NAME@ (const std::vector<@I_TYPE@> k); + friend @SPTR_NAME@ gr_make_@BASE_NAME@ (const std::vector<@I_TYPE@> &k); std::vector<@I_TYPE@> d_k; // the constant - @NAME@ (const std::vector<@I_TYPE@> k); + @NAME@ (const std::vector<@I_TYPE@> &k); public: const std::vector<@I_TYPE@> k () const { return d_k; } - void set_k (const std::vector<@I_TYPE@> k) { d_k = k; } + void set_k (const std::vector<@I_TYPE@> &k) { d_k = k; } int work (int noutput_items, gr_vector_const_void_star &input_items, diff --git a/gnuradio-core/src/lib/gengen/gr_add_const_vXX.i.t b/gnuradio-core/src/lib/gengen/gr_add_const_vXX.i.t index a2e7dd70b..ad1643a7e 100755 --- a/gnuradio-core/src/lib/gengen/gr_add_const_vXX.i.t +++ b/gnuradio-core/src/lib/gengen/gr_add_const_vXX.i.t @@ -1,6 +1,6 @@ /* -*- c++ -*- */ /* - * Copyright 2004,2006 Free Software Foundation, Inc. + * Copyright 2004,2006,2010 Free Software Foundation, Inc. * * This file is part of GNU Radio * @@ -24,14 +24,14 @@ GR_SWIG_BLOCK_MAGIC(gr,@BASE_NAME@) -@SPTR_NAME@ gr_make_@BASE_NAME@ (const std::vector<@I_TYPE@> k); +@SPTR_NAME@ gr_make_@BASE_NAME@ (const std::vector<@I_TYPE@> &k); class @NAME@ : public gr_sync_block { private: - @NAME@ (const std::vector<@I_TYPE@> k); + @NAME@ (const std::vector<@I_TYPE@> &k); public: std::vector<@I_TYPE@> k () const { return d_k; } - void set_k (const std::vector<@I_TYPE@> k) { d_k = k; } + void set_k (const std::vector<@I_TYPE@> &k) { d_k = k; } }; diff --git a/gnuradio-core/src/lib/gengen/gr_multiply_const_vXX.cc.t b/gnuradio-core/src/lib/gengen/gr_multiply_const_vXX.cc.t index 8286453f1..5725c1c46 100755 --- a/gnuradio-core/src/lib/gengen/gr_multiply_const_vXX.cc.t +++ b/gnuradio-core/src/lib/gengen/gr_multiply_const_vXX.cc.t @@ -30,12 +30,12 @@ #include <gr_io_signature.h> @SPTR_NAME@ -gr_make_@BASE_NAME@ (const std::vector<@I_TYPE@> k) +gr_make_@BASE_NAME@ (const std::vector<@I_TYPE@> &k) { return gnuradio::get_initial_sptr (new @NAME@ (k)); } -@NAME@::@NAME@ (const std::vector<@I_TYPE@> k) +@NAME@::@NAME@ (const std::vector<@I_TYPE@> &k) : gr_sync_block ("@BASE_NAME@", gr_make_io_signature (1, 1, sizeof(@I_TYPE@)*k.size()), gr_make_io_signature (1, 1, sizeof(@O_TYPE@)*k.size())) diff --git a/gnuradio-core/src/lib/gengen/gr_multiply_const_vXX.h.t b/gnuradio-core/src/lib/gengen/gr_multiply_const_vXX.h.t index 22334505a..81e781895 100755 --- a/gnuradio-core/src/lib/gengen/gr_multiply_const_vXX.h.t +++ b/gnuradio-core/src/lib/gengen/gr_multiply_const_vXX.h.t @@ -1,6 +1,6 @@ /* -*- c++ -*- */ /* - * Copyright 2004,2006 Free Software Foundation, Inc. + * Copyright 2004,2006,2010 Free Software Foundation, Inc. * * This file is part of GNU Radio * @@ -30,7 +30,7 @@ class @NAME@; typedef boost::shared_ptr<@NAME@> @SPTR_NAME@; -@SPTR_NAME@ gr_make_@BASE_NAME@ (const std::vector<@I_TYPE@> k); +@SPTR_NAME@ gr_make_@BASE_NAME@ (const std::vector<@I_TYPE@> &k); /*! * \brief output vector = input vector * constant vector (element-wise) @@ -38,14 +38,14 @@ typedef boost::shared_ptr<@NAME@> @SPTR_NAME@; */ class @NAME@ : public gr_sync_block { - friend @SPTR_NAME@ gr_make_@BASE_NAME@ (const std::vector<@I_TYPE@> k); + friend @SPTR_NAME@ gr_make_@BASE_NAME@ (const std::vector<@I_TYPE@> &k); std::vector<@I_TYPE@> d_k; // the constant - @NAME@ (const std::vector<@I_TYPE@> k); + @NAME@ (const std::vector<@I_TYPE@> &k); public: const std::vector<@I_TYPE@> k () const { return d_k; } - void set_k (const std::vector<@I_TYPE@> k) { d_k = k; } + void set_k (const std::vector<@I_TYPE@> &k) { d_k = k; } int work (int noutput_items, gr_vector_const_void_star &input_items, diff --git a/gnuradio-core/src/lib/gengen/gr_multiply_const_vXX.i.t b/gnuradio-core/src/lib/gengen/gr_multiply_const_vXX.i.t index a2e7dd70b..ad1643a7e 100755 --- a/gnuradio-core/src/lib/gengen/gr_multiply_const_vXX.i.t +++ b/gnuradio-core/src/lib/gengen/gr_multiply_const_vXX.i.t @@ -1,6 +1,6 @@ /* -*- c++ -*- */ /* - * Copyright 2004,2006 Free Software Foundation, Inc. + * Copyright 2004,2006,2010 Free Software Foundation, Inc. * * This file is part of GNU Radio * @@ -24,14 +24,14 @@ GR_SWIG_BLOCK_MAGIC(gr,@BASE_NAME@) -@SPTR_NAME@ gr_make_@BASE_NAME@ (const std::vector<@I_TYPE@> k); +@SPTR_NAME@ gr_make_@BASE_NAME@ (const std::vector<@I_TYPE@> &k); class @NAME@ : public gr_sync_block { private: - @NAME@ (const std::vector<@I_TYPE@> k); + @NAME@ (const std::vector<@I_TYPE@> &k); public: std::vector<@I_TYPE@> k () const { return d_k; } - void set_k (const std::vector<@I_TYPE@> k) { d_k = k; } + void set_k (const std::vector<@I_TYPE@> &k) { d_k = k; } }; |