MonitoringStrategy
Diff: inc/circleMonitoringStrategy.h
- Revision:
- 0:7b63a9dd265c
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/inc/circleMonitoringStrategy.h Fri May 07 13:49:51 2021 +0000 @@ -0,0 +1,21 @@ +#ifndef CIRCLEMONITORINGSTRATEGY_H +#define CIRCLEMONITORINGSTRATEGY_H + +#include "monitoringStrategyIf.h" + +/* +* This class is implemntation of monitoringStrategIf for Circle monitoring. Class is used to find nearest object in monitoring area +*/ +class CircleMonitoringStrategy : public MonitoringStrategyIf +{ +public: + CircleMonitoringStrategy(Configuration* config); + ~CircleMonitoringStrategy(); + + /**Checking objects pressence in monitoring area by comparing objects distance from senzor and minimum allowed distrance. + * If any object within the restricted area returns true. If more objects within the restricted area, postion of nearest + * is stored in objectPosition. + */ + bool presenceCheck(const std::map<float, float>& distancesMap, ObjectPosition* objectPosition); +}; +#endif \ No newline at end of file