Exemplo n.º 1
0
        public MotionWindow AccumulateVector(MotionPoint mp, Func <MotionPoint, MotionPoint, bool> isProperVectorCheck)
        {
            if (isProperVectorCheck(Start, mp))
            {
                var vector = new MotionVector(Start, mp);
                if (!_vectorsHistory.Contains(vector))
                {
                    _vectorsHistory.Add(vector);
                    _vectors.Add(vector);
                }
            }

            return(this);
        }
Exemplo n.º 2
0
        public MotionWindow AccumulateVector(MotionPoint mp)
        {
            if (_roomService.IsProperVector(Start, mp))
            {
                var vector = new MotionVector(Start, mp);
                if (!_vectorsHistory.Contains(vector))
                {
                    _vectorsHistory.Add(vector);
                    _vectors.Add(vector);
                }
            }

            return(this);
        }
Exemplo n.º 3
0
 public bool Contains(MotionPoint p) => _start.Equals(p) || _end.Equals(p);
Exemplo n.º 4
0
 public MotionVector(MotionPoint startPoint, MotionPoint endPoint)
 {
     _start = startPoint;
     _end   = endPoint;
 }
Exemplo n.º 5
0
 public MotionWindow(string place, DateTimeOffset time)
 {
     Start = new MotionPoint(place, time);
 }
Exemplo n.º 6
0
 public MotionWindow(MotionPoint start)
 {
     Start = start;
 }
Exemplo n.º 7
0
 public MotionWindow(string place, DateTimeOffset time, RoomService roomService)
 {
     Start        = new MotionPoint(place, time);
     _roomService = roomService;
 }
Exemplo n.º 8
0
 public bool Contains(MotionPoint p) => Start.Equals(p) || End.Equals(p);