Tyler Dauwalder 01293d6ed7 + Added InitCheck()
+ Added Priority()
+ Added Sniff()
+ Replaced ExprList typedef with plain old std::vector<Expr*>
so I wouldn't forget what the hell kind of list I was working with.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@607 a95241bf-73f2-0310-859d-f6bbb57e9c96
2002-08-06 08:32:27 +00:00

42 lines
791 B
C++

//----------------------------------------------------------------------
// This software is part of the OpenBeOS distribution and is covered
// by the OpenBeOS license.
//---------------------------------------------------------------------
/*!
\file sniffer/Rule.h
Mime sniffer rule declarations
*/
#ifndef _sk_sniffer_rule_h_
#define _sk_sniffer_rule_h_
#include <SupportDefs.h>
#include <vector>
class BPositionIO;
namespace Sniffer {
class Expr;
class Rule {
public:
Rule();
~Rule();
status_t InitCheck() const;
double Priority() const;
bool Sniff(BPositionIO *data) const;
private:
friend class Parser;
void Unset();
void SetTo(double priority, std::vector<Expr*>* list);
double fPriority;
std::vector<Expr*> *fExprList;
};
}
#endif // _sk_sniffer_rule_h_