Files
haiku-beta6/headers/private/storage/sniffer/PatternList.h
T

43 lines
998 B
C++
Raw Normal View History

2002-08-06 08:25:41 +00:00
//----------------------------------------------------------------------
// This software is part of the OpenBeOS distribution and is covered
// by the OpenBeOS license.
//---------------------------------------------------------------------
/*!
\file sniffer/PatternList.h
MIME sniffer pattern list declarations
*/
#ifndef _sk_sniffer_pattern_list_h_
#define _sk_sniffer_pattern_list_h_
#include <sniffer/DisjList.h>
2002-08-06 08:25:41 +00:00
#include <sniffer/Range.h>
#include <vector>
class BPositionIO;
namespace Sniffer {
class Err;
class Pattern;
/*! \brief A list of patterns, one of which must match for the list to match, all
of which are to be searched over the same range.
*/
class PatternList : public DisjList {
2002-08-06 08:25:41 +00:00
public:
PatternList(Range range);
virtual ~PatternList();
status_t InitCheck() const;
Err* GetErr() const;
virtual bool Sniff(BPositionIO *data) const;
void Add(Pattern *pattern);
private:
std::vector<Pattern*> fList;
Range fRange;
};
}
#endif // _sk_sniffer_pattern_list_h_