]> sigrok.org Git - pulseview.git/blobdiff - pv/data/decode/decoder.hpp
Use SignalBase instead of LogicSignal for decoders
[pulseview.git] / pv / data / decode / decoder.hpp
index aa79e01c93d4894f312d0b63c9cc3c99bde8b5bc..105c6f744b0cf897df19e64d7237a06ddf50fb67 100644 (file)
@@ -18,8 +18,8 @@
  * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301 USA
  */
 
-#ifndef PULSEVIEW_PV_DATA_DECODE_DECODER_H
-#define PULSEVIEW_PV_DATA_DECODE_DECODER_H
+#ifndef PULSEVIEW_PV_DATA_DECODE_DECODER_HPP
+#define PULSEVIEW_PV_DATA_DECODE_DECODER_HPP
 
 #include <map>
 #include <memory>
@@ -34,20 +34,17 @@ struct srd_session;
 
 namespace pv {
 
-namespace view {
-class LogicSignal;
-}
-
 namespace data {
 
 class Logic;
+class SignalBase;
 
 namespace decode {
 
 class Decoder
 {
 public:
-       Decoder(const srd_decoder *const decoder);
+       Decoder(const srd_decoder *const dec);
 
        virtual ~Decoder();
 
@@ -57,9 +54,9 @@ public:
        void show(bool show = true);
 
        const std::map<const srd_channel*,
-               std::shared_ptr<view::LogicSignal> >& channels() const;
+               std::shared_ptr<data::SignalBase> >& channels() const;
        void set_channels(std::map<const srd_channel*,
-               std::shared_ptr<view::LogicSignal> > channels);
+               std::shared_ptr<data::SignalBase> > channels);
 
        const std::map<std::string, GVariant*>& options() const;
 
@@ -68,7 +65,7 @@ public:
        bool have_required_channels() const;
 
        srd_decoder_inst* create_decoder_inst(
-               srd_session *session, int unit_size) const;
+               srd_session *session) const;
 
        std::set< std::shared_ptr<pv::data::Logic> > get_data();
 
@@ -77,7 +74,7 @@ private:
 
        bool shown_;
 
-       std::map<const srd_channel*, std::shared_ptr<pv::view::LogicSignal> >
+       std::map<const srd_channel*, std::shared_ptr<pv::data::SignalBase> >
                channels_;
        std::map<std::string, GVariant*> options_;
 };
@@ -86,4 +83,4 @@ private:
 } // namespace data
 } // namespace pv
 
-#endif // PULSEVIEW_PV_DATA_DECODE_DECODER_H
+#endif // PULSEVIEW_PV_DATA_DECODE_DECODER_HPP