private void ReturnMeasurementValues()
 {
     ModifiedPythagorousResultTxtBx.Text = ModifiedPythagoras.Measure(StartLocationInDegrees, EndLocationInDegrees).ToString();
     GreaterCircleResultTxtBx.Text       = GreaterCircle.Measure(StartLocationInRadian, EndLocationInRadian, EarthRadius).ToString();
     HaversineFormulaResultTxtBx.Text    = HaversineFormula.Measure(StartLocationInRadian, EndLocationInRadian, EarthRadius).ToString();
 }
Beispiel #2
0
        public string ShortName => End.ShortName;     // Temp name.

        //public string Message // Just for fun, but real logic and other properties may be handy.
        //{
        //    get // Don't do night flight navigation after these coordinates or tell your English teacher about the sentence structure.
        //    {
        //        var s = Start.Latitude >= 51.229 && Start.Latitude <= 53.635 && Start.Longitude >= -5.807 && Start.Longitude <= -2.649
        //            ? "You are probably in Wales. "
        //            : "Seems that you are not in Wales. ";

        //        s += End.Latitude >= 51.4 && End.Latitude <= 53.4 && End.Longitude >= -5.3 && End.Longitude <= -2.9
        //            ? "Are you going to Wales?"
        //            : "Are you leaving Wales?";

        //        return s;
        //    }
        //}

        // Methods
        public void ChangeUnit(Unit selectedUnit)
        {
            ModifiedPythagorasResult = ModifiedPythagoras.ToUnit(selectedUnit);
            GreaterCircleResult      = GreaterCircle.ToUnit(selectedUnit);
            HaversineFormulaResult   = Haversine.ToUnit(selectedUnit);
        }