12 #ifndef INTERFACE_SORT_FILTER_MODEL_H
13 #define INTERFACE_SORT_FILTER_MODEL_H
21 #include <QSortFilterProxyModel>
29 void setStoreOnChange(
bool storeOnChange);
30 void resetAllFilter();
32 void setFilterHidden(
bool filter);
33 bool filterHidden()
const;
34 int interfacesHidden();
35 void toggleFilterHidden();
37 void setSortByActivity(
bool sort);
38 bool sortByActivity()
const;
40 #ifdef HAVE_PCAP_REMOTE
41 void setRemoteDisplay(
bool remoteDisplay);
43 void toggleRemoteDisplay();
44 bool remoteInterfacesExist();
47 void setInterfaceTypeVisible(
int ifType,
bool visible);
48 bool isInterfaceTypeShown(
int ifType)
const;
49 void setFilterByType(
bool filter,
bool invert =
false);
50 bool filterByType()
const;
51 void toggleTypeVisibility(
int ifType);
53 QList<int> typesDisplayed();
55 void setColumns(QList<InterfaceTreeColumns> columns);
56 int mapSourceToColumn(InterfaceTreeColumns mdlIndex);
58 QModelIndex mapToSource(
const QModelIndex &proxyIndex)
const;
59 QModelIndex mapFromSource(
const QModelIndex &sourceIndex)
const;
61 QString interfaceError();
64 bool filterAcceptsRow(
int source_row,
const QModelIndex & source_parent)
const;
65 bool filterAcceptsColumn(
int source_column,
const QModelIndex & source_parent)
const;
66 bool lessThan(
const QModelIndex &source_left,
const QModelIndex &source_right)
const;
71 bool _invertTypeFilter;
75 #ifdef HAVE_PCAP_REMOTE
79 QList<int> displayHiddenTypes;
81 QList<InterfaceTreeColumns> _columns;
84 void resetPreferenceData();
Definition: interface_sort_filter_model.h:24