예제 #1
0
        static double GetConstant(string constantName)
        {
            var handle = Dlfcn.dlopen(Constants.CoreLocationLibrary, 0);

            try {
                return(Dlfcn.GetDouble(handle, constantName));
            } finally {
                Dlfcn.dlclose(handle);
            }
        }
예제 #2
0
        static CLLocation()
        {
            var handle = Libraries.CoreLocation.Handle;

            if (handle == IntPtr.Zero)
            {
                return;
            }

            AccurracyBestForNavigation = Dlfcn.GetDouble(handle, "kCLLocationAccuracyBestForNavigation");
            AccuracyBest             = Dlfcn.GetDouble(handle, "kCLLocationAccuracyBest");
            AccuracyNearestTenMeters = Dlfcn.GetDouble(handle, "kCLLocationAccuracyNearestTenMeters");
            AccuracyHundredMeters    = Dlfcn.GetDouble(handle, "kCLLocationAccuracyHundredMeters");
            AccuracyKilometer        = Dlfcn.GetDouble(handle, "kCLLocationAccuracyKilometer");
            AccuracyThreeKilometers  = Dlfcn.GetDouble(handle, "kCLLocationAccuracyThreeKilometers");
        }
예제 #3
0
        static CLLocation()
        {
            var handle = Dlfcn.dlopen(Constants.CoreLocationLibrary, 0);

            if (handle == IntPtr.Zero)
            {
                return;
            }

            try {
                AccurracyBestForNavigation = Dlfcn.GetDouble(handle, "kCLLocationAccuracyBestForNavigation");
                AccuracyBest             = Dlfcn.GetDouble(handle, "kCLLocationAccuracyBest");
                AccuracyNearestTenMeters = Dlfcn.GetDouble(handle, "kCLLocationAccuracyNearestTenMeters");
                AccuracyHundredMeters    = Dlfcn.GetDouble(handle, "kCLLocationAccuracyHundredMeters");
                AccuracyKilometer        = Dlfcn.GetDouble(handle, "kCLLocationAccuracyKilometer");
                AccuracyThreeKilometers  = Dlfcn.GetDouble(handle, "kCLLocationAccuracyThreeKilometers");
            } finally {
                Dlfcn.dlclose(handle);
            }
        }