File indexing completed on 2024-04-28 04:39:08

0001 /*
0002     SPDX-FileCopyrightText: 2013 Milian Wolff <mail@milianw.de>
0003 
0004     SPDX-License-Identifier: LGPL-2.0-or-later
0005 */
0006 
0007 #ifndef PROJECTFILTER_H
0008 #define PROJECTFILTER_H
0009 
0010 #include <project/interfaces/iprojectfilter.h>
0011 #include <util/path.h>
0012 
0013 #include "filter.h"
0014 
0015 namespace KDevelop {
0016 
0017 class IProject;
0018 
0019 class ProjectFilter : public IProjectFilter
0020 {
0021 public:
0022     ProjectFilter(const IProject* const project, const Filters& filters);
0023     ~ProjectFilter() override;
0024 
0025     bool isValid(const Path& path, bool isFolder) const override;
0026 
0027 private:
0028     QString makeRelative(const Path& path) const;
0029 
0030     Filters m_filters;
0031     Path m_projectFile;
0032     Path m_project;
0033 };
0034 
0035 }
0036 
0037 #endif // PROJECTFILTER_H