18#include <ui/qt/widgets/detachable_tabwidget.h>
25#include <QAbstractItemDelegate>
26#include <QSortFilterProxyModel>
36typedef ATapDataModel * (*ATapModelCallback)(
int protoId, QString filter);
45typedef QAbstractItemDelegate * (*ATapCreateDelegate)(QWidget * parent);
159 void setFilter(QString filter = QString());
166 void setNameResolution(
bool checked);
186 QMenu * createCopyMenu(QWidget * parent =
nullptr);
195 bool hasNameResolution(
int tabIdx = -1);
205 bool hasGeoIPData(
int tabIdx = -1);
214 QUrl createGeoIPMap(
bool onlyJSON,
int tabIdx = -1);
224 QVariant currentItemData(
int role = Qt::DisplayRole);
233 qlonglong countSelectedItems(
int role = Qt::DisplayRole);
241 QList<QList<QVariant> > selectedItemsIOGData();
248 void useNanosecondTimestamps(
bool useNSTime);
264 void useAbsoluteTime(
bool absolute);
270 void limitToDisplayFilter(
bool limit);
276 void setMachineReadable(
bool machine);
282 void setOpenTabs(QList<int> protocols);
329 virtual void detachTab(
int idx, QPoint pos)
override;
336 virtual void attachTab(QWidget * content, QString name)
override;
340 QList<int> _allProtocols;
343 QMap<int, int> _tabs;
352 GList ** _recentList;
355 GList ** _recentColumnList;
361 bool _nameResolution;
367 bool _limitToDisplayFilter;
373 bool _machineReadable;
380 QTreeView * createTree(
int protoId);
408 void insertProtoTab(
int protoId,
bool emitSignals =
true);
415 void removeProtoTab(
int protoId,
bool emitSignals =
true);
439 void doCurrentIndexChange(
const QModelIndex & cur,
const QModelIndex & prev);
446 void doSelectionChange(
const QItemSelection &selected,
const QItemSelection &deselected);
DataModel for tap user data.
Definition atap_data_model.h:33
Action
Defines an action to be taken with a filter.
Definition filter_action.h:30
ActionType
Defines how the new filter should be combined with the existing one.
Definition filter_action.h:43
A simple class to store the data for a tab in the traffic tab widget.
Definition traffic_tab.h:51
TabData & operator=(const TabData &)=default
Copy assignment operator.
TabData()
Constructs a new empty TabData object.
Definition traffic_tab.cpp:48
int protoId() const
Retrieves the protocol ID.
Definition traffic_tab.cpp:63
TabData(const TabData &)=default
Copy constructor.
QString name() const
Retrieves the name of the tab.
Definition traffic_tab.cpp:58
Proxy model handling sorting, filtering, and column visibility for traffic data.
Definition traffic_tree.h:156
A QTabWidget class, providing tap information.
Definition traffic_tab.h:106
void tabDataChanged(int idx, int selcounter)
Signal emitted when the tab data has changed.
void filterAction(QString filter, FilterAction::Action action, FilterAction::ActionType type)
Signal emitted to trigger a filter action.
void columnsHaveChanged(QList< int > columns)
Signal emitted when the column configuration has changed.
void tabsChanged(QList< int > protocols)
Signal emitted when the open tabs have changed.
void disablingTaps()
Signal emitted to notify that taps are being disabled.
void retapRequired()
Signal emitted when a retap operation is required.
Tree view widget that presents a filterable, sortable, checkable list of traffic-tap protocols and fo...
Definition traffic_types_list.h:229
ATapDataModel *(* ATapModelCallback)(int protoId, QString filter)
Callback for creating an ATapDataModel.
Definition traffic_tab.h:36
QAbstractItemDelegate *(* ATapCreateDelegate)(QWidget *parent)
Callback for creating an item delegate.
Definition traffic_tab.h:45