示例#1
0
            public override double Distance(Geography operand1, Geography operand2)
            {
                UnitTestGeographyDistanceCalculator calc = new UnitTestGeographyDistanceCalculator();

                operand1.SendTo(calc);
                operand2.SendTo(calc);
                return(calc.sum);
            }
示例#2
0
            /// <summary>Indicates a Geography LineString's length.</summary>
            /// <returns>The operation result.</returns>
            /// <param name="operand">The Operand.</param>
            public override double Length(Geography operand)
            {
                UnitTestGeographyDistanceCalculator calc = new UnitTestGeographyDistanceCalculator();
                var tmp = ((GeographyLineString)operand).Points;

                tmp[0].SendTo(calc);
                tmp[1].SendTo(calc);
                return(calc.sum);
            }
示例#3
0
 /// <summary>Indicates a Geography LineString's length.</summary>
 /// <returns>The operation result.</returns>
 /// <param name="operand">The Operand.</param>
 public override double Length(Geography operand)
 {
     UnitTestGeographyDistanceCalculator calc = new UnitTestGeographyDistanceCalculator();
     var tmp = ((GeographyLineString)operand).Points;
     tmp[0].SendTo(calc);
     tmp[1].SendTo(calc);
     return calc.sum;
 }
示例#4
0
 public override double Distance(Geography operand1, Geography operand2)
 {
     UnitTestGeographyDistanceCalculator calc = new UnitTestGeographyDistanceCalculator();
     operand1.SendTo(calc);
     operand2.SendTo(calc);
     return calc.sum;
 }