00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022 #ifndef PCAP_FIND_HH_
00023 # define PCAP_FIND_HH_
00024
00025 extern "C"
00026 {
00027 # include <inttypes.h>
00028 }
00029
00030 # include <vector>
00031 # include <cstddef>
00032
00033 # include <wipal/pcap/frame_descriptor.hh>
00034
00035 namespace pcapxx
00036 {
00037
00038 struct match
00039 {
00040 typedef std::vector<uint8_t> vector_of_bytes;
00041
00042 match(const vector_of_bytes& bytes, size_t first, size_t last);
00043
00044 template <class D>
00045 bool
00046 operator == (const frame_descriptor<D>& rhs) const;
00047
00048 private:
00049 vector_of_bytes bytes_;
00050 size_t first_;
00051 size_t last_;
00052 };
00053
00054 template <class D>
00055 bool
00056 operator == (const frame_descriptor<D>& rhs, const match& lhs);
00057
00058 }
00059
00060 # include "find.hxx"
00061
00062 #endif // ! PCAP_FIND_HH_