sneedmc/logic/pathmatcher/MultiMatcher.h
Petr Mrázek 96fdaebb5c GH-926 implement log cleaning functionality
Also adds gzip compressed log support
2015-08-18 08:51:12 +02:00

32 lines
467 B
C++

#include "IPathMatcher.h"
#include <SeparatorPrefixTree.h>
#include <QRegularExpression>
class MultiMatcher : public IPathMatcher
{
public:
virtual ~MultiMatcher() {};
MultiMatcher()
{
}
MultiMatcher &add(Ptr add)
{
m_matchers.append(add);
return *this;
}
virtual bool matches(const QString &string) override
{
for(auto iter: m_matchers)
{
if(iter->matches(string))
{
return true;
}
}
return false;
}
QList<Ptr> m_matchers;
};