| Wireshark 4.7.0 The Wireshark network protocol analyzer

Loading...
Searching...
No Matches
conversation_colorize_action.h
Go to the documentation of this file.
1
10#ifndef CONVERSATIONCOLORIZEACTION_H
11#define CONVERSATIONCOLORIZEACTION_H
12
13#include <QAction>
14
15 struct conversation_filter_s;
16 struct _packet_info;
17
18// Actions for "Conversation Filter" and "Colorize with Filter" menu items.
19
20 class ConversationAction : public QAction
21{
22 Q_OBJECT
23 public:
24 ConversationAction(QObject *parent, struct conversation_filter_s *conv_filter = NULL);
25
26 bool isFilterValid(struct _packet_info *pinfo);
27
28 const QByteArray filter() { return filter_ba_; }
29
30 void setColorNumber(int color_number) { color_number_ = color_number; }
31 int colorNumber() { return color_number_; }
32
33 public slots:
34 // Exactly one of these should be connected.
35 void setPacketInfo(struct _packet_info *pinfo);
36 void setFieldFilter(const QByteArray field_filter);
37
38 private:
39 struct conversation_filter_s *conv_filter_;
40 QByteArray filter_ba_;
41 int color_number_;
42};
43
44 class ColorizeAction : public QAction
45{
46 Q_OBJECT
47 public:
48 ColorizeAction(QObject *parent) : QAction(parent),
49 color_number_(-1)
50 {}
51
52 const QByteArray filter() { return filter_ba_; }
53
54 void setColorNumber(int color_number) { color_number_ = color_number; }
55 int colorNumber() { return color_number_; }
56
57 public slots:
58 void setFieldFilter(const QByteArray field_filter) { filter_ba_ = field_filter; }
59
60 private:
61 QByteArray filter_ba_;
62 int color_number_;
63};
64
65#endif // CONVERSATIONCOLORIZEACTION_H
ColorizeAction
Definition conversation_colorize_action.h:45
ConversationAction
Definition conversation_colorize_action.h:21
_packet_info
Definition packet_info.h:43
conversation_filter_s
Definition conversation_filter.h:103