Пример #1
0
        public void CanGetMonotonicityTypeEmpty()
        {
            ISegment segmentNaNFirst = new LineClass
            {
                FromPoint = CreatePoint(0, 0, double.NaN),
                ToPoint   = CreatePoint(0, 1, 0)
            };

            ISegment segmentNaNSecond = new LineClass
            {
                FromPoint = CreatePoint(0, 0, 99999.88),
                ToPoint   = CreatePoint(0, 1, double.NaN)
            };

            ISegment segmentNaNBoth = new LineClass
            {
                FromPoint = CreatePoint(0, 0, double.NaN),
                ToPoint   = CreatePoint(0, 1, double.NaN)
            };

            Assert.IsTrue(MeasureUtils.GetMonotonicityType(segmentNaNFirst) ==
                          esriMonotinicityEnum.esriValuesEmpty);

            Assert.IsTrue(MeasureUtils.GetMonotonicityType(segmentNaNSecond) ==
                          esriMonotinicityEnum.esriValuesEmpty);

            Assert.IsTrue(MeasureUtils.GetMonotonicityType(segmentNaNBoth) ==
                          esriMonotinicityEnum.esriValuesEmpty);
        }
Пример #2
0
        public void CanGetMonotonicityTypeLevel()
        {
            ISegment segment = new LineClass
            {
                FromPoint = CreatePoint(0, 0, 0),
                ToPoint   = CreatePoint(0, 1, 0)
            };

            Assert.IsTrue(MeasureUtils.GetMonotonicityType(segment) ==
                          esriMonotinicityEnum.esriValueLevel);
        }