summaryrefslogtreecommitdiff
path: root/src/desktop/rule/matchEngine/MatchEngine.hpp
blob: 9588ac059180f1a86c53b40253d757211be383f3 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
#pragma once

#include "../../DesktopTypes.hpp"

class CTagKeeper;

namespace Desktop::Rule {
    enum eRuleMatchEngine : uint8_t {
        RULE_MATCH_ENGINE_REGEX = 0,
        RULE_MATCH_ENGINE_BOOL,
        RULE_MATCH_ENGINE_INT,
        RULE_MATCH_ENGINE_WORKSPACE,
        RULE_MATCH_ENGINE_TAG,
    };

    class IMatchEngine {
      public:
        virtual ~IMatchEngine() = default;
        virtual bool match(const std::string&);
        virtual bool match(bool);
        virtual bool match(int);
        virtual bool match(PHLWORKSPACE);
        virtual bool match(const CTagKeeper& keeper);

      protected:
        IMatchEngine() = default;
    };
};