2023-01-22 17:17:28 +00:00
|
|
|
#include "app.h"
|
2023-04-04 09:22:41 +00:00
|
|
|
|
2023-12-10 09:13:11 +00:00
|
|
|
bool App::isFlagsEqual(const App &o) const
|
2023-12-04 16:52:11 +00:00
|
|
|
{
|
2023-12-10 09:13:11 +00:00
|
|
|
return isBaseFlagsEqual(o) && isExtraFlagsEqual(o);
|
2023-12-04 16:52:11 +00:00
|
|
|
}
|
|
|
|
|
2023-12-10 09:13:11 +00:00
|
|
|
bool App::isBaseFlagsEqual(const App &o) const
|
2023-04-04 09:22:41 +00:00
|
|
|
{
|
2023-12-03 09:06:43 +00:00
|
|
|
return isWildcard == o.isWildcard && useGroupPerm == o.useGroupPerm
|
2023-12-10 09:13:11 +00:00
|
|
|
&& applyChild == o.applyChild && killChild == o.killChild && lanOnly == o.lanOnly;
|
|
|
|
}
|
|
|
|
|
|
|
|
bool App::isExtraFlagsEqual(const App &o) const
|
|
|
|
{
|
|
|
|
return logBlocked == o.logBlocked && logConn == o.logConn && blocked == o.blocked
|
2023-12-09 16:54:43 +00:00
|
|
|
&& killProcess == o.killProcess;
|
2023-04-04 09:22:41 +00:00
|
|
|
}
|
2023-12-10 09:13:11 +00:00
|
|
|
|
|
|
|
bool App::isOptionsEqual(const App &o) const
|
|
|
|
{
|
|
|
|
return isFlagsEqual(o) && groupIndex == o.groupIndex && appOriginPath == o.appOriginPath
|
|
|
|
&& appPath == o.appPath && endTime == o.endTime;
|
|
|
|
}
|
|
|
|
|
|
|
|
bool App::isNameEqual(const App &o) const
|
|
|
|
{
|
|
|
|
return appName == o.appName;
|
|
|
|
}
|
2023-12-10 10:08:11 +00:00
|
|
|
|
|
|
|
bool App::isProcWild() const
|
|
|
|
{
|
|
|
|
return applyChild || killChild || killProcess;
|
|
|
|
}
|