Ejemplo n.º 1
0
        public void TestTwoOpenClose()
        {
            ///Simulates two threads using the same provider at the same time..
            var provider = new ShapeFile(TestDataPath, true, false);

            provider.Open();
            provider.Open();
            provider.GetGeometriesInView(GetRandomEnvelope());
            provider.Close();
            provider.GetGeometriesInView(GetRandomEnvelope());
            provider.Close();
        }
Ejemplo n.º 2
0
        public void TestTwoThreadsUsingDifferentProviders()
        {
            var provider1 = new ShapeFile(TestDataPath, false, true);
            var provider2 = new ShapeFile(TestDataPath, false, true);

            provider1.Open();
            provider2.Open();
            provider1.GetGeometriesInView(GetRandomEnvelope());
            provider1.Close();
            provider2.GetGeometriesInView(GetRandomEnvelope());
            provider2.Close();
        }