1 /* funnel_statistics.cpp 2 * 3 * Wireshark - Network traffic analyzer 4 * By Gerald Combs <gerald@wireshark.org> 5 * Copyright 1998 Gerald Combs 6 * 7 * SPDX-License-Identifier: GPL-2.0-or-later 8 */ 9 10 #ifndef FUNNELSTATISTICS_H 11 #define FUNNELSTATISTICS_H 12 13 #include <QObject> 14 15 #include "capture_file.h" 16 #include "funnel_text_dialog.h" 17 #include <ui/qt/filter_action.h> 18 19 struct _funnel_ops_t; 20 struct progdlg; 21 22 class FunnelStatistics : public QObject 23 { 24 Q_OBJECT 25 public: 26 explicit FunnelStatistics(QObject *parent, CaptureFile &cf); 27 ~FunnelStatistics(); 28 void retapPackets(); 29 struct progdlg *progressDialogNew(const gchar *task_title, const gchar *item_title, gboolean terminate_is_stop, gboolean *stop_flag); 30 const char *displayFilter(); 31 void emitSetDisplayFilter(const QString filter); 32 void reloadPackets(); 33 void redissectPackets(); 34 void reloadLuaPlugins(); 35 void emitApplyDisplayFilter(); 36 void emitOpenCaptureFile(QString cf_path, QString filter); actionName()37 static const QString &actionName() { return action_name_; } 38 39 signals: 40 void openCaptureFile(QString cf_path, QString filter); 41 void setDisplayFilter(QString filter, FilterAction::Action action, FilterAction::ActionType filterType); 42 43 public slots: 44 void funnelActionTriggered(); 45 void displayFilterTextChanged(const QString &filter); 46 47 private: 48 static const QString action_name_; 49 struct _funnel_ops_t *funnel_ops_; 50 struct _funnel_ops_id_t *funnel_ops_id_; 51 52 CaptureFile &capture_file_; 53 QByteArray display_filter_; 54 QString prepared_filter_; 55 }; 56 57 extern "C" { 58 void funnel_statistics_reload_menus(void); 59 } // extern "C" 60 61 #endif // FUNNELSTATISTICS_H 62