public bool CheckIsInHitArea(Vertex hitPoint)
        {
            double         resolution         = MapArguments.CurrentResolution;
            double         searchingTolerance = resolution * 14 * searchingToleranceRatio;
            RectangleShape searchingArea      = new RectangleShape(hitPoint.X - searchingTolerance, hitPoint.Y + searchingTolerance, hitPoint.X + searchingTolerance, hitPoint.Y - searchingTolerance);

            if (!EditShapesLayer.IsOpen)
            {
                EditShapesLayer.Open();
            }
            var features = EditShapesLayer.QueryTools.GetFeaturesIntersecting(searchingArea, EditShapesLayer.GetDistinctColumnNames());

            return(features.Count != 0);
        }
        public Collection <Feature> GetEditingFeaturesInterseting(BaseShape baseShape)
        {
            BaseShape searchArea = baseShape;

            if (baseShape.GetWellKnownType() == WellKnownType.Point)
            {
                PointShape worldCoordinate  = (PointShape)baseShape;
                double     searchTorlerence = 15 * MapArguments.CurrentResolution;
                searchArea = new RectangleShape(worldCoordinate.X - searchTorlerence,
                                                worldCoordinate.Y + searchTorlerence, worldCoordinate.X + searchTorlerence,
                                                worldCoordinate.Y - searchTorlerence);
            }

            Collection <Feature> features = new Collection <Feature>();

            lock (EditShapesLayer)
            {
                if (!EditShapesLayer.IsOpen)
                {
                    EditShapesLayer.Open();
                }
                var intersectingFeatures = EditShapesLayer.QueryTools.GetFeaturesIntersecting(searchArea, EditShapesLayer.GetDistinctColumnNames());
                foreach (var feature in intersectingFeatures)
                {
                    features.Add(feature);
                }
            }

            return(features);
        }