protected override RectangleShape GetBoundingBoxCore()
        {
            RectangleShape boundingBox;

            if (!LoadingFromShapeFile)
            {
                InputFeatureLayer.Open();
                boundingBox = InputFeatureLayer.GetBoundingBox();
                InputFeatureLayer.Close();
            }
            else
            {
                ShapeFileFeatureLayer shapeFileFeatureLayer = new ShapeFileFeatureLayer(shapePathFileName);
                shapeFileFeatureLayer.Open();
                boundingBox = shapeFileFeatureLayer.GetBoundingBox();
                shapeFileFeatureLayer.Close();
            }

            return(boundingBox);
        }
        protected override TopologyTestCase GenerateTestCaseWithinExtentCore(RectangleShape extent)
        {
            if (!OutputFeatureLayer.IsOpen)
            {
                OutputFeatureLayer.Open();
            }
            Collection <Feature> outputFeatures = OutputFeatureLayer.QueryTools.GetFeaturesInsideBoundingBox(extent, ReturningColumnsType.NoColumns);
            Collection <Feature> inputFeatures  = null;

            if (!LoadingFromShapeFile)
            {
                if (!InputFeatureLayer.IsOpen)
                {
                    InputFeatureLayer.Open();
                }

                inputFeatures = InputFeatureLayer.QueryTools.GetFeaturesInsideBoundingBox(extent, ReturningColumnsType.NoColumns);
            }
            else
            {
                ShapeFileFeatureLayer shapeFileFeatureLayer = new ShapeFileFeatureLayer(ShapePathFileName);
                shapeFileFeatureLayer.Open();
                inputFeatures = shapeFileFeatureLayer.QueryTools.GetFeaturesInsideBoundingBox(extent, ReturningColumnsType.NoColumns);
                shapeFileFeatureLayer.Close();
            }
            OneInputLayerTopologyTestCase topologyTestCase = (OneInputLayerTopologyTestCase)Activator.CreateInstance(GetType());

            foreach (Feature feature in outputFeatures)
            {
                topologyTestCase.OutputFeatureLayer.InternalFeatures.Add(feature);
            }

            foreach (Feature feature in inputFeatures)
            {
                topologyTestCase.InputFeatureLayer.InternalFeatures.Add(feature);
            }

            return(topologyTestCase);
        }