示例#1
0
 public virtual void testEnvelope2D_corners()
 {
     com.esri.core.geometry.Envelope2D env = new com.esri.core.geometry.Envelope2D(0,
                                                                                   1, 2, 3);
     NUnit.Framework.Assert.IsFalse(env.Equals(null));
     NUnit.Framework.Assert.IsTrue(env.Equals((object)new com.esri.core.geometry.Envelope2D
                                                  (0, 1, 2, 3)));
     com.esri.core.geometry.Point2D pt2D = env.getLowerLeft();
     NUnit.Framework.Assert.IsTrue(pt2D.equals(com.esri.core.geometry.Point2D.construct
                                                   (0, 1)));
     pt2D = env.getUpperLeft();
     NUnit.Framework.Assert.IsTrue(pt2D.equals(com.esri.core.geometry.Point2D.construct
                                                   (0, 3)));
     pt2D = env.getUpperRight();
     NUnit.Framework.Assert.IsTrue(pt2D.equals(com.esri.core.geometry.Point2D.construct
                                                   (2, 3)));
     pt2D = env.getLowerRight();
     NUnit.Framework.Assert.IsTrue(pt2D.equals(com.esri.core.geometry.Point2D.construct
                                                   (2, 1)));
     {
         com.esri.core.geometry.Point2D[] corners = new com.esri.core.geometry.Point2D[4];
         env.queryCorners(corners);
         NUnit.Framework.Assert.IsTrue(corners[0].equals(com.esri.core.geometry.Point2D.construct
                                                             (0, 1)));
         NUnit.Framework.Assert.IsTrue(corners[1].equals(com.esri.core.geometry.Point2D.construct
                                                             (0, 3)));
         NUnit.Framework.Assert.IsTrue(corners[2].equals(com.esri.core.geometry.Point2D.construct
                                                             (2, 3)));
         NUnit.Framework.Assert.IsTrue(corners[3].equals(com.esri.core.geometry.Point2D.construct
                                                             (2, 1)));
         env.queryCorners(corners);
         NUnit.Framework.Assert.IsTrue(corners[0].equals(env.queryCorner(0)));
         NUnit.Framework.Assert.IsTrue(corners[1].equals(env.queryCorner(1)));
         NUnit.Framework.Assert.IsTrue(corners[2].equals(env.queryCorner(2)));
         NUnit.Framework.Assert.IsTrue(corners[3].equals(env.queryCorner(3)));
     }
     {
         com.esri.core.geometry.Point2D[] corners = new com.esri.core.geometry.Point2D[4];
         env.queryCornersReversed(corners);
         NUnit.Framework.Assert.IsTrue(corners[0].equals(com.esri.core.geometry.Point2D.construct
                                                             (0, 1)));
         NUnit.Framework.Assert.IsTrue(corners[1].equals(com.esri.core.geometry.Point2D.construct
                                                             (2, 1)));
         NUnit.Framework.Assert.IsTrue(corners[2].equals(com.esri.core.geometry.Point2D.construct
                                                             (2, 3)));
         NUnit.Framework.Assert.IsTrue(corners[3].equals(com.esri.core.geometry.Point2D.construct
                                                             (0, 3)));
         env.queryCornersReversed(corners);
         NUnit.Framework.Assert.IsTrue(corners[0].equals(env.queryCorner(0)));
         NUnit.Framework.Assert.IsTrue(corners[1].equals(env.queryCorner(3)));
         NUnit.Framework.Assert.IsTrue(corners[2].equals(env.queryCorner(2)));
         NUnit.Framework.Assert.IsTrue(corners[3].equals(env.queryCorner(1)));
     }
     NUnit.Framework.Assert.IsTrue(env.getCenter().equals(com.esri.core.geometry.Point2D
                                                          .construct(1, 2)));
     NUnit.Framework.Assert.IsFalse(env.containsExclusive(env.getUpperLeft()));
     NUnit.Framework.Assert.IsTrue(env.contains(env.getUpperLeft()));
     NUnit.Framework.Assert.IsTrue(env.containsExclusive(env.getCenter()));
 }
 private static com.esri.core.geometry.Point makePoint()
 {
     com.esri.core.geometry.Point   point = new com.esri.core.geometry.Point();
     com.esri.core.geometry.Point2D pt    = new com.esri.core.geometry.Point2D();
     pt.setCoords(0, 15);
     point.setXY(pt);
     return(point);
 }
示例#3
0
 public static com.esri.core.geometry.Point makePoint()
 {
     com.esri.core.geometry.Point   point = new com.esri.core.geometry.Point();
     com.esri.core.geometry.Point2D pt    = new com.esri.core.geometry.Point2D();
     pt.setCoords(10, 20);
     point.setXY(pt);
     return(point);
 }
示例#4
0
        internal override int compare(com.esri.core.geometry.Treap treap, int elm, int node
                                      )
        {
            int elm2 = treap.getElement(node);

            com.esri.core.geometry.Point2D pt1 = m_pts[elm];
            com.esri.core.geometry.Point2D pt2 = m_pts[elm2];
            if (pt1.x < pt2.x)
            {
                return(-1);
            }
            return(1);
        }
 public static com.esri.core.geometry.MultiPoint makeMultiPoint3()
 {
     com.esri.core.geometry.MultiPoint mpoint = new com.esri.core.geometry.MultiPoint(
         );
     com.esri.core.geometry.Point2D pt1 = new com.esri.core.geometry.Point2D();
     pt1.x = 1.0;
     pt1.y = 1.0;
     com.esri.core.geometry.Point2D pt2 = new com.esri.core.geometry.Point2D();
     pt2.x = 5.0;
     pt2.y = 5.0;
     mpoint.add(pt1.x, pt1.y);
     mpoint.add(pt2.x, pt2.y);
     return(mpoint);
 }
 public static com.esri.core.geometry.MultiPoint makeMultiPoint2()
 {
     com.esri.core.geometry.MultiPoint mpoint = new com.esri.core.geometry.MultiPoint(
         );
     com.esri.core.geometry.Point2D pt1 = new com.esri.core.geometry.Point2D();
     pt1.x = 1.0;
     pt1.y = 1.0;
     com.esri.core.geometry.Point2D pt2 = new com.esri.core.geometry.Point2D();
     pt2.x = 1.0;
     pt2.y = 1.0;
     com.esri.core.geometry.Point2D pt3 = new com.esri.core.geometry.Point2D();
     pt3.x = 15.0;
     pt3.y = 15.0;
     com.esri.core.geometry.Point2D pt4 = new com.esri.core.geometry.Point2D();
     pt4.x = 15.0;
     pt4.y = 15.0;
     com.esri.core.geometry.Point2D pt5 = new com.esri.core.geometry.Point2D();
     pt5.x = 1.0;
     pt5.y = 1.0;
     com.esri.core.geometry.Point2D pt6 = new com.esri.core.geometry.Point2D();
     pt6.x = 1.0;
     pt6.y = 1.0;
     com.esri.core.geometry.Point2D pt7 = new com.esri.core.geometry.Point2D();
     pt7.x = 15.0;
     pt7.y = 15.0;
     com.esri.core.geometry.Point2D pt8 = new com.esri.core.geometry.Point2D();
     pt8.x = 15.0;
     pt8.y = 15.0;
     com.esri.core.geometry.Point2D pt9 = new com.esri.core.geometry.Point2D();
     pt9.x = 15.0;
     pt9.y = 15.0;
     com.esri.core.geometry.Point2D pt10 = new com.esri.core.geometry.Point2D();
     pt10.x = 1.0;
     pt10.y = 1.0;
     com.esri.core.geometry.Point2D pt11 = new com.esri.core.geometry.Point2D();
     pt11.x = 15.0;
     pt11.y = 15.0;
     mpoint.add(pt1.x, pt1.y);
     mpoint.add(pt2.x, pt2.y);
     mpoint.add(pt3.x, pt3.y);
     mpoint.add(pt4.x, pt4.y);
     mpoint.add(pt5.x, pt5.y);
     mpoint.add(pt6.x, pt6.y);
     mpoint.add(pt7.x, pt7.y);
     mpoint.add(pt8.x, pt8.y);
     mpoint.add(pt9.x, pt9.y);
     mpoint.add(pt10.x, pt10.y);
     mpoint.add(pt11.x, pt11.y);
     return(mpoint);
 }
示例#7
0
 public static void test1()
 {
     com.esri.core.geometry.Point2D[] pts = new com.esri.core.geometry.Point2D[10];
     for (int i = 0; i < 10; i++)
     {
         com.esri.core.geometry.Point2D pt = new com.esri.core.geometry.Point2D();
         pt.x   = i;
         pt.y   = 0;
         pts[i] = pt;
     }
     com.esri.core.geometry.TreapComparatorForTesting c = new com.esri.core.geometry.TreapComparatorForTesting
                                                              (pts);
     com.esri.core.geometry.Treap treap = new com.esri.core.geometry.Treap();
     treap.setComparator(c);
     int[] nodes = new int[10];
     for (int i_1 = 0; i_1 < 10; i_1++)
     {
         nodes[i_1] = treap.addElement(i_1, -1);
     }
     for (int i_2 = 1; i_2 < 10; i_2++)
     {
         NUnit.Framework.Assert.IsTrue(treap.getPrev(nodes[i_2]) == nodes[i_2 - 1]);
     }
     for (int i_3 = 0; i_3 < 9; i_3++)
     {
         NUnit.Framework.Assert.IsTrue(treap.getNext(nodes[i_3]) == nodes[i_3 + 1]);
     }
     treap.deleteNode(nodes[0], -1);
     treap.deleteNode(nodes[2], -1);
     treap.deleteNode(nodes[4], -1);
     treap.deleteNode(nodes[6], -1);
     treap.deleteNode(nodes[8], -1);
     NUnit.Framework.Assert.IsTrue(treap.getPrev(nodes[3]) == nodes[1]);
     NUnit.Framework.Assert.IsTrue(treap.getPrev(nodes[5]) == nodes[3]);
     NUnit.Framework.Assert.IsTrue(treap.getPrev(nodes[7]) == nodes[5]);
     NUnit.Framework.Assert.IsTrue(treap.getPrev(nodes[9]) == nodes[7]);
     NUnit.Framework.Assert.IsTrue(treap.getNext(nodes[1]) == nodes[3]);
     NUnit.Framework.Assert.IsTrue(treap.getNext(nodes[3]) == nodes[5]);
     NUnit.Framework.Assert.IsTrue(treap.getNext(nodes[5]) == nodes[7]);
     NUnit.Framework.Assert.IsTrue(treap.getNext(nodes[7]) == nodes[9]);
 }
		public static void Test1()
		{
			com.esri.core.geometry.Point2D[] pts = new com.esri.core.geometry.Point2D[10];
			for (int i = 0; i < 10; i++)
			{
				com.esri.core.geometry.Point2D pt = new com.esri.core.geometry.Point2D();
				pt.x = i;
				pt.y = 0;
				pts[i] = pt;
			}
			com.esri.core.geometry.TreapComparatorForTesting c = new com.esri.core.geometry.TreapComparatorForTesting(pts);
			com.esri.core.geometry.Treap treap = new com.esri.core.geometry.Treap();
			treap.SetComparator(c);
			int[] nodes = new int[10];
			for (int i_1 = 0; i_1 < 10; i_1++)
			{
				nodes[i_1] = treap.AddElement(i_1, -1);
			}
			for (int i_2 = 1; i_2 < 10; i_2++)
			{
				NUnit.Framework.Assert.IsTrue(treap.GetPrev(nodes[i_2]) == nodes[i_2 - 1]);
			}
			for (int i_3 = 0; i_3 < 9; i_3++)
			{
				NUnit.Framework.Assert.IsTrue(treap.GetNext(nodes[i_3]) == nodes[i_3 + 1]);
			}
			treap.DeleteNode(nodes[0], -1);
			treap.DeleteNode(nodes[2], -1);
			treap.DeleteNode(nodes[4], -1);
			treap.DeleteNode(nodes[6], -1);
			treap.DeleteNode(nodes[8], -1);
			NUnit.Framework.Assert.IsTrue(treap.GetPrev(nodes[3]) == nodes[1]);
			NUnit.Framework.Assert.IsTrue(treap.GetPrev(nodes[5]) == nodes[3]);
			NUnit.Framework.Assert.IsTrue(treap.GetPrev(nodes[7]) == nodes[5]);
			NUnit.Framework.Assert.IsTrue(treap.GetPrev(nodes[9]) == nodes[7]);
			NUnit.Framework.Assert.IsTrue(treap.GetNext(nodes[1]) == nodes[3]);
			NUnit.Framework.Assert.IsTrue(treap.GetNext(nodes[3]) == nodes[5]);
			NUnit.Framework.Assert.IsTrue(treap.GetNext(nodes[5]) == nodes[7]);
			NUnit.Framework.Assert.IsTrue(treap.GetNext(nodes[7]) == nodes[9]);
		}
 public static void testEditShape()
 {
     {
         // std::shared_ptr<Esri_runtimecore::Geometry::Polygon> poly_base_6
         // = std::make_shared<Esri_runtimecore::Geometry::Polygon>();
         // Single part polygon
         com.esri.core.geometry.Polygon poly = new com.esri.core.geometry.Polygon();
         poly.startPath(10, 10);
         poly.lineTo(10, 12);
         poly.lineTo(14, 15);
         poly.lineTo(10, 11);
         com.esri.core.geometry.EditShape editShape = new com.esri.core.geometry.EditShape
                                                          ();
         int geom = editShape.addGeometry(poly);
         com.esri.core.geometry.Polygon poly2 = (com.esri.core.geometry.Polygon)editShape.
                                                getGeometry(geom);
         NUnit.Framework.Assert.IsTrue(poly.Equals(poly2));
     }
     {
         // Two part poly
         com.esri.core.geometry.Polygon poly = new com.esri.core.geometry.Polygon();
         poly.startPath(10, 10);
         poly.lineTo(10, 12);
         poly.lineTo(14, 15);
         poly.lineTo(10, 11);
         poly.startPath(100, 10);
         poly.lineTo(100, 12);
         poly.lineTo(14, 150);
         poly.lineTo(10, 101);
         poly.lineTo(100, 11);
         com.esri.core.geometry.EditShape editShape = new com.esri.core.geometry.EditShape
                                                          ();
         int geom = editShape.addGeometry(poly);
         com.esri.core.geometry.Polygon poly2 = (com.esri.core.geometry.Polygon)editShape.
                                                getGeometry(geom);
         NUnit.Framework.Assert.IsTrue(poly.Equals(poly2));
     }
     {
         // Single part polyline
         com.esri.core.geometry.Polyline poly = new com.esri.core.geometry.Polyline();
         poly.startPath(10, 10);
         poly.lineTo(10, 12);
         poly.lineTo(14, 15);
         poly.lineTo(10, 11);
         com.esri.core.geometry.EditShape editShape = new com.esri.core.geometry.EditShape
                                                          ();
         int geom = editShape.addGeometry(poly);
         com.esri.core.geometry.Polyline poly2 = (com.esri.core.geometry.Polyline)editShape
                                                 .getGeometry(geom);
         NUnit.Framework.Assert.IsTrue(poly.Equals(poly2));
     }
     {
         // Two part poly
         com.esri.core.geometry.Polyline poly = new com.esri.core.geometry.Polyline();
         poly.startPath(10, 10);
         poly.lineTo(10, 12);
         poly.lineTo(14, 15);
         poly.lineTo(10, 11);
         poly.startPath(100, 10);
         poly.lineTo(100, 12);
         poly.lineTo(14, 150);
         poly.lineTo(10, 101);
         poly.lineTo(100, 11);
         com.esri.core.geometry.EditShape editShape = new com.esri.core.geometry.EditShape
                                                          ();
         int geom = editShape.addGeometry(poly);
         com.esri.core.geometry.Polyline poly2 = (com.esri.core.geometry.Polyline)editShape
                                                 .getGeometry(geom);
         NUnit.Framework.Assert.IsTrue(poly.Equals(poly2));
     }
     {
         // Five part poly. Close one of parts to test if it works.
         com.esri.core.geometry.Polyline poly = new com.esri.core.geometry.Polyline();
         poly.startPath(10, 10);
         poly.lineTo(10, 12);
         poly.lineTo(14, 15);
         poly.lineTo(10, 11);
         poly.startPath(100, 10);
         poly.lineTo(100, 12);
         poly.lineTo(14, 150);
         poly.lineTo(10, 101);
         poly.lineTo(100, 11);
         poly.startPath(1100, 101);
         poly.lineTo(1300, 132);
         poly.lineTo(144, 150);
         poly.lineTo(106, 1051);
         poly.lineTo(1600, 161);
         poly.startPath(100, 190);
         poly.lineTo(1800, 192);
         poly.lineTo(184, 8150);
         poly.lineTo(1080, 181);
         poly.startPath(1030, 10);
         poly.lineTo(1300, 132);
         poly.lineTo(314, 3150);
         poly.lineTo(310, 1301);
         poly.lineTo(3100, 311);
         com.esri.core.geometry.EditShape editShape = new com.esri.core.geometry.EditShape
                                                          ();
         int geom = editShape.addGeometry(poly);
         editShape.setClosedPath(editShape.getNextPath(editShape.getFirstPath(geom)), true
                                 );
         ((com.esri.core.geometry.MultiPathImpl)poly._getImpl()).closePathWithLine(1);
         com.esri.core.geometry.Polyline poly2 = (com.esri.core.geometry.Polyline)editShape
                                                 .getGeometry(geom);
         NUnit.Framework.Assert.IsTrue(poly.Equals(poly2));
     }
     {
         // Test erase
         com.esri.core.geometry.Polyline poly = new com.esri.core.geometry.Polyline();
         poly.startPath(10, 10);
         poly.lineTo(10, 12);
         poly.lineTo(314, 3150);
         poly.lineTo(310, 1301);
         poly.lineTo(3100, 311);
         com.esri.core.geometry.EditShape editShape = new com.esri.core.geometry.EditShape
                                                          ();
         int geom   = editShape.addGeometry(poly);
         int vertex = editShape.getFirstVertex(editShape.getFirstPath(geom));
         vertex = editShape.removeVertex(vertex, true);
         vertex = editShape.getNextVertex(vertex);
         editShape.removeVertex(vertex, true);
         com.esri.core.geometry.Polyline poly2 = (com.esri.core.geometry.Polyline)editShape
                                                 .getGeometry(geom);
         poly.setEmpty();
         poly.startPath(10, 12);
         poly.lineTo(310, 1301);
         poly.lineTo(3100, 311);
         NUnit.Framework.Assert.IsTrue(poly.Equals(poly2));
     }
     {
         // Test erase
         com.esri.core.geometry.Polygon poly = new com.esri.core.geometry.Polygon();
         poly.startPath(10, 10);
         poly.lineTo(10, 12);
         poly.lineTo(314, 3150);
         poly.lineTo(310, 1301);
         poly.lineTo(3100, 311);
         com.esri.core.geometry.EditShape editShape = new com.esri.core.geometry.EditShape
                                                          ();
         int geom   = editShape.addGeometry(poly);
         int vertex = editShape.getFirstVertex(editShape.getFirstPath(geom));
         vertex = editShape.removeVertex(vertex, true);
         vertex = editShape.getNextVertex(vertex);
         editShape.removeVertex(vertex, true);
         com.esri.core.geometry.Polygon poly2 = (com.esri.core.geometry.Polygon)editShape.
                                                getGeometry(geom);
         poly.setEmpty();
         poly.startPath(10, 12);
         poly.lineTo(310, 1301);
         poly.lineTo(3100, 311);
         NUnit.Framework.Assert.IsTrue(poly.Equals(poly2));
     }
     {
         // Test Filter Close Points
         com.esri.core.geometry.Polygon poly = new com.esri.core.geometry.Polygon();
         poly.startPath(10, 10);
         poly.lineTo(10, 10.001);
         poly.lineTo(10.001, 10);
         com.esri.core.geometry.EditShape editShape = new com.esri.core.geometry.EditShape
                                                          ();
         int geom = editShape.addGeometry(poly);
         editShape.filterClosePoints(0.002, true, false);
         com.esri.core.geometry.Polygon poly2 = (com.esri.core.geometry.Polygon)editShape.
                                                getGeometry(geom);
         NUnit.Framework.Assert.IsTrue(poly2.isEmpty());
     }
     {
         // Test Filter Close Points
         com.esri.core.geometry.Polygon poly = new com.esri.core.geometry.Polygon();
         poly.startPath(10, 10);
         poly.lineTo(10, 10.0025);
         poly.lineTo(11.0, 10);
         com.esri.core.geometry.EditShape editShape = new com.esri.core.geometry.EditShape
                                                          ();
         int geom = editShape.addGeometry(poly);
         editShape.filterClosePoints(0.002, true, false);
         com.esri.core.geometry.Polygon poly2 = (com.esri.core.geometry.Polygon)editShape.
                                                getGeometry(geom);
         NUnit.Framework.Assert.IsTrue(!poly2.isEmpty());
     }
     {
         // Test Filter Close Points
         com.esri.core.geometry.Polygon poly = new com.esri.core.geometry.Polygon();
         poly.startPath(10, 10);
         poly.lineTo(10, 10.001);
         poly.lineTo(11.0, 10);
         com.esri.core.geometry.EditShape editShape = new com.esri.core.geometry.EditShape
                                                          ();
         int geom = editShape.addGeometry(poly);
         editShape.filterClosePoints(0.002, true, false);
         com.esri.core.geometry.Polygon poly2 = (com.esri.core.geometry.Polygon)editShape.
                                                getGeometry(geom);
         NUnit.Framework.Assert.IsTrue(poly2.isEmpty());
     }
     {
         // Test attribute splitting 1
         com.esri.core.geometry.Polyline polyline = new com.esri.core.geometry.Polyline();
         polyline.startPath(0, 0);
         polyline.lineTo(1, 1);
         polyline.lineTo(2, 2);
         polyline.lineTo(3, 3);
         polyline.lineTo(4, 4);
         polyline.startPath(5, 5);
         polyline.lineTo(6, 6);
         polyline.lineTo(7, 7);
         polyline.lineTo(8, 8);
         polyline.lineTo(9, 9);
         polyline.addAttribute(com.esri.core.geometry.VertexDescription.Semantics.Z);
         polyline.setAttribute(com.esri.core.geometry.VertexDescription.Semantics.Z, 0, 0,
                               4);
         polyline.setAttribute(com.esri.core.geometry.VertexDescription.Semantics.Z, 1, 0,
                               8);
         polyline.setAttribute(com.esri.core.geometry.VertexDescription.Semantics.Z, 2, 0,
                               12);
         polyline.setAttribute(com.esri.core.geometry.VertexDescription.Semantics.Z, 3, 0,
                               16);
         polyline.setAttribute(com.esri.core.geometry.VertexDescription.Semantics.Z, 4, 0,
                               20);
         polyline.setAttribute(com.esri.core.geometry.VertexDescription.Semantics.Z, 5, 0,
                               22);
         polyline.setAttribute(com.esri.core.geometry.VertexDescription.Semantics.Z, 6, 0,
                               26);
         polyline.setAttribute(com.esri.core.geometry.VertexDescription.Semantics.Z, 7, 0,
                               30);
         polyline.setAttribute(com.esri.core.geometry.VertexDescription.Semantics.Z, 8, 0,
                               34);
         polyline.setAttribute(com.esri.core.geometry.VertexDescription.Semantics.Z, 9, 0,
                               38);
         com.esri.core.geometry.EditShape shape = new com.esri.core.geometry.EditShape();
         int geometry = shape.addGeometry(polyline);
         com.esri.core.geometry.AttributeStreamOfInt32 vertex_handles = new com.esri.core.geometry.AttributeStreamOfInt32
                                                                            (0);
         for (int path = shape.getFirstPath(geometry); path != -1; path = shape.getNextPath
                                                                              (path))
         {
             for (int vertex = shape.getFirstVertex(path); vertex != -1; vertex = shape.getNextVertex
                                                                                      (vertex))
             {
                 if (vertex != shape.getLastVertex(path))
                 {
                     vertex_handles.add(vertex);
                 }
             }
         }
         double[] t = new double[1];
         for (int i = 0; i < vertex_handles.size(); i++)
         {
             int vertex = vertex_handles.read(i);
             t[0] = 0.5;
             shape.splitSegment(vertex, t, 1);
         }
         com.esri.core.geometry.Polyline chopped_polyline = (com.esri.core.geometry.Polyline
                                                             )shape.getGeometry(geometry);
         NUnit.Framework.Assert.IsTrue(chopped_polyline.getPointCount() == 18);
         double att_ = 4;
         for (int i_1 = 0; i_1 < 18; i_1++)
         {
             double att = chopped_polyline.getAttributeAsDbl(com.esri.core.geometry.VertexDescription.Semantics
                                                             .Z, i_1, 0);
             NUnit.Framework.Assert.IsTrue(att == att_);
             att_ += 2;
         }
     }
     {
         // Test attribute splitting 2
         com.esri.core.geometry.Polyline line1 = new com.esri.core.geometry.Polyline();
         com.esri.core.geometry.Polyline line2 = new com.esri.core.geometry.Polyline();
         line1.addAttribute(com.esri.core.geometry.VertexDescription.Semantics.M);
         line2.addAttribute(com.esri.core.geometry.VertexDescription.Semantics.M);
         line1.startPath(0, 0);
         line1.lineTo(10, 10);
         line2.startPath(10, 0);
         line2.lineTo(0, 10);
         line1.setAttribute(com.esri.core.geometry.VertexDescription.Semantics.M, 0, 0, 7);
         line1.setAttribute(com.esri.core.geometry.VertexDescription.Semantics.M, 1, 0, 17
                            );
         line2.setAttribute(com.esri.core.geometry.VertexDescription.Semantics.M, 0, 0, 5);
         line2.setAttribute(com.esri.core.geometry.VertexDescription.Semantics.M, 1, 0, 15
                            );
         com.esri.core.geometry.EditShape shape = new com.esri.core.geometry.EditShape();
         int g1 = shape.addGeometry(line1);
         int g2 = shape.addGeometry(line2);
         com.esri.core.geometry.CrackAndCluster.execute(shape, 0.001, null, true);
         com.esri.core.geometry.Polyline chopped_line1 = (com.esri.core.geometry.Polyline)
                                                         shape.getGeometry(g1);
         com.esri.core.geometry.Polyline chopped_line2 = (com.esri.core.geometry.Polyline)
                                                         shape.getGeometry(g2);
         double att1 = chopped_line1.getAttributeAsDbl(com.esri.core.geometry.VertexDescription.Semantics
                                                       .M, 1, 0);
         double att2 = chopped_line2.getAttributeAsDbl(com.esri.core.geometry.VertexDescription.Semantics
                                                       .M, 1, 0);
         NUnit.Framework.Assert.IsTrue(att1 == 12);
         NUnit.Framework.Assert.IsTrue(att2 == 10);
     }
     {
         // Test attribute splitting 3
         com.esri.core.geometry.Polygon polygon = new com.esri.core.geometry.Polygon();
         polygon.addAttribute(com.esri.core.geometry.VertexDescription.Semantics.M);
         polygon.startPath(0, 0);
         polygon.lineTo(0, 10);
         polygon.lineTo(10, 10);
         polygon.lineTo(10, 0);
         polygon.setAttribute(com.esri.core.geometry.VertexDescription.Semantics.M, 0, 0,
                              7);
         polygon.setAttribute(com.esri.core.geometry.VertexDescription.Semantics.M, 1, 0,
                              17);
         polygon.setAttribute(com.esri.core.geometry.VertexDescription.Semantics.M, 2, 0,
                              23);
         polygon.setAttribute(com.esri.core.geometry.VertexDescription.Semantics.M, 3, 0,
                              43);
         com.esri.core.geometry.EditShape shape = new com.esri.core.geometry.EditShape();
         int geometry = shape.addGeometry(polygon);
         com.esri.core.geometry.AttributeStreamOfInt32 vertex_handles = new com.esri.core.geometry.AttributeStreamOfInt32
                                                                            (0);
         int start_v = shape.getFirstVertex(shape.getFirstPath(geometry));
         int v       = start_v;
         do
         {
             vertex_handles.add(v);
             v = shape.getNextVertex(v);
         }while (v != start_v);
         double[] t = new double[1];
         for (int i = 0; i < vertex_handles.size(); i++)
         {
             int v1 = vertex_handles.read(i);
             t[0] = 0.5;
             shape.splitSegment(v1, t, 1);
         }
         com.esri.core.geometry.Polygon cut_polygon = (com.esri.core.geometry.Polygon)shape
                                                      .getGeometry(geometry);
         NUnit.Framework.Assert.IsTrue(cut_polygon.getPointCount() == 8);
         com.esri.core.geometry.Point2D pt0 = cut_polygon.getXY(0);
         double a0 = cut_polygon.getAttributeAsDbl(com.esri.core.geometry.VertexDescription.Semantics
                                                   .M, 0, 0);
         NUnit.Framework.Assert.IsTrue(a0 == 25);
         com.esri.core.geometry.Point2D pt1 = cut_polygon.getXY(1);
         double a1 = cut_polygon.getAttributeAsDbl(com.esri.core.geometry.VertexDescription.Semantics
                                                   .M, 1, 0);
         NUnit.Framework.Assert.IsTrue(a1 == 7);
         com.esri.core.geometry.Point2D pt2 = cut_polygon.getXY(2);
         double a2 = cut_polygon.getAttributeAsDbl(com.esri.core.geometry.VertexDescription.Semantics
                                                   .M, 2, 0);
         NUnit.Framework.Assert.IsTrue(a2 == 12);
         com.esri.core.geometry.Point2D pt3 = cut_polygon.getXY(3);
         double a3 = cut_polygon.getAttributeAsDbl(com.esri.core.geometry.VertexDescription.Semantics
                                                   .M, 3, 0);
         NUnit.Framework.Assert.IsTrue(a3 == 17);
         com.esri.core.geometry.Point2D pt4 = cut_polygon.getXY(4);
         double a4 = cut_polygon.getAttributeAsDbl(com.esri.core.geometry.VertexDescription.Semantics
                                                   .M, 4, 0);
         NUnit.Framework.Assert.IsTrue(a4 == 20);
         com.esri.core.geometry.Point2D pt5 = cut_polygon.getXY(5);
         double a5 = cut_polygon.getAttributeAsDbl(com.esri.core.geometry.VertexDescription.Semantics
                                                   .M, 5, 0);
         NUnit.Framework.Assert.IsTrue(a5 == 23);
         com.esri.core.geometry.Point2D pt6 = cut_polygon.getXY(6);
         double a6 = cut_polygon.getAttributeAsDbl(com.esri.core.geometry.VertexDescription.Semantics
                                                   .M, 6, 0);
         NUnit.Framework.Assert.IsTrue(a6 == 33);
         com.esri.core.geometry.Point2D pt7 = cut_polygon.getXY(7);
         double a7 = cut_polygon.getAttributeAsDbl(com.esri.core.geometry.VertexDescription.Semantics
                                                   .M, 7, 0);
         NUnit.Framework.Assert.IsTrue(a7 == 43);
     }
 }
//		[NUnit.Framework.Test]
//		public virtual void TestPolylinePolylineCrosses()
//		{
//			com.esri.core.geometry.OperatorCrosses crosses = (com.esri.core.geometry.OperatorCrosses)(com.esri.core.geometry.OperatorFactoryLocal.GetInstance().GetOperator(com.esri.core.geometry.Operator.Type.Crosses));
//			com.esri.core.geometry.SpatialReference sr = com.esri.core.geometry.SpatialReference.Create(102100);
//			double tolerance = sr.GetTolerance(com.esri.core.geometry.VertexDescription.Semantics.POSITION);
//			// Polyline1 and Polyline2 touch at a point
//			string str1 = "{\"paths\":[[[0,0],[0,5],[0,10],[10,10],[10,0]],[[1,1],[9,1],[9,9],[1,9],[1,1],[1,1]]]}";
//			string str2 = "{\"paths\":[[[10,10],[10,15],[15,15],[15,10]]]}";
//			com.esri.core.geometry.Polyline polyline1 = (com.esri.core.geometry.Polyline)(com.esri.core.geometry.TestCommonMethods.FromJson(str1).GetGeometry());
//			com.esri.core.geometry.Polyline polyline2 = (com.esri.core.geometry.Polyline)(com.esri.core.geometry.TestCommonMethods.FromJson(str2).GetGeometry());
//			bool res = crosses.Execute(polyline1, polyline2, sr, null);
//			NUnit.Framework.Assert.IsTrue(!res);
//			res = crosses.Execute(polyline2, polyline1, sr, null);
//			NUnit.Framework.Assert.IsTrue(!res);
//			// Polyline1 and Polyline2 intersect at interiors
//			str1 = "{\"paths\":[[[0,0],[0,5],[0,10],[10,10],[10,0],[0,0]],[[1,1],[9,1],[9,9],[1,9],[1,1],[1,1]]]}";
//			str2 = "{\"paths\":[[[15,5],[5,15],[15,15],[15,5]]]}";
//			polyline1 = (com.esri.core.geometry.Polyline)(com.esri.core.geometry.TestCommonMethods.FromJson(str1).GetGeometry());
//			polyline2 = (com.esri.core.geometry.Polyline)(com.esri.core.geometry.TestCommonMethods.FromJson(str2).GetGeometry());
//			res = crosses.Execute(polyline1, polyline2, sr, null);
//			NUnit.Framework.Assert.IsTrue(res);
//			res = crosses.Execute(polyline2, polyline1, sr, null);
//			NUnit.Framework.Assert.IsTrue(res);
//			// Polyline1 and Polyline2 touch at an endpoint of Polyline1 and
//			// interior of Polyline2 (but Polyline1 is closed)
//			str1 = "{\"paths\":[[[10,10],[10,0],[0,0],[0,10],[10,10]],[[1,1],[9,1],[9,9],[1,9],[1,1],[1,1]]]}";
//			str2 = "{\"paths\":[[[15,5],[5,15],[15,15]]]}";
//			polyline1 = (com.esri.core.geometry.Polyline)(com.esri.core.geometry.TestCommonMethods.FromJson(str1).GetGeometry());
//			polyline2 = (com.esri.core.geometry.Polyline)(com.esri.core.geometry.TestCommonMethods.FromJson(str2).GetGeometry());
//			res = crosses.Execute(polyline1, polyline2, sr, null);
//			NUnit.Framework.Assert.IsTrue(res);
//			res = crosses.Execute(polyline2, polyline1, sr, null);
//			NUnit.Framework.Assert.IsTrue(res);
//			// Polyline1 and Polyline2 touch at an endpoint of Polyline1 and
//			// interior of Polyline2 (same as previous case, but Polyline1 is not
//			// closed)
//			str1 = "{\"paths\":[[[10,10],[10,0],[0,0],[0,10]],[[1,1],[9,1],[9,9],[1,9],[1,1],[1,1]]]}";
//			str2 = "{\"paths\":[[[15,5],[5,15],[15,15]]]}";
//			polyline1 = (com.esri.core.geometry.Polyline)(com.esri.core.geometry.TestCommonMethods.FromJson(str1).GetGeometry());
//			polyline2 = (com.esri.core.geometry.Polyline)(com.esri.core.geometry.TestCommonMethods.FromJson(str2).GetGeometry());
//			res = crosses.Execute(polyline1, polyline2, sr, null);
//			NUnit.Framework.Assert.IsTrue(!res);
//			res = crosses.Execute(polyline2, polyline1, sr, null);
//			NUnit.Framework.Assert.IsTrue(!res);
//			str1 = "{\"paths\":[[[10,11],[10,0],[0,0],[0,10]],[[1,1],[9,1],[9,9],[1,9],[6, 9]]]}";
//			str2 = "{\"paths\":[[[15,5],[5,15],[15,15],[15,5]]]}";
//			polyline1 = (com.esri.core.geometry.Polyline)(com.esri.core.geometry.TestCommonMethods.FromJson(str1).GetGeometry());
//			polyline2 = (com.esri.core.geometry.Polyline)(com.esri.core.geometry.TestCommonMethods.FromJson(str2).GetGeometry());
//			res = crosses.Execute(polyline1, polyline2, sr, null);
//			NUnit.Framework.Assert.IsTrue(res);
//			res = crosses.Execute(polyline2, polyline1, sr, null);
//			NUnit.Framework.Assert.IsTrue(res);
//			polyline1.SetEmpty();
//			polyline2.SetEmpty();
//			polyline1.StartPath(-2, -2);
//			polyline1.LineTo(-1, -1);
//			polyline1.LineTo(1, 1);
//			polyline1.LineTo(2, 2);
//			polyline2.StartPath(-2, 2);
//			polyline2.LineTo(-1, 1);
//			polyline2.LineTo(1, -1);
//			polyline2.LineTo(2, -2);
//			res = crosses.Execute(polyline2, polyline1, sr, null);
//			NUnit.Framework.Assert.IsTrue(res);
//		}
//
//		[NUnit.Framework.Test]
//		public virtual void TestPolygonEnvelope()
//		{
//			com.esri.core.geometry.OperatorEquals equals = (com.esri.core.geometry.OperatorEquals)(com.esri.core.geometry.OperatorFactoryLocal.GetInstance().GetOperator(com.esri.core.geometry.Operator.Type.Equals));
//			com.esri.core.geometry.OperatorContains contains = (com.esri.core.geometry.OperatorContains)(com.esri.core.geometry.OperatorFactoryLocal.GetInstance().GetOperator(com.esri.core.geometry.Operator.Type.Contains));
//			com.esri.core.geometry.OperatorDisjoint disjoint = (com.esri.core.geometry.OperatorDisjoint)(com.esri.core.geometry.OperatorFactoryLocal.GetInstance().GetOperator(com.esri.core.geometry.Operator.Type.Disjoint));
//			com.esri.core.geometry.OperatorCrosses crosses = (com.esri.core.geometry.OperatorCrosses)(com.esri.core.geometry.OperatorFactoryLocal.GetInstance().GetOperator(com.esri.core.geometry.Operator.Type.Crosses));
//			com.esri.core.geometry.OperatorWithin within = (com.esri.core.geometry.OperatorWithin)(com.esri.core.geometry.OperatorFactoryLocal.GetInstance().GetOperator(com.esri.core.geometry.Operator.Type.Within));
//			com.esri.core.geometry.OperatorOverlaps overlaps = (com.esri.core.geometry.OperatorOverlaps)(com.esri.core.geometry.OperatorFactoryLocal.GetInstance().GetOperator(com.esri.core.geometry.Operator.Type.Overlaps));
//			com.esri.core.geometry.OperatorTouches touches = (com.esri.core.geometry.OperatorTouches)(com.esri.core.geometry.OperatorFactoryLocal.GetInstance().GetOperator(com.esri.core.geometry.Operator.Type.Touches));
//			com.esri.core.geometry.OperatorDensifyByLength densify = (com.esri.core.geometry.OperatorDensifyByLength)(com.esri.core.geometry.OperatorFactoryLocal.GetInstance().GetOperator(com.esri.core.geometry.Operator.Type.DensifyByLength));
//			com.esri.core.geometry.SpatialReference sr = com.esri.core.geometry.SpatialReference.Create(4326);
//			{
//				com.esri.core.geometry.Polygon polygon = (com.esri.core.geometry.Polygon)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"rings\":[[[0,0],[0,5],[0,10],[10,10],[10,0],[0,0]]]}").GetGeometry());
//				com.esri.core.geometry.Polygon densified = (com.esri.core.geometry.Polygon)(densify.Execute(polygon, 1.0, null));
//				com.esri.core.geometry.Envelope envelope = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":0,\"ymin\":0,\"xmax\":10,\"ymax\":10}").GetGeometry());
//				WiggleGeometry(densified, 0.00000001, 1982);
//				WiggleGeometry(envelope, 0.00000001, 511);
//				NUnit.Framework.Assert.IsTrue(equals.Execute(envelope, densified, sr, null));
//				// they
//				// cover
//				// the
//				// same
//				// space
//				NUnit.Framework.Assert.IsTrue(contains.Execute(densified, envelope, sr, null));
//				NUnit.Framework.Assert.IsTrue(!disjoint.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!touches.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(envelope, densified, sr, null));
//			}
//			{
//				com.esri.core.geometry.Polygon polygon = (com.esri.core.geometry.Polygon)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"rings\":[[[0,0],[0,5],[0,10],[10,10],[10,0],[0,0]]]}").GetGeometry());
//				com.esri.core.geometry.Polygon densified = (com.esri.core.geometry.Polygon)(densify.Execute(polygon, 1.0, null));
//				com.esri.core.geometry.Envelope envelope = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":5,\"ymin\":0,\"xmax\":10,\"ymax\":10}").GetGeometry());
//				WiggleGeometry(densified, 0.00000001, 1982);
//				WiggleGeometry(envelope, 0.00000001, 511);
//				NUnit.Framework.Assert.IsTrue(!equals.Execute(envelope, densified, sr, null));
//				// the
//				// polygon
//				// contains
//				// the
//				// envelope,
//				// but
//				// they
//				// aren't
//				// equal
//				NUnit.Framework.Assert.IsTrue(contains.Execute(densified, envelope, sr, null));
//				NUnit.Framework.Assert.IsTrue(!disjoint.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!touches.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(envelope, densified, sr, null));
//			}
//			{
//				com.esri.core.geometry.Polygon polygon = (com.esri.core.geometry.Polygon)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"rings\":[[[0,0],[0,5],[0,10],[10,10],[10,0],[0,0]]]}").GetGeometry());
//				com.esri.core.geometry.Polygon densified = (com.esri.core.geometry.Polygon)(densify.Execute(polygon, 1.0, null));
//				com.esri.core.geometry.Envelope envelope = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":0,\"ymin\":0,\"xmax\":15,\"ymax\":10}").GetGeometry());
//				WiggleGeometry(densified, 0.00000001, 1982);
//				WiggleGeometry(envelope, 0.00000001, 511);
//				NUnit.Framework.Assert.IsTrue(!equals.Execute(envelope, densified, sr, null));
//				// the
//				// envelope
//				// sticks
//				// outside
//				// of
//				// the
//				// polygon
//				// but
//				// they
//				// intersect
//				NUnit.Framework.Assert.IsTrue(!contains.Execute(densified, envelope, sr, null));
//				NUnit.Framework.Assert.IsTrue(!disjoint.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!touches.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(envelope, densified, sr, null));
//			}
//			{
//				com.esri.core.geometry.Polygon polygon = (com.esri.core.geometry.Polygon)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"rings\":[[[0,0],[0,5],[0,10],[10,10],[10,0],[0,0]]]}").GetGeometry());
//				com.esri.core.geometry.Polygon densified = (com.esri.core.geometry.Polygon)(densify.Execute(polygon, 1.0, null));
//				com.esri.core.geometry.Envelope envelope = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":5,\"ymin\":0,\"xmax\":15,\"ymax\":10}").GetGeometry());
//				WiggleGeometry(densified, 0.00000001, 1982);
//				WiggleGeometry(envelope, 0.00000001, 511);
//				NUnit.Framework.Assert.IsTrue(!equals.Execute(envelope, densified, sr, null));
//				// the
//				// envelope
//				// sticks
//				// outside
//				// of
//				// the
//				// polygon
//				// but
//				// they
//				// intersect
//				// and
//				// overlap
//				NUnit.Framework.Assert.IsTrue(!contains.Execute(densified, envelope, sr, null));
//				NUnit.Framework.Assert.IsTrue(!disjoint.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!touches.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(overlaps.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(envelope, densified, sr, null));
//			}
//			{
//				com.esri.core.geometry.Polygon polygon = (com.esri.core.geometry.Polygon)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"rings\":[[[0,0],[0,5],[0,10],[10,10],[10,0],[0,0]]]}").GetGeometry());
//				com.esri.core.geometry.Polygon densified = (com.esri.core.geometry.Polygon)(densify.Execute(polygon, 1.0, null));
//				com.esri.core.geometry.Envelope envelope = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":10,\"ymin\":0,\"xmax\":15,\"ymax\":5}").GetGeometry());
//				WiggleGeometry(densified, 0.00000001, 1982);
//				WiggleGeometry(envelope, 0.00000001, 511);
//				NUnit.Framework.Assert.IsTrue(!equals.Execute(envelope, densified, sr, null));
//				// the
//				// envelope
//				// rides
//				// the
//				// side
//				// of
//				// the
//				// polygon
//				// (they
//				// touch)
//				NUnit.Framework.Assert.IsTrue(!contains.Execute(densified, envelope, sr, null));
//				NUnit.Framework.Assert.IsTrue(!disjoint.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(touches.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(envelope, densified, sr, null));
//			}
//			{
//				com.esri.core.geometry.Polygon polygon = (com.esri.core.geometry.Polygon)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"rings\":[[[0,0],[0,5],[0,10],[10,10],[10,0],[0,0]]]}").GetGeometry());
//				com.esri.core.geometry.Polygon densified = (com.esri.core.geometry.Polygon)(densify.Execute(polygon, 1.0, null));
//				com.esri.core.geometry.Envelope envelope = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":0,\"ymin\":0,\"xmax\":10,\"ymax\":10}").GetGeometry());
//				WiggleGeometry(densified, 0.00000001, 1982);
//				WiggleGeometry(envelope, 0.00000001, 511);
//				NUnit.Framework.Assert.IsTrue(contains.Execute(densified, envelope, sr, null));
//				// polygon
//				// and
//				// envelope
//				// cover
//				// the
//				// same
//				// space
//				NUnit.Framework.Assert.IsTrue(!disjoint.Execute(densified, envelope, sr, null));
//				NUnit.Framework.Assert.IsTrue(!touches.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(envelope, densified, sr, null));
//			}
//			{
//				com.esri.core.geometry.Polygon polygon = (com.esri.core.geometry.Polygon)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"rings\":[[[0,0],[0,5],[0,10],[10,0],[0,0]]]}").GetGeometry());
//				com.esri.core.geometry.Polygon densified = (com.esri.core.geometry.Polygon)(densify.Execute(polygon, 1.0, null));
//				com.esri.core.geometry.Envelope envelope = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":0,\"ymin\":0,\"xmax\":10,\"ymax\":10}").GetGeometry());
//				WiggleGeometry(densified, 0.00000001, 1982);
//				WiggleGeometry(envelope, 0.00000001, 511);
//				NUnit.Framework.Assert.IsTrue(!equals.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!contains.Execute(densified, envelope, sr, null));
//				// envelope
//				// sticks
//				// outside
//				// of
//				// polygon,
//				// but
//				// the
//				// envelopes
//				// are
//				// equal
//				NUnit.Framework.Assert.IsTrue(!disjoint.Execute(densified, envelope, sr, null));
//				NUnit.Framework.Assert.IsTrue(!touches.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(envelope, densified, sr, null));
//			}
//			{
//				com.esri.core.geometry.Polygon polygon = (com.esri.core.geometry.Polygon)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"rings\":[[[0,0],[0,5],[0,10],[10,0],[0,0]]]}").GetGeometry());
//				com.esri.core.geometry.Polygon densified = (com.esri.core.geometry.Polygon)(densify.Execute(polygon, 1.0, null));
//				com.esri.core.geometry.Envelope envelope = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":0,\"ymin\":0,\"xmax\":15,\"ymax\":10}").GetGeometry());
//				WiggleGeometry(densified, 0.00000001, 1982);
//				WiggleGeometry(envelope, 0.00000001, 511);
//				NUnit.Framework.Assert.IsTrue(!equals.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!contains.Execute(densified, envelope, sr, null));
//				// the
//				// polygon
//				// envelope
//				// doesn't
//				// contain
//				// the
//				// envelope,
//				// but
//				// they
//				// intersect
//				NUnit.Framework.Assert.IsTrue(!disjoint.Execute(densified, envelope, sr, null));
//				NUnit.Framework.Assert.IsTrue(!touches.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(envelope, densified, sr, null));
//			}
//			{
//				com.esri.core.geometry.Polygon polygon = (com.esri.core.geometry.Polygon)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"rings\":[[[0,0],[0,5],[0,10],[10,10],[10,0],[0,0]]]}").GetGeometry());
//				com.esri.core.geometry.Polygon densified = (com.esri.core.geometry.Polygon)(densify.Execute(polygon, 1.0, null));
//				com.esri.core.geometry.Envelope envelope = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":0,\"ymin\":0,\"xmax\":0,\"ymax\":0}").GetGeometry());
//				WiggleGeometry(densified, 0.00000001, 1982);
//				WiggleGeometry(envelope, 0.00000001, 511);
//				NUnit.Framework.Assert.IsTrue(!equals.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!contains.Execute(densified, envelope, sr, null));
//				// envelope
//				// degenerate
//				// to
//				// a
//				// point
//				// and
//				// is
//				// on
//				// border
//				// (i.e.
//				// touches)
//				NUnit.Framework.Assert.IsTrue(!disjoint.Execute(densified, envelope, sr, null));
//				NUnit.Framework.Assert.IsTrue(touches.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(envelope, densified, sr, null));
//			}
//			{
//				com.esri.core.geometry.Polygon polygon = (com.esri.core.geometry.Polygon)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"rings\":[[[0,0],[0,5],[0,10],[10,10],[10,0],[0,0]]]}").GetGeometry());
//				com.esri.core.geometry.Polygon densified = (com.esri.core.geometry.Polygon)(densify.Execute(polygon, 1.0, null));
//				com.esri.core.geometry.Envelope envelope = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":1,\"ymin\":1,\"xmax\":1,\"ymax\":1}").GetGeometry());
//				WiggleGeometry(densified, 0.00000001, 1982);
//				WiggleGeometry(envelope, 0.00000001, 511);
//				NUnit.Framework.Assert.IsTrue(!equals.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(contains.Execute(densified, envelope, sr, null));
//				// envelope
//				// degenerate
//				// to
//				// a
//				// point
//				// and
//				// is
//				// properly
//				// inside
//				NUnit.Framework.Assert.IsTrue(!disjoint.Execute(densified, envelope, sr, null));
//				NUnit.Framework.Assert.IsTrue(!touches.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(envelope, densified, sr, null));
//			}
//			{
//				com.esri.core.geometry.Polygon polygon = (com.esri.core.geometry.Polygon)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"rings\":[[[0,0],[0,5],[0,10],[10,10],[10,0],[0,0]]]}").GetGeometry());
//				com.esri.core.geometry.Polygon densified = (com.esri.core.geometry.Polygon)(densify.Execute(polygon, 1.0, null));
//				com.esri.core.geometry.Envelope envelope = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":-1,\"ymin\":-1,\"xmax\":-1,\"ymax\":-1}").GetGeometry());
//				WiggleGeometry(densified, 0.00000001, 1982);
//				WiggleGeometry(envelope, 0.00000001, 511);
//				NUnit.Framework.Assert.IsTrue(!equals.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!contains.Execute(densified, envelope, sr, null));
//				// envelope
//				// degenerate
//				// to
//				// a
//				// point
//				// and
//				// is
//				// properly
//				// outside
//				NUnit.Framework.Assert.IsTrue(disjoint.Execute(densified, envelope, sr, null));
//				NUnit.Framework.Assert.IsTrue(!touches.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(envelope, densified, sr, null));
//			}
//			{
//				com.esri.core.geometry.Polygon polygon = (com.esri.core.geometry.Polygon)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"rings\":[[[0,0],[0,5],[0,10],[10,10],[10,0],[0,0]]]}").GetGeometry());
//				com.esri.core.geometry.Polygon densified = (com.esri.core.geometry.Polygon)(densify.Execute(polygon, 1.0, null));
//				com.esri.core.geometry.Envelope envelope = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":0,\"ymin\":0,\"xmax\":1,\"ymax\":0}").GetGeometry());
//				WiggleGeometry(densified, 0.00000001, 1982);
//				WiggleGeometry(envelope, 0.00000001, 511);
//				NUnit.Framework.Assert.IsTrue(!equals.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!contains.Execute(densified, envelope, sr, null));
//				// envelope
//				// degenerate
//				// to
//				// a
//				// line
//				// and
//				// rides
//				// the
//				// bottom
//				// of
//				// the
//				// polygon
//				// (no
//				// interior
//				// intersection)
//				NUnit.Framework.Assert.IsTrue(!disjoint.Execute(densified, envelope, sr, null));
//				NUnit.Framework.Assert.IsTrue(touches.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(envelope, densified, sr, null));
//			}
//			{
//				com.esri.core.geometry.Polygon polygon = (com.esri.core.geometry.Polygon)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"rings\":[[[0,0],[0,5],[0,10],[10,10],[10,0],[0,0]]]}").GetGeometry());
//				com.esri.core.geometry.Polygon densified = (com.esri.core.geometry.Polygon)(densify.Execute(polygon, 1.0, null));
//				com.esri.core.geometry.Envelope envelope = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":0,\"ymin\":1,\"xmax\":1,\"ymax\":1}").GetGeometry());
//				WiggleGeometry(densified, 0.00000001, 1982);
//				WiggleGeometry(envelope, 0.00000001, 511);
//				NUnit.Framework.Assert.IsTrue(!equals.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(contains.Execute(densified, envelope, sr, null));
//				// envelope
//				// degenerate
//				// to
//				// a
//				// line,
//				// touches
//				// the
//				// border
//				// on
//				// the
//				// inside
//				// yet
//				// has
//				// interior
//				// intersection
//				NUnit.Framework.Assert.IsTrue(!disjoint.Execute(densified, envelope, sr, null));
//				NUnit.Framework.Assert.IsTrue(!touches.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(envelope, densified, sr, null));
//			}
//			{
//				com.esri.core.geometry.Polygon polygon = (com.esri.core.geometry.Polygon)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"rings\":[[[0,0],[0,5],[0,10],[10,0],[0,0]]]}").GetGeometry());
//				com.esri.core.geometry.Polygon densified = (com.esri.core.geometry.Polygon)(densify.Execute(polygon, 1.0, null));
//				com.esri.core.geometry.Envelope envelope = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":5,\"ymin\":5,\"xmax\":6,\"ymax\":5}").GetGeometry());
//				WiggleGeometry(densified, 0.00000001, 1982);
//				WiggleGeometry(envelope, 0.00000001, 511);
//				NUnit.Framework.Assert.IsTrue(!equals.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!contains.Execute(densified, envelope, sr, null));
//				// envelope
//				// degenerate
//				// to
//				// a
//				// line,
//				// touches
//				// the
//				// boundary,
//				// and
//				// is
//				// outside
//				NUnit.Framework.Assert.IsTrue(!disjoint.Execute(densified, envelope, sr, null));
//				NUnit.Framework.Assert.IsTrue(touches.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(envelope, densified, sr, null));
//			}
//			{
//				com.esri.core.geometry.Polygon polygon = (com.esri.core.geometry.Polygon)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"rings\":[[[0,0],[0,5],[0,10],[10,0],[0,0]]]}").GetGeometry());
//				com.esri.core.geometry.Polygon densified = (com.esri.core.geometry.Polygon)(densify.Execute(polygon, 1.0, null));
//				com.esri.core.geometry.Envelope envelope = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":6,\"ymin\":5,\"xmax\":7,\"ymax\":5}").GetGeometry());
//				WiggleGeometry(densified, 0.00000001, 1982);
//				WiggleGeometry(envelope, 0.00000001, 511);
//				NUnit.Framework.Assert.IsTrue(!equals.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!contains.Execute(densified, envelope, sr, null));
//				// envelope
//				// degenerate
//				// to
//				// a
//				// line,
//				// and
//				// is
//				// outside
//				NUnit.Framework.Assert.IsTrue(disjoint.Execute(densified, envelope, sr, null));
//				NUnit.Framework.Assert.IsTrue(!touches.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(envelope, densified, sr, null));
//			}
//			{
//				com.esri.core.geometry.Polygon polygon = (com.esri.core.geometry.Polygon)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"rings\":[[[0,0],[0,5],[0,10],[10,0],[0,0]]]}").GetGeometry());
//				com.esri.core.geometry.Polygon densified = (com.esri.core.geometry.Polygon)(densify.Execute(polygon, 1.0, null));
//				com.esri.core.geometry.Envelope envelope = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":4,\"ymin\":5,\"xmax\":7,\"ymax\":5}").GetGeometry());
//				WiggleGeometry(densified, 0.00000001, 1982);
//				WiggleGeometry(envelope, 0.00000001, 511);
//				NUnit.Framework.Assert.IsTrue(!equals.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!contains.Execute(densified, envelope, sr, null));
//				// envelope
//				// degenerate
//				// to
//				// a
//				// line,
//				// and
//				// crosses
//				// polygon
//				NUnit.Framework.Assert.IsTrue(!disjoint.Execute(densified, envelope, sr, null));
//				NUnit.Framework.Assert.IsTrue(!touches.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(crosses.Execute(envelope, densified, sr, null));
//			}
//		}
//
//		[NUnit.Framework.Test]
//		public virtual void TestPolylineEnvelope()
//		{
//			com.esri.core.geometry.OperatorEquals equals = (com.esri.core.geometry.OperatorEquals)(com.esri.core.geometry.OperatorFactoryLocal.GetInstance().GetOperator(com.esri.core.geometry.Operator.Type.Equals));
//			com.esri.core.geometry.OperatorContains contains = (com.esri.core.geometry.OperatorContains)(com.esri.core.geometry.OperatorFactoryLocal.GetInstance().GetOperator(com.esri.core.geometry.Operator.Type.Contains));
//			com.esri.core.geometry.OperatorDisjoint disjoint = (com.esri.core.geometry.OperatorDisjoint)(com.esri.core.geometry.OperatorFactoryLocal.GetInstance().GetOperator(com.esri.core.geometry.Operator.Type.Disjoint));
//			com.esri.core.geometry.OperatorCrosses crosses = (com.esri.core.geometry.OperatorCrosses)(com.esri.core.geometry.OperatorFactoryLocal.GetInstance().GetOperator(com.esri.core.geometry.Operator.Type.Crosses));
//			com.esri.core.geometry.OperatorWithin within = (com.esri.core.geometry.OperatorWithin)(com.esri.core.geometry.OperatorFactoryLocal.GetInstance().GetOperator(com.esri.core.geometry.Operator.Type.Within));
//			com.esri.core.geometry.OperatorOverlaps overlaps = (com.esri.core.geometry.OperatorOverlaps)(com.esri.core.geometry.OperatorFactoryLocal.GetInstance().GetOperator(com.esri.core.geometry.Operator.Type.Overlaps));
//			com.esri.core.geometry.OperatorTouches touches = (com.esri.core.geometry.OperatorTouches)(com.esri.core.geometry.OperatorFactoryLocal.GetInstance().GetOperator(com.esri.core.geometry.Operator.Type.Touches));
//			com.esri.core.geometry.OperatorDensifyByLength densify = (com.esri.core.geometry.OperatorDensifyByLength)(com.esri.core.geometry.OperatorFactoryLocal.GetInstance().GetOperator(com.esri.core.geometry.Operator.Type.DensifyByLength));
//			com.esri.core.geometry.SpatialReference sr = com.esri.core.geometry.SpatialReference.Create(4326);
//			{
//				com.esri.core.geometry.Polyline polyline = (com.esri.core.geometry.Polyline)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"paths\":[[[0,0],[0,5],[0,10],[10,10],[10,0]]]}").GetGeometry());
//				com.esri.core.geometry.Polyline densified = (com.esri.core.geometry.Polyline)(densify.Execute(polyline, 1.0, null));
//				com.esri.core.geometry.Envelope envelope = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":0,\"ymin\":0,\"xmax\":10,\"ymax\":10}").GetGeometry());
//				WiggleGeometry(densified, 0.00000001, 1982);
//				WiggleGeometry(envelope, 0.00000001, 511);
//				NUnit.Framework.Assert.IsTrue(!equals.Execute(envelope, densified, sr, null));
//				// polyline
//				// straddles
//				// the
//				// envelope
//				// like
//				// a hat
//				NUnit.Framework.Assert.IsTrue(!contains.Execute(densified, envelope, sr, null));
//				NUnit.Framework.Assert.IsTrue(!disjoint.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(touches.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(envelope, densified, sr, null));
//			}
//			{
//				com.esri.core.geometry.Polyline polyline = (com.esri.core.geometry.Polyline)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"paths\":[[[-10,0],[0,10]]]}").GetGeometry());
//				com.esri.core.geometry.Polyline densified = (com.esri.core.geometry.Polyline)(densify.Execute(polyline, 1.0, null));
//				com.esri.core.geometry.Envelope envelope = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":0,\"ymin\":0,\"xmax\":10,\"ymax\":10}").GetGeometry());
//				WiggleGeometry(densified, 0.00000001, 1982);
//				WiggleGeometry(envelope, 0.00000001, 511);
//				NUnit.Framework.Assert.IsTrue(!equals.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!contains.Execute(densified, envelope, sr, null));
//				NUnit.Framework.Assert.IsTrue(!disjoint.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(touches.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(touches.Execute(densified, envelope, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(envelope, densified, sr, null));
//			}
//			{
//				com.esri.core.geometry.Polyline polyline = (com.esri.core.geometry.Polyline)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"paths\":[[[-11,0],[1,12]]]}").GetGeometry());
//				com.esri.core.geometry.Polyline densified = (com.esri.core.geometry.Polyline)(densify.Execute(polyline, 1.0, null));
//				com.esri.core.geometry.Envelope envelope = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":0,\"ymin\":0,\"xmax\":10,\"ymax\":10}").GetGeometry());
//				WiggleGeometry(densified, 0.00000001, 1982);
//				WiggleGeometry(envelope, 0.00000001, 511);
//				NUnit.Framework.Assert.IsTrue(!equals.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!contains.Execute(densified, envelope, sr, null));
//				NUnit.Framework.Assert.IsTrue(disjoint.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!touches.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!touches.Execute(densified, envelope, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(envelope, densified, sr, null));
//			}
//			{
//				com.esri.core.geometry.Polyline polyline = (com.esri.core.geometry.Polyline)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"paths\":[[[5,5],[6,6]]]}").GetGeometry());
//				com.esri.core.geometry.Polyline densified = (com.esri.core.geometry.Polyline)(densify.Execute(polyline, 1.0, null));
//				com.esri.core.geometry.Envelope envelope = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":0,\"ymin\":0,\"xmax\":10,\"ymax\":10}").GetGeometry());
//				WiggleGeometry(densified, 0.00000001, 1982);
//				WiggleGeometry(envelope, 0.00000001, 511);
//				NUnit.Framework.Assert.IsTrue(!equals.Execute(envelope, densified, sr, null));
//				// polyline
//				// properly
//				// inside
//				NUnit.Framework.Assert.IsTrue(contains.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!disjoint.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!touches.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(envelope, densified, sr, null));
//			}
//			{
//				com.esri.core.geometry.Polyline polyline = (com.esri.core.geometry.Polyline)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"paths\":[[[5,5],[10,10]]]}").GetGeometry());
//				com.esri.core.geometry.Polyline densified = (com.esri.core.geometry.Polyline)(densify.Execute(polyline, 1.0, null));
//				com.esri.core.geometry.Envelope envelope = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":0,\"ymin\":0,\"xmax\":10,\"ymax\":10}").GetGeometry());
//				WiggleGeometry(densified, 0.00000001, 1982);
//				WiggleGeometry(envelope, 0.00000001, 511);
//				NUnit.Framework.Assert.IsTrue(!equals.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(contains.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!disjoint.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!touches.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(envelope, densified, sr, null));
//			}
//			{
//				com.esri.core.geometry.Polyline polyline = (com.esri.core.geometry.Polyline)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"paths\":[[[-5,5],[15,5]]]}").GetGeometry());
//				com.esri.core.geometry.Polyline densified = (com.esri.core.geometry.Polyline)(densify.Execute(polyline, 1.0, null));
//				com.esri.core.geometry.Envelope envelope = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":0,\"ymin\":0,\"xmax\":10,\"ymax\":10}").GetGeometry());
//				WiggleGeometry(densified, 0.00000001, 1982);
//				WiggleGeometry(envelope, 0.00000001, 511);
//				NUnit.Framework.Assert.IsTrue(!equals.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!contains.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!disjoint.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!touches.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(crosses.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(crosses.Execute(densified, envelope, sr, null));
//			}
//			{
//				com.esri.core.geometry.Polyline polyline = (com.esri.core.geometry.Polyline)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"paths\":[[[5,5],[5,15]]]}").GetGeometry());
//				com.esri.core.geometry.Polyline densified = (com.esri.core.geometry.Polyline)(densify.Execute(polyline, 1.0, null));
//				com.esri.core.geometry.Envelope envelope = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":0,\"ymin\":0,\"xmax\":10,\"ymax\":10}").GetGeometry());
//				WiggleGeometry(densified, 0.00000001, 1982);
//				WiggleGeometry(envelope, 0.00000001, 511);
//				NUnit.Framework.Assert.IsTrue(!equals.Execute(envelope, densified, sr, null));
//				// polyline
//				// slices
//				// through
//				// the
//				// envelope
//				// (interior
//				// and
//				// exterior
//				// intersection)
//				NUnit.Framework.Assert.IsTrue(!contains.Execute(densified, envelope, sr, null));
//				NUnit.Framework.Assert.IsTrue(!disjoint.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!touches.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(crosses.Execute(envelope, densified, sr, null));
//			}
//			{
//				com.esri.core.geometry.Polyline polyline = (com.esri.core.geometry.Polyline)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"paths\":[[[5,11],[5,15]]]}").GetGeometry());
//				com.esri.core.geometry.Polyline densified = (com.esri.core.geometry.Polyline)(densify.Execute(polyline, 1.0, null));
//				com.esri.core.geometry.Envelope envelope = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":0,\"ymin\":0,\"xmax\":10,\"ymax\":10}").GetGeometry());
//				WiggleGeometry(densified, 0.00000001, 1982);
//				WiggleGeometry(envelope, 0.00000001, 511);
//				NUnit.Framework.Assert.IsTrue(!equals.Execute(envelope, densified, sr, null));
//				// polyline
//				// outside
//				// of
//				// envelope
//				NUnit.Framework.Assert.IsTrue(!contains.Execute(densified, envelope, sr, null));
//				NUnit.Framework.Assert.IsTrue(disjoint.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!touches.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(envelope, densified, sr, null));
//			}
//			{
//				com.esri.core.geometry.Polyline polyline = (com.esri.core.geometry.Polyline)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"paths\":[[[0,0],[0,5],[0,10],[10,10],[10,0]]]}").GetGeometry());
//				com.esri.core.geometry.Polyline densified = (com.esri.core.geometry.Polyline)(densify.Execute(polyline, 1.0, null));
//				com.esri.core.geometry.Envelope envelope = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":0,\"ymin\":10,\"xmax\":10,\"ymax\":10}").GetGeometry());
//				WiggleGeometry(densified, 0.00000001, 1982);
//				WiggleGeometry(envelope, 0.00000001, 511);
//				NUnit.Framework.Assert.IsTrue(!equals.Execute(envelope, densified, sr, null));
//				// polyline
//				// straddles
//				// the
//				// degenerate
//				// envelope
//				// like
//				// a hat
//				NUnit.Framework.Assert.IsTrue(contains.Execute(densified, envelope, sr, null));
//				NUnit.Framework.Assert.IsTrue(!disjoint.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!touches.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(envelope, densified, sr, null));
//			}
//			{
//				com.esri.core.geometry.Polyline polyline = (com.esri.core.geometry.Polyline)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"paths\":[[[0,0],[0,5],[0,10],[10,10],[10,0]]]}").GetGeometry());
//				com.esri.core.geometry.Polyline densified = (com.esri.core.geometry.Polyline)(densify.Execute(polyline, 1.0, null));
//				com.esri.core.geometry.Envelope envelope = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":0,\"ymin\":-5,\"xmax\":0,\"ymax\":10}").GetGeometry());
//				WiggleGeometry(densified, 0.00000001, 1982);
//				WiggleGeometry(envelope, 0.00000001, 511);
//				NUnit.Framework.Assert.IsTrue(!equals.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!contains.Execute(densified, envelope, sr, null));
//				NUnit.Framework.Assert.IsTrue(!disjoint.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!touches.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(overlaps.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(envelope, densified, sr, null));
//			}
//			{
//				com.esri.core.geometry.Polyline polyline = (com.esri.core.geometry.Polyline)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"paths\":[[[0,0],[0,5],[0,10],[10,10],[10,0]]]}").GetGeometry());
//				com.esri.core.geometry.Polyline densified = (com.esri.core.geometry.Polyline)(densify.Execute(polyline, 1.0, null));
//				com.esri.core.geometry.Envelope envelope = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":0,\"ymin\":0,\"xmax\":0,\"ymax\":0}").GetGeometry());
//				WiggleGeometry(densified, 0.00000001, 511);
//				WiggleGeometry(envelope, 0.00000001, 1982);
//				NUnit.Framework.Assert.IsTrue(!equals.Execute(envelope, densified, sr, null));
//				// degenerate
//				// envelope
//				// is at
//				// the
//				// end
//				// point
//				// of
//				// polyline
//				NUnit.Framework.Assert.IsTrue(!contains.Execute(densified, envelope, sr, null));
//				NUnit.Framework.Assert.IsTrue(!disjoint.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(touches.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(envelope, densified, sr, null));
//			}
//			{
//				com.esri.core.geometry.Polyline polyline = (com.esri.core.geometry.Polyline)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"paths\":[[[0,0],[0,5],[0,10],[10,10],[10,0]]]}").GetGeometry());
//				com.esri.core.geometry.Polyline densified = (com.esri.core.geometry.Polyline)(densify.Execute(polyline, 1.0, null));
//				com.esri.core.geometry.Envelope envelope = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":0,\"ymin\":5,\"xmax\":0,\"ymax\":5}").GetGeometry());
//				WiggleGeometry(densified, 0.00000001, 1982);
//				WiggleGeometry(envelope, 0.00000001, 511);
//				NUnit.Framework.Assert.IsTrue(!equals.Execute(envelope, densified, sr, null));
//				// degenerate
//				// envelope
//				// is at
//				// the
//				// interior
//				// of
//				// polyline
//				NUnit.Framework.Assert.IsTrue(contains.Execute(densified, envelope, sr, null));
//				NUnit.Framework.Assert.IsTrue(!disjoint.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!touches.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(envelope, densified, sr, null));
//			}
//			{
//				com.esri.core.geometry.Polyline polyline = (com.esri.core.geometry.Polyline)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"paths\":[[[2,-2],[2,2]]]}").GetGeometry());
//				com.esri.core.geometry.Polyline densified = (com.esri.core.geometry.Polyline)(densify.Execute(polyline, 1.0, null));
//				com.esri.core.geometry.Envelope envelope = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":0,\"ymin\":0,\"xmax\":5,\"ymax\":0}").GetGeometry());
//				WiggleGeometry(densified, 0.00000001, 1982);
//				WiggleGeometry(envelope, 0.00000001, 511);
//				NUnit.Framework.Assert.IsTrue(!equals.Execute(envelope, densified, sr, null));
//				// degenerate
//				// envelope
//				// crosses
//				// polyline
//				NUnit.Framework.Assert.IsTrue(!contains.Execute(densified, envelope, sr, null));
//				NUnit.Framework.Assert.IsTrue(!disjoint.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!touches.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(crosses.Execute(envelope, densified, sr, null));
//			}
//			{
//				com.esri.core.geometry.Polyline polyline = (com.esri.core.geometry.Polyline)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"paths\":[[[2,0],[2,2]]]}").GetGeometry());
//				com.esri.core.geometry.Polyline densified = (com.esri.core.geometry.Polyline)(densify.Execute(polyline, 1.0, null));
//				com.esri.core.geometry.Envelope envelope = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":0,\"ymin\":0,\"xmax\":5,\"ymax\":0}").GetGeometry());
//				WiggleGeometry(densified, 0.00000001, 1982);
//				WiggleGeometry(envelope, 0.00000001, 511);
//				NUnit.Framework.Assert.IsTrue(!equals.Execute(envelope, densified, sr, null));
//				// degenerate
//				// envelope
//				// crosses
//				// polyline
//				NUnit.Framework.Assert.IsTrue(!contains.Execute(densified, envelope, sr, null));
//				NUnit.Framework.Assert.IsTrue(!disjoint.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(touches.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(envelope, densified, sr, null));
//			}
//			{
//				com.esri.core.geometry.Polyline polyline = (com.esri.core.geometry.Polyline)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"paths\":[[[2,0],[2,2]]]}").GetGeometry());
//				com.esri.core.geometry.Polyline densified = (com.esri.core.geometry.Polyline)(densify.Execute(polyline, 1.0, null));
//				com.esri.core.geometry.Envelope envelope = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":2,\"ymin\":0,\"xmax\":2,\"ymax\":3}").GetGeometry());
//				WiggleGeometry(densified, 0.00000001, 1982);
//				WiggleGeometry(envelope, 0.00000001, 511);
//				NUnit.Framework.Assert.IsTrue(!equals.Execute(envelope, densified, sr, null));
//				// degenerate
//				// envelope
//				// contains
//				// polyline
//				NUnit.Framework.Assert.IsTrue(!contains.Execute(densified, envelope, sr, null));
//				NUnit.Framework.Assert.IsTrue(contains.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!disjoint.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!touches.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(envelope, densified, sr, null));
//			}
//			{
//				com.esri.core.geometry.Polyline polyline = (com.esri.core.geometry.Polyline)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"paths\":[[[5,5],[6,6]]]}").GetGeometry());
//				com.esri.core.geometry.Polyline densified = (com.esri.core.geometry.Polyline)(densify.Execute(polyline, 1.0, null));
//				com.esri.core.geometry.Envelope envelope = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":0,\"ymin\":0,\"xmax\":5,\"ymax\":5}").GetGeometry());
//				WiggleGeometry(densified, 0.00000001, 1982);
//				WiggleGeometry(envelope, 0.00000001, 511);
//				NUnit.Framework.Assert.IsTrue(!equals.Execute(envelope, densified, sr, null));
//				// polyline
//				// properly
//				// inside
//				NUnit.Framework.Assert.IsTrue(!contains.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!disjoint.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(touches.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(envelope, densified, sr, null));
//			}
//			{
//				com.esri.core.geometry.Polyline polyline = (com.esri.core.geometry.Polyline)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"paths\":[[[5,5],[5,10]]]}").GetGeometry());
//				com.esri.core.geometry.Polyline densified = (com.esri.core.geometry.Polyline)(densify.Execute(polyline, 1.0, null));
//				com.esri.core.geometry.Envelope envelope = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":5,\"ymin\":5,\"xmax\":5,\"ymax\":10}").GetGeometry());
//				WiggleGeometry(densified, 0.00000001, 1982);
//				WiggleGeometry(envelope, 0.00000001, 511);
//				NUnit.Framework.Assert.IsTrue(equals.Execute(envelope, densified, sr, null));
//				// polyline
//				// properly
//				// inside
//				NUnit.Framework.Assert.IsTrue(contains.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!disjoint.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!touches.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(envelope, densified, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(envelope, densified, sr, null));
//			}
//		}
//
//		[NUnit.Framework.Test]
//		public virtual void TestMultiPointEnvelope()
//		{
//			com.esri.core.geometry.OperatorEquals equals = (com.esri.core.geometry.OperatorEquals)(com.esri.core.geometry.OperatorFactoryLocal.GetInstance().GetOperator(com.esri.core.geometry.Operator.Type.Equals));
//			com.esri.core.geometry.OperatorContains contains = (com.esri.core.geometry.OperatorContains)(com.esri.core.geometry.OperatorFactoryLocal.GetInstance().GetOperator(com.esri.core.geometry.Operator.Type.Contains));
//			com.esri.core.geometry.OperatorDisjoint disjoint = (com.esri.core.geometry.OperatorDisjoint)(com.esri.core.geometry.OperatorFactoryLocal.GetInstance().GetOperator(com.esri.core.geometry.Operator.Type.Disjoint));
//			com.esri.core.geometry.OperatorCrosses crosses = (com.esri.core.geometry.OperatorCrosses)(com.esri.core.geometry.OperatorFactoryLocal.GetInstance().GetOperator(com.esri.core.geometry.Operator.Type.Crosses));
//			com.esri.core.geometry.OperatorWithin within = (com.esri.core.geometry.OperatorWithin)(com.esri.core.geometry.OperatorFactoryLocal.GetInstance().GetOperator(com.esri.core.geometry.Operator.Type.Within));
//			com.esri.core.geometry.OperatorOverlaps overlaps = (com.esri.core.geometry.OperatorOverlaps)(com.esri.core.geometry.OperatorFactoryLocal.GetInstance().GetOperator(com.esri.core.geometry.Operator.Type.Overlaps));
//			com.esri.core.geometry.OperatorTouches touches = (com.esri.core.geometry.OperatorTouches)(com.esri.core.geometry.OperatorFactoryLocal.GetInstance().GetOperator(com.esri.core.geometry.Operator.Type.Touches));
//			com.esri.core.geometry.OperatorDensifyByLength densify = (com.esri.core.geometry.OperatorDensifyByLength)(com.esri.core.geometry.OperatorFactoryLocal.GetInstance().GetOperator(com.esri.core.geometry.Operator.Type.DensifyByLength));
//			com.esri.core.geometry.SpatialReference sr = com.esri.core.geometry.SpatialReference.Create(4326);
//			{
//				com.esri.core.geometry.MultiPoint multi_point = (com.esri.core.geometry.MultiPoint)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"points\":[[0,0],[0,10],[10,10],[10,0]]}").GetGeometry());
//				com.esri.core.geometry.Envelope envelope = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":0,\"ymin\":0,\"xmax\":10,\"ymax\":10}").GetGeometry());
//				WiggleGeometry(multi_point, 0.00000001, 1982);
//				WiggleGeometry(envelope, 0.00000001, 511);
//				NUnit.Framework.Assert.IsTrue(!equals.Execute(envelope, multi_point, sr, null));
//				// all
//				// points
//				// on
//				// boundary
//				NUnit.Framework.Assert.IsTrue(!contains.Execute(envelope, multi_point, sr, null));
//				NUnit.Framework.Assert.IsTrue(!disjoint.Execute(envelope, multi_point, sr, null));
//				NUnit.Framework.Assert.IsTrue(touches.Execute(envelope, multi_point, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(envelope, multi_point, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(envelope, multi_point, sr, null));
//			}
//			{
//				com.esri.core.geometry.MultiPoint multi_point = (com.esri.core.geometry.MultiPoint)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"points\":[[0,0],[0,10],[10,10],[5,5]]}").GetGeometry());
//				com.esri.core.geometry.Envelope envelope = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":0,\"ymin\":0,\"xmax\":10,\"ymax\":10}").GetGeometry());
//				WiggleGeometry(multi_point, 0.00000001, 1982);
//				WiggleGeometry(envelope, 0.00000001, 511);
//				NUnit.Framework.Assert.IsTrue(!equals.Execute(envelope, multi_point, sr, null));
//				// points
//				// on
//				// boundary
//				// and
//				// one
//				// point
//				// in
//				// interior
//				NUnit.Framework.Assert.IsTrue(contains.Execute(envelope, multi_point, sr, null));
//				NUnit.Framework.Assert.IsTrue(!disjoint.Execute(envelope, multi_point, sr, null));
//				NUnit.Framework.Assert.IsTrue(!touches.Execute(envelope, multi_point, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(envelope, multi_point, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(envelope, multi_point, sr, null));
//			}
//			{
//				com.esri.core.geometry.MultiPoint multi_point = (com.esri.core.geometry.MultiPoint)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"points\":[[0,0],[0,10],[10,10],[5,5],[15,15]]}").GetGeometry());
//				com.esri.core.geometry.Envelope envelope = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":0,\"ymin\":0,\"xmax\":10,\"ymax\":10}").GetGeometry());
//				WiggleGeometry(multi_point, 0.00000001, 1982);
//				WiggleGeometry(envelope, 0.00000001, 511);
//				NUnit.Framework.Assert.IsTrue(!equals.Execute(envelope, multi_point, sr, null));
//				// points
//				// on
//				// boundary,
//				// one
//				// interior,
//				// one
//				// exterior
//				NUnit.Framework.Assert.IsTrue(!contains.Execute(envelope, multi_point, sr, null));
//				NUnit.Framework.Assert.IsTrue(!disjoint.Execute(envelope, multi_point, sr, null));
//				NUnit.Framework.Assert.IsTrue(!touches.Execute(envelope, multi_point, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(envelope, multi_point, sr, null));
//				NUnit.Framework.Assert.IsTrue(crosses.Execute(envelope, multi_point, sr, null));
//			}
//			{
//				com.esri.core.geometry.MultiPoint multi_point = (com.esri.core.geometry.MultiPoint)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"points\":[[0,0],[0,10],[10,10],[15,15]]}").GetGeometry());
//				com.esri.core.geometry.Envelope envelope = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":0,\"ymin\":0,\"xmax\":10,\"ymax\":10}").GetGeometry());
//				WiggleGeometry(multi_point, 0.00000001, 1982);
//				WiggleGeometry(envelope, 0.00000001, 511);
//				NUnit.Framework.Assert.IsTrue(!equals.Execute(envelope, multi_point, sr, null));
//				// points
//				// on
//				// boundary,
//				// one
//				// exterior
//				NUnit.Framework.Assert.IsTrue(!contains.Execute(envelope, multi_point, sr, null));
//				NUnit.Framework.Assert.IsTrue(!disjoint.Execute(envelope, multi_point, sr, null));
//				NUnit.Framework.Assert.IsTrue(touches.Execute(envelope, multi_point, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(envelope, multi_point, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(envelope, multi_point, sr, null));
//			}
//			{
//				com.esri.core.geometry.MultiPoint multi_point = (com.esri.core.geometry.MultiPoint)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"points\":[[0,-1],[0,11],[11,11],[15,15]]}").GetGeometry());
//				com.esri.core.geometry.Envelope envelope = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":0,\"ymin\":0,\"xmax\":10,\"ymax\":10}").GetGeometry());
//				WiggleGeometry(multi_point, 0.00000001, 1982);
//				WiggleGeometry(envelope, 0.00000001, 511);
//				NUnit.Framework.Assert.IsTrue(!equals.Execute(envelope, multi_point, sr, null));
//				// all
//				// points
//				// exterior
//				NUnit.Framework.Assert.IsTrue(!contains.Execute(envelope, multi_point, sr, null));
//				NUnit.Framework.Assert.IsTrue(disjoint.Execute(envelope, multi_point, sr, null));
//				NUnit.Framework.Assert.IsTrue(!touches.Execute(envelope, multi_point, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(envelope, multi_point, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(envelope, multi_point, sr, null));
//			}
//			{
//				com.esri.core.geometry.MultiPoint multi_point = (com.esri.core.geometry.MultiPoint)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"points\":[[0,0],[0,10],[10,10],[10,0]]}").GetGeometry());
//				com.esri.core.geometry.Envelope envelope = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":0,\"ymin\":10,\"xmax\":10,\"ymax\":10}").GetGeometry());
//				WiggleGeometry(multi_point, 0.00000001, 1982);
//				WiggleGeometry(envelope, 0.00000001, 511);
//				NUnit.Framework.Assert.IsTrue(!equals.Execute(envelope, multi_point, sr, null));
//				// degenerate
//				// envelope
//				// slices
//				// through
//				// some
//				// points,
//				// but
//				// some
//				// points
//				// are
//				// off
//				// the
//				// line
//				NUnit.Framework.Assert.IsTrue(!contains.Execute(envelope, multi_point, sr, null));
//				NUnit.Framework.Assert.IsTrue(!disjoint.Execute(envelope, multi_point, sr, null));
//				NUnit.Framework.Assert.IsTrue(touches.Execute(envelope, multi_point, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(envelope, multi_point, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(envelope, multi_point, sr, null));
//			}
//			{
//				com.esri.core.geometry.MultiPoint multi_point = (com.esri.core.geometry.MultiPoint)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"points\":[[0,0],[1,10],[10,10],[10,0]]}").GetGeometry());
//				com.esri.core.geometry.Envelope envelope = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":0,\"ymin\":10,\"xmax\":10,\"ymax\":10}").GetGeometry());
//				WiggleGeometry(multi_point, 0.00000001, 1982);
//				WiggleGeometry(envelope, 0.00000001, 511);
//				NUnit.Framework.Assert.IsTrue(!equals.Execute(envelope, multi_point, sr, null));
//				// degenerate
//				// envelope
//				// slices
//				// through
//				// some
//				// points,
//				// but
//				// some
//				// points
//				// are
//				// off
//				// the
//				// line
//				NUnit.Framework.Assert.IsTrue(!contains.Execute(envelope, multi_point, sr, null));
//				NUnit.Framework.Assert.IsTrue(!disjoint.Execute(envelope, multi_point, sr, null));
//				NUnit.Framework.Assert.IsTrue(!touches.Execute(envelope, multi_point, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(envelope, multi_point, sr, null));
//				NUnit.Framework.Assert.IsTrue(crosses.Execute(envelope, multi_point, sr, null));
//			}
//			{
//				com.esri.core.geometry.MultiPoint multi_point = (com.esri.core.geometry.MultiPoint)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"points\":[[0,10],[10,10]]}").GetGeometry());
//				com.esri.core.geometry.Envelope envelope = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":0,\"ymin\":10,\"xmax\":10,\"ymax\":10}").GetGeometry());
//				WiggleGeometry(multi_point, 0.00000001, 1982);
//				WiggleGeometry(envelope, 0.00000001, 511);
//				NUnit.Framework.Assert.IsTrue(!equals.Execute(envelope, multi_point, sr, null));
//				// degenerate
//				// envelopes
//				// slices
//				// through
//				// all
//				// the
//				// points,
//				// and
//				// they
//				// are
//				// at
//				// the
//				// end
//				// points
//				// of
//				// the
//				// line
//				NUnit.Framework.Assert.IsTrue(!contains.Execute(envelope, multi_point, sr, null));
//				NUnit.Framework.Assert.IsTrue(!disjoint.Execute(envelope, multi_point, sr, null));
//				NUnit.Framework.Assert.IsTrue(touches.Execute(envelope, multi_point, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(envelope, multi_point, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(envelope, multi_point, sr, null));
//			}
//			{
//				com.esri.core.geometry.MultiPoint multi_point = (com.esri.core.geometry.MultiPoint)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"points\":[[1,10],[9,10]]}").GetGeometry());
//				com.esri.core.geometry.Envelope envelope = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":0,\"ymin\":10,\"xmax\":10,\"ymax\":10}").GetGeometry());
//				WiggleGeometry(multi_point, 0.00000001, 1982);
//				WiggleGeometry(envelope, 0.00000001, 511);
//				NUnit.Framework.Assert.IsTrue(!equals.Execute(envelope, multi_point, sr, null));
//				// degenerate
//				// envelopes
//				// slices
//				// through
//				// all
//				// the
//				// points,
//				// and
//				// they
//				// are
//				// in
//				// the
//				// interior
//				// of
//				// the
//				// line
//				NUnit.Framework.Assert.IsTrue(contains.Execute(envelope, multi_point, sr, null));
//				NUnit.Framework.Assert.IsTrue(!disjoint.Execute(envelope, multi_point, sr, null));
//				NUnit.Framework.Assert.IsTrue(!touches.Execute(envelope, multi_point, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(envelope, multi_point, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(envelope, multi_point, sr, null));
//			}
//			{
//				com.esri.core.geometry.MultiPoint multi_point = (com.esri.core.geometry.MultiPoint)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"points\":[[0,-1],[0,11],[11,11],[15,15]]}").GetGeometry());
//				com.esri.core.geometry.Envelope envelope = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":0,\"ymin\":10,\"xmax\":10,\"ymax\":10}").GetGeometry());
//				WiggleGeometry(multi_point, 0.00000001, 1982);
//				WiggleGeometry(envelope, 0.00000001, 511);
//				NUnit.Framework.Assert.IsTrue(!equals.Execute(envelope, multi_point, sr, null));
//				// all
//				// points
//				// exterior
//				NUnit.Framework.Assert.IsTrue(!contains.Execute(envelope, multi_point, sr, null));
//				NUnit.Framework.Assert.IsTrue(disjoint.Execute(envelope, multi_point, sr, null));
//				NUnit.Framework.Assert.IsTrue(!touches.Execute(envelope, multi_point, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(envelope, multi_point, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(envelope, multi_point, sr, null));
//			}
//			{
//				com.esri.core.geometry.MultiPoint multi_point = (com.esri.core.geometry.MultiPoint)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"points\":[[0,-1],[0,11],[11,11],[15,15]]}").GetGeometry());
//				com.esri.core.geometry.Envelope envelope = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":10,\"ymin\":10,\"xmax\":10,\"ymax\":10}").GetGeometry());
//				WiggleGeometry(multi_point, 0.00000001, 1982);
//				WiggleGeometry(envelope, 0.00000001, 511);
//				NUnit.Framework.Assert.IsTrue(!equals.Execute(envelope, multi_point, sr, null));
//				// all
//				// points
//				// exterior
//				NUnit.Framework.Assert.IsTrue(!contains.Execute(envelope, multi_point, sr, null));
//				NUnit.Framework.Assert.IsTrue(disjoint.Execute(envelope, multi_point, sr, null));
//				NUnit.Framework.Assert.IsTrue(!touches.Execute(envelope, multi_point, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(envelope, multi_point, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(envelope, multi_point, sr, null));
//			}
//			{
//				com.esri.core.geometry.MultiPoint multi_point = (com.esri.core.geometry.MultiPoint)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"points\":[[0,-1],[0,11],[11,11],[15,15]]}").GetGeometry());
//				com.esri.core.geometry.Envelope envelope = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":0,\"ymin\":0,\"xmax\":11,\"ymax\":11}").GetGeometry());
//				WiggleGeometry(multi_point, 0.00000001, 1982);
//				WiggleGeometry(envelope, 0.00000001, 511);
//				NUnit.Framework.Assert.IsTrue(!equals.Execute(envelope, multi_point, sr, null));
//				// all
//				// points
//				// exterior
//				NUnit.Framework.Assert.IsTrue(!contains.Execute(multi_point, envelope, sr, null));
//				NUnit.Framework.Assert.IsTrue(!contains.Execute(envelope, multi_point, sr, null));
//				NUnit.Framework.Assert.IsTrue(!disjoint.Execute(envelope, multi_point, sr, null));
//				NUnit.Framework.Assert.IsTrue(touches.Execute(envelope, multi_point, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(envelope, multi_point, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(envelope, multi_point, sr, null));
//			}
//			{
//				com.esri.core.geometry.MultiPoint multi_point = (com.esri.core.geometry.MultiPoint)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"points\":[[0,-1],[0,-1]]}").GetGeometry());
//				com.esri.core.geometry.Envelope envelope = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":0,\"ymin\":-1,\"xmax\":0,\"ymax\":-1}").GetGeometry());
//				WiggleGeometry(multi_point, 0.00000001, 1982);
//				WiggleGeometry(envelope, 0.00000001, 511);
//				NUnit.Framework.Assert.IsTrue(equals.Execute(envelope, multi_point, sr, null));
//				// all
//				// points
//				// exterior
//				NUnit.Framework.Assert.IsTrue(contains.Execute(multi_point, envelope, sr, null));
//				NUnit.Framework.Assert.IsTrue(contains.Execute(envelope, multi_point, sr, null));
//				NUnit.Framework.Assert.IsTrue(!disjoint.Execute(envelope, multi_point, sr, null));
//				NUnit.Framework.Assert.IsTrue(!touches.Execute(envelope, multi_point, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(envelope, multi_point, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(envelope, multi_point, sr, null));
//			}
//		}
//
//		[NUnit.Framework.Test]
//		public virtual void TestPointEnvelope()
//		{
//			com.esri.core.geometry.OperatorEquals equals = (com.esri.core.geometry.OperatorEquals)(com.esri.core.geometry.OperatorFactoryLocal.GetInstance().GetOperator(com.esri.core.geometry.Operator.Type.Equals));
//			com.esri.core.geometry.OperatorContains contains = (com.esri.core.geometry.OperatorContains)(com.esri.core.geometry.OperatorFactoryLocal.GetInstance().GetOperator(com.esri.core.geometry.Operator.Type.Contains));
//			com.esri.core.geometry.OperatorDisjoint disjoint = (com.esri.core.geometry.OperatorDisjoint)(com.esri.core.geometry.OperatorFactoryLocal.GetInstance().GetOperator(com.esri.core.geometry.Operator.Type.Disjoint));
//			com.esri.core.geometry.OperatorCrosses crosses = (com.esri.core.geometry.OperatorCrosses)(com.esri.core.geometry.OperatorFactoryLocal.GetInstance().GetOperator(com.esri.core.geometry.Operator.Type.Crosses));
//			com.esri.core.geometry.OperatorWithin within = (com.esri.core.geometry.OperatorWithin)(com.esri.core.geometry.OperatorFactoryLocal.GetInstance().GetOperator(com.esri.core.geometry.Operator.Type.Within));
//			com.esri.core.geometry.OperatorOverlaps overlaps = (com.esri.core.geometry.OperatorOverlaps)(com.esri.core.geometry.OperatorFactoryLocal.GetInstance().GetOperator(com.esri.core.geometry.Operator.Type.Overlaps));
//			com.esri.core.geometry.OperatorTouches touches = (com.esri.core.geometry.OperatorTouches)(com.esri.core.geometry.OperatorFactoryLocal.GetInstance().GetOperator(com.esri.core.geometry.Operator.Type.Touches));
//			com.esri.core.geometry.SpatialReference sr = com.esri.core.geometry.SpatialReference.Create(4326);
//			{
//				com.esri.core.geometry.Point point = (com.esri.core.geometry.Point)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"x\":5,\"y\":6}").GetGeometry());
//				com.esri.core.geometry.Envelope envelope = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":0,\"ymin\":0,\"xmax\":10,\"ymax\":10}").GetGeometry());
//				WiggleGeometry(point, 0.00000001, 1982);
//				WiggleGeometry(envelope, 0.00000001, 511);
//				NUnit.Framework.Assert.IsTrue(!equals.Execute(envelope, point, sr, null));
//				NUnit.Framework.Assert.IsTrue(contains.Execute(envelope, point, sr, null));
//				NUnit.Framework.Assert.IsTrue(!contains.Execute(point, envelope, sr, null));
//				NUnit.Framework.Assert.IsTrue(!disjoint.Execute(envelope, point, sr, null));
//				NUnit.Framework.Assert.IsTrue(!touches.Execute(envelope, point, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(envelope, point, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(envelope, point, sr, null));
//			}
//			{
//				com.esri.core.geometry.Point point = (com.esri.core.geometry.Point)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"x\":0,\"y\":10}").GetGeometry());
//				com.esri.core.geometry.Envelope envelope = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":0,\"ymin\":0,\"xmax\":10,\"ymax\":10}").GetGeometry());
//				WiggleGeometry(point, 0.00000001, 1982);
//				WiggleGeometry(envelope, 0.00000001, 511);
//				NUnit.Framework.Assert.IsTrue(!equals.Execute(envelope, point, sr, null));
//				NUnit.Framework.Assert.IsTrue(!contains.Execute(envelope, point, sr, null));
//				NUnit.Framework.Assert.IsTrue(!contains.Execute(point, envelope, sr, null));
//				NUnit.Framework.Assert.IsTrue(!disjoint.Execute(envelope, point, sr, null));
//				NUnit.Framework.Assert.IsTrue(touches.Execute(envelope, point, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(envelope, point, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(envelope, point, sr, null));
//			}
//			{
//				com.esri.core.geometry.Point point = (com.esri.core.geometry.Point)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"x\":0,\"y\":11}").GetGeometry());
//				com.esri.core.geometry.Envelope envelope = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":0,\"ymin\":0,\"xmax\":10,\"ymax\":10}").GetGeometry());
//				WiggleGeometry(point, 0.00000001, 1982);
//				WiggleGeometry(envelope, 0.00000001, 511);
//				NUnit.Framework.Assert.IsTrue(!equals.Execute(envelope, point, sr, null));
//				NUnit.Framework.Assert.IsTrue(!contains.Execute(envelope, point, sr, null));
//				NUnit.Framework.Assert.IsTrue(!contains.Execute(point, envelope, sr, null));
//				NUnit.Framework.Assert.IsTrue(disjoint.Execute(envelope, point, sr, null));
//				NUnit.Framework.Assert.IsTrue(!touches.Execute(envelope, point, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(envelope, point, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(envelope, point, sr, null));
//			}
//			{
//				com.esri.core.geometry.Point point = (com.esri.core.geometry.Point)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"x\":0,\"y\":0}").GetGeometry());
//				com.esri.core.geometry.Envelope envelope = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":0,\"ymin\":0,\"xmax\":10,\"ymax\":0}").GetGeometry());
//				WiggleGeometry(point, 0.00000001, 1982);
//				WiggleGeometry(envelope, 0.00000001, 511);
//				NUnit.Framework.Assert.IsTrue(!equals.Execute(envelope, point, sr, null));
//				NUnit.Framework.Assert.IsTrue(!contains.Execute(envelope, point, sr, null));
//				NUnit.Framework.Assert.IsTrue(!contains.Execute(point, envelope, sr, null));
//				NUnit.Framework.Assert.IsTrue(!disjoint.Execute(envelope, point, sr, null));
//				NUnit.Framework.Assert.IsTrue(touches.Execute(envelope, point, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(envelope, point, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(envelope, point, sr, null));
//			}
//			{
//				com.esri.core.geometry.Point point = (com.esri.core.geometry.Point)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"x\":5,\"y\":0}").GetGeometry());
//				com.esri.core.geometry.Envelope envelope = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":0,\"ymin\":0,\"xmax\":10,\"ymax\":0}").GetGeometry());
//				WiggleGeometry(point, 0.00000001, 1982);
//				WiggleGeometry(envelope, 0.00000001, 511);
//				NUnit.Framework.Assert.IsTrue(!equals.Execute(envelope, point, sr, null));
//				NUnit.Framework.Assert.IsTrue(contains.Execute(envelope, point, sr, null));
//				NUnit.Framework.Assert.IsTrue(!contains.Execute(point, envelope, sr, null));
//				NUnit.Framework.Assert.IsTrue(!disjoint.Execute(envelope, point, sr, null));
//				NUnit.Framework.Assert.IsTrue(!touches.Execute(envelope, point, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(envelope, point, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(envelope, point, sr, null));
//			}
//			{
//				com.esri.core.geometry.Point point = (com.esri.core.geometry.Point)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"x\":11,\"y\":0}").GetGeometry());
//				com.esri.core.geometry.Envelope envelope = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":0,\"ymin\":0,\"xmax\":10,\"ymax\":0}").GetGeometry());
//				WiggleGeometry(point, 0.00000001, 1982);
//				WiggleGeometry(envelope, 0.00000001, 511);
//				NUnit.Framework.Assert.IsTrue(!equals.Execute(envelope, point, sr, null));
//				NUnit.Framework.Assert.IsTrue(!contains.Execute(envelope, point, sr, null));
//				NUnit.Framework.Assert.IsTrue(!contains.Execute(point, envelope, sr, null));
//				NUnit.Framework.Assert.IsTrue(disjoint.Execute(envelope, point, sr, null));
//				NUnit.Framework.Assert.IsTrue(!touches.Execute(envelope, point, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(envelope, point, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(envelope, point, sr, null));
//			}
//			{
//				com.esri.core.geometry.Point point = (com.esri.core.geometry.Point)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"x\":0,\"y\":0}").GetGeometry());
//				com.esri.core.geometry.Envelope envelope = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":0,\"ymin\":0,\"xmax\":0,\"ymax\":0}").GetGeometry());
//				WiggleGeometry(point, 0.00000001, 1982);
//				WiggleGeometry(envelope, 0.00000001, 511);
//				NUnit.Framework.Assert.IsTrue(equals.Execute(envelope, point, sr, null));
//				NUnit.Framework.Assert.IsTrue(contains.Execute(envelope, point, sr, null));
//				NUnit.Framework.Assert.IsTrue(contains.Execute(point, envelope, sr, null));
//				NUnit.Framework.Assert.IsTrue(!disjoint.Execute(envelope, point, sr, null));
//				NUnit.Framework.Assert.IsTrue(!touches.Execute(envelope, point, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(envelope, point, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(envelope, point, sr, null));
//			}
//		}
//
//		[NUnit.Framework.Test]
//		public virtual void TestEnvelopeEnvelope()
//		{
//			com.esri.core.geometry.OperatorEquals equals = (com.esri.core.geometry.OperatorEquals)(com.esri.core.geometry.OperatorFactoryLocal.GetInstance().GetOperator(com.esri.core.geometry.Operator.Type.Equals));
//			com.esri.core.geometry.OperatorContains contains = (com.esri.core.geometry.OperatorContains)(com.esri.core.geometry.OperatorFactoryLocal.GetInstance().GetOperator(com.esri.core.geometry.Operator.Type.Contains));
//			com.esri.core.geometry.OperatorDisjoint disjoint = (com.esri.core.geometry.OperatorDisjoint)(com.esri.core.geometry.OperatorFactoryLocal.GetInstance().GetOperator(com.esri.core.geometry.Operator.Type.Disjoint));
//			com.esri.core.geometry.OperatorCrosses crosses = (com.esri.core.geometry.OperatorCrosses)(com.esri.core.geometry.OperatorFactoryLocal.GetInstance().GetOperator(com.esri.core.geometry.Operator.Type.Crosses));
//			com.esri.core.geometry.OperatorWithin within = (com.esri.core.geometry.OperatorWithin)(com.esri.core.geometry.OperatorFactoryLocal.GetInstance().GetOperator(com.esri.core.geometry.Operator.Type.Within));
//			com.esri.core.geometry.OperatorOverlaps overlaps = (com.esri.core.geometry.OperatorOverlaps)(com.esri.core.geometry.OperatorFactoryLocal.GetInstance().GetOperator(com.esri.core.geometry.Operator.Type.Overlaps));
//			com.esri.core.geometry.OperatorTouches touches = (com.esri.core.geometry.OperatorTouches)(com.esri.core.geometry.OperatorFactoryLocal.GetInstance().GetOperator(com.esri.core.geometry.Operator.Type.Touches));
//			com.esri.core.geometry.SpatialReference sr = com.esri.core.geometry.SpatialReference.Create(4326);
//			{
//				com.esri.core.geometry.Envelope env1 = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":0,\"ymin\":0,\"xmax\":10,\"ymax\":10}").GetGeometry());
//				com.esri.core.geometry.Envelope env2 = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":0,\"ymin\":0,\"xmax\":10,\"ymax\":10}").GetGeometry());
//				WiggleGeometry(env1, 0.00000001, 1982);
//				WiggleGeometry(env2, 0.00000001, 511);
//				NUnit.Framework.Assert.IsTrue(equals.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(contains.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(contains.Execute(env2, env1, sr, null));
//				NUnit.Framework.Assert.IsTrue(!disjoint.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!touches.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!touches.Execute(env2, env1, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(env2, env1, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(env2, env1, sr, null));
//			}
//			{
//				com.esri.core.geometry.Envelope env1 = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":5,\"ymin\":5,\"xmax\":10,\"ymax\":10}").GetGeometry());
//				com.esri.core.geometry.Envelope env2 = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":0,\"ymin\":0,\"xmax\":10,\"ymax\":10}").GetGeometry());
//				WiggleGeometry(env1, 0.00000001, 1982);
//				WiggleGeometry(env2, 0.00000001, 511);
//				NUnit.Framework.Assert.IsTrue(!equals.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!contains.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(contains.Execute(env2, env1, sr, null));
//				NUnit.Framework.Assert.IsTrue(!disjoint.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!touches.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(env2, env1, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(env2, env1, sr, null));
//			}
//			{
//				com.esri.core.geometry.Envelope env1 = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":5,\"ymin\":5,\"xmax\":15,\"ymax\":15}").GetGeometry());
//				com.esri.core.geometry.Envelope env2 = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":0,\"ymin\":0,\"xmax\":10,\"ymax\":10}").GetGeometry());
//				WiggleGeometry(env1, 0.00000001, 1982);
//				WiggleGeometry(env2, 0.00000001, 511);
//				NUnit.Framework.Assert.IsTrue(!equals.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!contains.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!contains.Execute(env2, env1, sr, null));
//				NUnit.Framework.Assert.IsTrue(!disjoint.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!touches.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(overlaps.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(overlaps.Execute(env2, env1, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(env2, env1, sr, null));
//			}
//			{
//				com.esri.core.geometry.Envelope env1 = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":10,\"ymin\":0,\"xmax\":20,\"ymax\":10}").GetGeometry());
//				com.esri.core.geometry.Envelope env2 = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":0,\"ymin\":0,\"xmax\":10,\"ymax\":10}").GetGeometry());
//				WiggleGeometry(env1, 0.00000001, 1982);
//				WiggleGeometry(env2, 0.00000001, 511);
//				NUnit.Framework.Assert.IsTrue(!equals.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!contains.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!contains.Execute(env2, env1, sr, null));
//				NUnit.Framework.Assert.IsTrue(!disjoint.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(touches.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(env2, env1, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(env2, env1, sr, null));
//			}
//			{
//				com.esri.core.geometry.Envelope env1 = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":10,\"ymin\":0,\"xmax\":20,\"ymax\":10}").GetGeometry());
//				com.esri.core.geometry.Envelope env2 = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":0,\"ymin\":0,\"xmax\":10,\"ymax\":10}").GetGeometry());
//				WiggleGeometry(env1, 0.00000001, 1982);
//				WiggleGeometry(env2, 0.00000001, 511);
//				NUnit.Framework.Assert.IsTrue(!equals.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!contains.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!contains.Execute(env2, env1, sr, null));
//				NUnit.Framework.Assert.IsTrue(!disjoint.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(touches.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(env2, env1, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(env2, env1, sr, null));
//			}
//			{
//				com.esri.core.geometry.Envelope env1 = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":10,\"ymin\":0,\"xmax\":20,\"ymax\":10}").GetGeometry());
//				com.esri.core.geometry.Envelope env2 = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":0,\"ymin\":10,\"xmax\":10,\"ymax\":20}").GetGeometry());
//				WiggleGeometry(env1, 0.00000001, 1982);
//				WiggleGeometry(env2, 0.00000001, 511);
//				NUnit.Framework.Assert.IsTrue(!equals.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!contains.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!contains.Execute(env2, env1, sr, null));
//				NUnit.Framework.Assert.IsTrue(!disjoint.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(touches.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(env2, env1, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(env2, env1, sr, null));
//			}
//			{
//				com.esri.core.geometry.Envelope env1 = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":0,\"ymin\":0,\"xmax\":10,\"ymax\":10}").GetGeometry());
//				com.esri.core.geometry.Envelope env2 = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":0,\"ymin\":0,\"xmax\":10,\"ymax\":0}").GetGeometry());
//				WiggleGeometry(env1, 0.00000001, 1982);
//				WiggleGeometry(env2, 0.00000001, 511);
//				NUnit.Framework.Assert.IsTrue(!equals.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!contains.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!contains.Execute(env2, env1, sr, null));
//				NUnit.Framework.Assert.IsTrue(!disjoint.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(touches.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(env2, env1, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(env2, env1, sr, null));
//			}
//			{
//				com.esri.core.geometry.Envelope env1 = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":0,\"ymin\":0,\"xmax\":10,\"ymax\":10}").GetGeometry());
//				com.esri.core.geometry.Envelope env2 = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":0,\"ymin\":0,\"xmax\":15,\"ymax\":0}").GetGeometry());
//				WiggleGeometry(env1, 0.00000001, 1982);
//				WiggleGeometry(env2, 0.00000001, 511);
//				NUnit.Framework.Assert.IsTrue(!equals.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!contains.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!contains.Execute(env2, env1, sr, null));
//				NUnit.Framework.Assert.IsTrue(!disjoint.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(touches.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(env2, env1, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(env2, env1, sr, null));
//			}
//			{
//				com.esri.core.geometry.Envelope env1 = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":0,\"ymin\":0,\"xmax\":10,\"ymax\":10}").GetGeometry());
//				com.esri.core.geometry.Envelope env2 = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":-5,\"ymin\":5,\"xmax\":0,\"ymax\":5}").GetGeometry());
//				WiggleGeometry(env1, 0.00000001, 1982);
//				WiggleGeometry(env2, 0.00000001, 511);
//				NUnit.Framework.Assert.IsTrue(!equals.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!contains.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!contains.Execute(env2, env1, sr, null));
//				NUnit.Framework.Assert.IsTrue(!disjoint.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(touches.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(env2, env1, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(env2, env1, sr, null));
//			}
//			{
//				com.esri.core.geometry.Envelope env1 = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":0,\"ymin\":0,\"xmax\":10,\"ymax\":10}").GetGeometry());
//				com.esri.core.geometry.Envelope env2 = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":-5,\"ymin\":5,\"xmax\":5,\"ymax\":5}").GetGeometry());
//				WiggleGeometry(env1, 0.00000001, 1982);
//				WiggleGeometry(env2, 0.00000001, 511);
//				NUnit.Framework.Assert.IsTrue(!equals.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!contains.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!contains.Execute(env2, env1, sr, null));
//				NUnit.Framework.Assert.IsTrue(!disjoint.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!touches.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(env2, env1, sr, null));
//				NUnit.Framework.Assert.IsTrue(crosses.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(crosses.Execute(env2, env1, sr, null));
//			}
//			{
//				com.esri.core.geometry.Envelope env1 = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":0,\"ymin\":0,\"xmax\":10,\"ymax\":10}").GetGeometry());
//				com.esri.core.geometry.Envelope env2 = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":3,\"ymin\":5,\"xmax\":5,\"ymax\":5}").GetGeometry());
//				WiggleGeometry(env1, 0.00000001, 1982);
//				WiggleGeometry(env2, 0.00000001, 511);
//				NUnit.Framework.Assert.IsTrue(!equals.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(contains.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!contains.Execute(env2, env1, sr, null));
//				NUnit.Framework.Assert.IsTrue(!disjoint.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!touches.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(env2, env1, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(env2, env1, sr, null));
//			}
//			{
//				com.esri.core.geometry.Envelope env1 = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":0,\"ymin\":0,\"xmax\":10,\"ymax\":10}").GetGeometry());
//				com.esri.core.geometry.Envelope env2 = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":3,\"ymin\":5,\"xmax\":10,\"ymax\":5}").GetGeometry());
//				WiggleGeometry(env1, 0.00000001, 1982);
//				WiggleGeometry(env2, 0.00000001, 511);
//				NUnit.Framework.Assert.IsTrue(!equals.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(contains.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!contains.Execute(env2, env1, sr, null));
//				NUnit.Framework.Assert.IsTrue(!disjoint.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!touches.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(env2, env1, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(env2, env1, sr, null));
//			}
//			{
//				com.esri.core.geometry.Envelope env1 = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":0,\"ymin\":0,\"xmax\":10,\"ymax\":10}").GetGeometry());
//				com.esri.core.geometry.Envelope env2 = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":-5,\"ymin\":0,\"xmax\":0,\"ymax\":0}").GetGeometry());
//				WiggleGeometry(env1, 0.00000001, 1982);
//				WiggleGeometry(env2, 0.00000001, 511);
//				NUnit.Framework.Assert.IsTrue(!equals.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!contains.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!contains.Execute(env2, env1, sr, null));
//				NUnit.Framework.Assert.IsTrue(!disjoint.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(touches.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(env2, env1, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(env2, env1, sr, null));
//			}
//			{
//				com.esri.core.geometry.Envelope env1 = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":0,\"ymin\":0,\"xmax\":10,\"ymax\":0}").GetGeometry());
//				com.esri.core.geometry.Envelope env2 = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":0,\"ymin\":0,\"xmax\":10,\"ymax\":0}").GetGeometry());
//				WiggleGeometry(env1, 0.00000001, 1982);
//				WiggleGeometry(env2, 0.00000001, 511);
//				NUnit.Framework.Assert.IsTrue(equals.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(contains.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(contains.Execute(env2, env1, sr, null));
//				NUnit.Framework.Assert.IsTrue(!disjoint.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!touches.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(env2, env1, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(env2, env1, sr, null));
//			}
//			{
//				com.esri.core.geometry.Envelope env1 = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":0,\"ymin\":0,\"xmax\":15,\"ymax\":0}").GetGeometry());
//				com.esri.core.geometry.Envelope env2 = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":0,\"ymin\":0,\"xmax\":10,\"ymax\":0}").GetGeometry());
//				WiggleGeometry(env1, 0.00000001, 1982);
//				WiggleGeometry(env2, 0.00000001, 511);
//				NUnit.Framework.Assert.IsTrue(!equals.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(contains.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!contains.Execute(env2, env1, sr, null));
//				NUnit.Framework.Assert.IsTrue(!disjoint.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!touches.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(env2, env1, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(env2, env1, sr, null));
//			}
//			{
//				com.esri.core.geometry.Envelope env1 = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":0,\"ymin\":0,\"xmax\":15,\"ymax\":0}").GetGeometry());
//				com.esri.core.geometry.Envelope env2 = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":-5,\"ymin\":0,\"xmax\":10,\"ymax\":0}").GetGeometry());
//				WiggleGeometry(env1, 0.00000001, 1982);
//				WiggleGeometry(env2, 0.00000001, 511);
//				NUnit.Framework.Assert.IsTrue(!equals.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!contains.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!contains.Execute(env2, env1, sr, null));
//				NUnit.Framework.Assert.IsTrue(!disjoint.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!touches.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(overlaps.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(overlaps.Execute(env2, env1, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(env2, env1, sr, null));
//			}
//			{
//				com.esri.core.geometry.Envelope env1 = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":0,\"ymin\":0,\"xmax\":5,\"ymax\":0}").GetGeometry());
//				com.esri.core.geometry.Envelope env2 = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":-5,\"ymin\":0,\"xmax\":0,\"ymax\":0}").GetGeometry());
//				WiggleGeometry(env1, 0.00000001, 1982);
//				WiggleGeometry(env2, 0.00000001, 511);
//				NUnit.Framework.Assert.IsTrue(!equals.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!contains.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!contains.Execute(env2, env1, sr, null));
//				NUnit.Framework.Assert.IsTrue(!disjoint.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(touches.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(env2, env1, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(env2, env1, sr, null));
//			}
//			{
//				com.esri.core.geometry.Envelope env1 = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":0,\"ymin\":0,\"xmax\":10,\"ymax\":0}").GetGeometry());
//				com.esri.core.geometry.Envelope env2 = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":5,\"ymin\":-5,\"xmax\":5,\"ymax\":5}").GetGeometry());
//				WiggleGeometry(env1, 0.00000001, 1982);
//				WiggleGeometry(env2, 0.00000001, 511);
//				NUnit.Framework.Assert.IsTrue(!equals.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!contains.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!contains.Execute(env2, env1, sr, null));
//				NUnit.Framework.Assert.IsTrue(!disjoint.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!touches.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(env2, env1, sr, null));
//				NUnit.Framework.Assert.IsTrue(crosses.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(crosses.Execute(env2, env1, sr, null));
//			}
//			{
//				com.esri.core.geometry.Envelope env1 = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":0,\"ymin\":0,\"xmax\":10,\"ymax\":0}").GetGeometry());
//				com.esri.core.geometry.Envelope env2 = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":10,\"ymin\":0,\"xmax\":20,\"ymax\":0}").GetGeometry());
//				WiggleGeometry(env1, 0.00000001, 1982);
//				WiggleGeometry(env2, 0.00000001, 511);
//				NUnit.Framework.Assert.IsTrue(!equals.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!contains.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!contains.Execute(env2, env1, sr, null));
//				NUnit.Framework.Assert.IsTrue(!disjoint.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(touches.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(env2, env1, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(env2, env1, sr, null));
//			}
//			{
//				com.esri.core.geometry.Envelope env1 = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":0,\"ymin\":0,\"xmax\":10,\"ymax\":0}").GetGeometry());
//				com.esri.core.geometry.Envelope env2 = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":5,\"ymin\":0,\"xmax\":5,\"ymax\":5}").GetGeometry());
//				WiggleGeometry(env1, 0.00000001, 1982);
//				WiggleGeometry(env2, 0.00000001, 511);
//				NUnit.Framework.Assert.IsTrue(!equals.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!contains.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!contains.Execute(env2, env1, sr, null));
//				NUnit.Framework.Assert.IsTrue(!disjoint.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(touches.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(touches.Execute(env2, env1, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(env2, env1, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(env2, env1, sr, null));
//			}
//			{
//				com.esri.core.geometry.Envelope env1 = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":0,\"ymin\":0,\"xmax\":0,\"ymax\":0}").GetGeometry());
//				com.esri.core.geometry.Envelope env2 = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":0,\"ymin\":0,\"xmax\":10,\"ymax\":10}").GetGeometry());
//				WiggleGeometry(env1, 0.00000001, 1982);
//				WiggleGeometry(env2, 0.00000001, 511);
//				NUnit.Framework.Assert.IsTrue(!equals.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!contains.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!contains.Execute(env2, env1, sr, null));
//				NUnit.Framework.Assert.IsTrue(!disjoint.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(touches.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(touches.Execute(env2, env1, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(env2, env1, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(env2, env1, sr, null));
//			}
//			{
//				com.esri.core.geometry.Envelope env1 = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":5,\"ymin\":0,\"xmax\":5,\"ymax\":0}").GetGeometry());
//				com.esri.core.geometry.Envelope env2 = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":0,\"ymin\":0,\"xmax\":10,\"ymax\":10}").GetGeometry());
//				WiggleGeometry(env1, 0.00000001, 1982);
//				WiggleGeometry(env2, 0.00000001, 511);
//				NUnit.Framework.Assert.IsTrue(!equals.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!contains.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!contains.Execute(env2, env1, sr, null));
//				NUnit.Framework.Assert.IsTrue(!disjoint.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(touches.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(touches.Execute(env2, env1, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(env2, env1, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(env2, env1, sr, null));
//			}
//			{
//				com.esri.core.geometry.Envelope env1 = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":5,\"ymin\":5,\"xmax\":5,\"ymax\":5}").GetGeometry());
//				com.esri.core.geometry.Envelope env2 = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":0,\"ymin\":0,\"xmax\":10,\"ymax\":10}").GetGeometry());
//				WiggleGeometry(env1, 0.00000001, 1982);
//				WiggleGeometry(env2, 0.00000001, 511);
//				NUnit.Framework.Assert.IsTrue(!equals.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!contains.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(contains.Execute(env2, env1, sr, null));
//				NUnit.Framework.Assert.IsTrue(!disjoint.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!touches.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!touches.Execute(env2, env1, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(env2, env1, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(env2, env1, sr, null));
//			}
//			{
//				com.esri.core.geometry.Envelope env1 = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":0,\"ymin\":0,\"xmax\":0,\"ymax\":0}").GetGeometry());
//				com.esri.core.geometry.Envelope env2 = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":0,\"ymin\":0,\"xmax\":10,\"ymax\":0}").GetGeometry());
//				WiggleGeometry(env1, 0.00000001, 1982);
//				WiggleGeometry(env2, 0.00000001, 511);
//				NUnit.Framework.Assert.IsTrue(!equals.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!contains.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!contains.Execute(env2, env1, sr, null));
//				NUnit.Framework.Assert.IsTrue(!disjoint.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(touches.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(touches.Execute(env2, env1, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(env2, env1, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(env2, env1, sr, null));
//			}
//			{
//				com.esri.core.geometry.Envelope env1 = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":5,\"ymin\":0,\"xmax\":5,\"ymax\":0}").GetGeometry());
//				com.esri.core.geometry.Envelope env2 = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":0,\"ymin\":0,\"xmax\":10,\"ymax\":0}").GetGeometry());
//				WiggleGeometry(env1, 0.00000001, 1982);
//				WiggleGeometry(env2, 0.00000001, 511);
//				NUnit.Framework.Assert.IsTrue(!equals.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!contains.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(contains.Execute(env2, env1, sr, null));
//				NUnit.Framework.Assert.IsTrue(!disjoint.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!touches.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!touches.Execute(env2, env1, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(env2, env1, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(env2, env1, sr, null));
//			}
//			{
//				com.esri.core.geometry.Envelope env1 = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":5,\"ymin\":0,\"xmax\":5,\"ymax\":0}").GetGeometry());
//				com.esri.core.geometry.Envelope env2 = (com.esri.core.geometry.Envelope)(com.esri.core.geometry.TestCommonMethods.FromJson("{\"xmin\":5,\"ymin\":0,\"xmax\":5,\"ymax\":0}").GetGeometry());
//				WiggleGeometry(env1, 0.00000001, 1982);
//				WiggleGeometry(env2, 0.00000001, 511);
//				NUnit.Framework.Assert.IsTrue(equals.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(contains.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(contains.Execute(env2, env1, sr, null));
//				NUnit.Framework.Assert.IsTrue(!disjoint.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!touches.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!touches.Execute(env2, env1, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!overlaps.Execute(env2, env1, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(env1, env2, sr, null));
//				NUnit.Framework.Assert.IsTrue(!crosses.Execute(env2, env1, sr, null));
//			}
//		}

		internal static void WiggleGeometry(com.esri.core.geometry.Geometry geometry, double tolerance, int rand)
		{
			int type = geometry.GetType().Value();
			if (type == com.esri.core.geometry.Geometry.GeometryType.Polygon || type == com.esri.core.geometry.Geometry.GeometryType.Polyline || type == com.esri.core.geometry.Geometry.GeometryType.MultiPoint)
			{
				com.esri.core.geometry.MultiVertexGeometry mvGeom = (com.esri.core.geometry.MultiVertexGeometry)geometry;
				for (int i = 0; i < mvGeom.GetPointCount(); i++)
				{
					com.esri.core.geometry.Point2D pt = mvGeom.GetXY(i);
					// create random vector and normalize it to 0.49 * tolerance
					com.esri.core.geometry.Point2D randomV = new com.esri.core.geometry.Point2D();
					rand = com.esri.core.geometry.NumberUtils.NextRand(rand);
					randomV.x = 1.0 * rand / com.esri.core.geometry.NumberUtils.IntMax() - 0.5;
					rand = com.esri.core.geometry.NumberUtils.NextRand(rand);
					randomV.y = 1.0 * rand / com.esri.core.geometry.NumberUtils.IntMax() - 0.5;
					randomV.Normalize();
					randomV.Scale(0.45 * tolerance);
					pt.Add(randomV);
					mvGeom.SetXY(i, pt);
				}
			}
			else
			{
				if (type == com.esri.core.geometry.Geometry.GeometryType.Point)
				{
					com.esri.core.geometry.Point ptGeom = (com.esri.core.geometry.Point)(geometry);
					com.esri.core.geometry.Point2D pt = ptGeom.GetXY();
					// create random vector and normalize it to 0.49 * tolerance
					com.esri.core.geometry.Point2D randomV = new com.esri.core.geometry.Point2D();
					rand = com.esri.core.geometry.NumberUtils.NextRand(rand);
					randomV.x = 1.0 * rand / com.esri.core.geometry.NumberUtils.IntMax() - 0.5;
					rand = com.esri.core.geometry.NumberUtils.NextRand(rand);
					randomV.y = 1.0 * rand / com.esri.core.geometry.NumberUtils.IntMax() - 0.5;
					randomV.Normalize();
					randomV.Scale(0.45 * tolerance);
					pt.Add(randomV);
					ptGeom.SetXY(pt);
				}
				else
				{
					if (type == com.esri.core.geometry.Geometry.GeometryType.Envelope)
					{
						com.esri.core.geometry.Envelope envGeom = (com.esri.core.geometry.Envelope)(geometry);
						com.esri.core.geometry.Envelope2D env = new com.esri.core.geometry.Envelope2D();
						envGeom.QueryEnvelope2D(env);
						double xmin;
						double xmax;
						double ymin;
						double ymax;
						com.esri.core.geometry.Point2D pt = new com.esri.core.geometry.Point2D();
						env.QueryLowerLeft(pt);
						// create random vector and normalize it to 0.49 * tolerance
						com.esri.core.geometry.Point2D randomV = new com.esri.core.geometry.Point2D();
						rand = com.esri.core.geometry.NumberUtils.NextRand(rand);
						randomV.x = 1.0 * rand / com.esri.core.geometry.NumberUtils.IntMax() - 0.5;
						rand = com.esri.core.geometry.NumberUtils.NextRand(rand);
						randomV.y = 1.0 * rand / com.esri.core.geometry.NumberUtils.IntMax() - 0.5;
						randomV.Normalize();
						randomV.Scale(0.45 * tolerance);
						xmin = (pt.x + randomV.x);
						ymin = (pt.y + randomV.y);
						env.QueryUpperRight(pt);
						// create random vector and normalize it to 0.49 * tolerance
						rand = com.esri.core.geometry.NumberUtils.NextRand(rand);
						randomV.x = 1.0 * rand / com.esri.core.geometry.NumberUtils.IntMax() - 0.5;
						rand = com.esri.core.geometry.NumberUtils.NextRand(rand);
						randomV.y = 1.0 * rand / com.esri.core.geometry.NumberUtils.IntMax() - 0.5;
						randomV.Normalize();
						randomV.Scale(0.45 * tolerance);
						xmax = (pt.x + randomV.x);
						ymax = (pt.y + randomV.y);
						if (xmin > xmax)
						{
							double swap = xmin;
							xmin = xmax;
							xmax = swap;
						}
						if (ymin > ymax)
						{
							double swap = ymin;
							ymin = ymax;
							ymax = swap;
						}
						envGeom.SetCoords(xmin, ymin, xmax, ymax);
					}
				}
			}
		}
		public static void TestPointInAnyOuterRing()
		{
			com.esri.core.geometry.Polygon polygon = new com.esri.core.geometry.Polygon();
			// outer ring1
			polygon.StartPath(-200, -100);
			polygon.LineTo(200, -100);
			polygon.LineTo(200, 100);
			polygon.LineTo(-190, 100);
			polygon.LineTo(-190, 90);
			polygon.LineTo(-200, 90);
			// hole
			polygon.StartPath(-100, 50);
			polygon.LineTo(100, 50);
			polygon.LineTo(100, -40);
			polygon.LineTo(90, -40);
			polygon.LineTo(90, -50);
			polygon.LineTo(-100, -50);
			// island
			polygon.StartPath(-10, -10);
			polygon.LineTo(10, -10);
			polygon.LineTo(10, 10);
			polygon.LineTo(-10, 10);
			// outer ring2
			polygon.StartPath(300, 300);
			polygon.LineTo(310, 300);
			polygon.LineTo(310, 310);
			polygon.LineTo(300, 310);
			polygon.ReverseAllPaths();
			com.esri.core.geometry.Point2D testPointIn1 = new com.esri.core.geometry.Point2D(1, 2);
			// inside the island
			com.esri.core.geometry.Point2D testPointIn2 = new com.esri.core.geometry.Point2D(190, 90);
			// inside, betwen outer
			// ring1 and the hole
			com.esri.core.geometry.Point2D testPointIn3 = new com.esri.core.geometry.Point2D(305, 305);
			// inside the outer ring2
			com.esri.core.geometry.Point2D testPointOut1 = new com.esri.core.geometry.Point2D(300, 2);
			// outside any
			com.esri.core.geometry.Point2D testPointOut2 = new com.esri.core.geometry.Point2D(-195, 95);
			// outside any (in the
			// concave area of outer
			// ring 2)
			com.esri.core.geometry.Point2D testPointOut3 = new com.esri.core.geometry.Point2D(99, 49);
			// outside (in the hole)
			com.esri.core.geometry.PolygonUtils.PiPResult res;
			// is_point_in_polygon_2D
			res = com.esri.core.geometry.PolygonUtils.IsPointInPolygon2D(polygon, testPointIn1, 0);
			NUnit.Framework.Assert.IsTrue(res == com.esri.core.geometry.PolygonUtils.PiPResult.PiPInside);
			res = com.esri.core.geometry.PolygonUtils.IsPointInPolygon2D(polygon, testPointIn2, 0);
			NUnit.Framework.Assert.IsTrue(res == com.esri.core.geometry.PolygonUtils.PiPResult.PiPInside);
			res = com.esri.core.geometry.PolygonUtils.IsPointInPolygon2D(polygon, testPointIn3, 0);
			NUnit.Framework.Assert.IsTrue(res == com.esri.core.geometry.PolygonUtils.PiPResult.PiPInside);
			res = com.esri.core.geometry.PolygonUtils.IsPointInPolygon2D(polygon, testPointOut1, 0);
			NUnit.Framework.Assert.IsTrue(res == com.esri.core.geometry.PolygonUtils.PiPResult.PiPOutside);
			res = com.esri.core.geometry.PolygonUtils.IsPointInPolygon2D(polygon, testPointOut2, 0);
			NUnit.Framework.Assert.IsTrue(res == com.esri.core.geometry.PolygonUtils.PiPResult.PiPOutside);
			res = com.esri.core.geometry.PolygonUtils.IsPointInPolygon2D(polygon, testPointOut3, 0);
			NUnit.Framework.Assert.IsTrue(res == com.esri.core.geometry.PolygonUtils.PiPResult.PiPOutside);
			// Ispoint_in_any_outer_ring
			res = com.esri.core.geometry.PolygonUtils.IsPointInAnyOuterRing(polygon, testPointIn1, 0);
			NUnit.Framework.Assert.IsTrue(res == com.esri.core.geometry.PolygonUtils.PiPResult.PiPInside);
			res = com.esri.core.geometry.PolygonUtils.IsPointInAnyOuterRing(polygon, testPointIn2, 0);
			NUnit.Framework.Assert.IsTrue(res == com.esri.core.geometry.PolygonUtils.PiPResult.PiPInside);
			res = com.esri.core.geometry.PolygonUtils.IsPointInAnyOuterRing(polygon, testPointIn3, 0);
			NUnit.Framework.Assert.IsTrue(res == com.esri.core.geometry.PolygonUtils.PiPResult.PiPInside);
			res = com.esri.core.geometry.PolygonUtils.IsPointInAnyOuterRing(polygon, testPointOut1, 0);
			NUnit.Framework.Assert.IsTrue(res == com.esri.core.geometry.PolygonUtils.PiPResult.PiPOutside);
			res = com.esri.core.geometry.PolygonUtils.IsPointInAnyOuterRing(polygon, testPointOut2, 0);
			NUnit.Framework.Assert.IsTrue(res == com.esri.core.geometry.PolygonUtils.PiPResult.PiPOutside);
			res = com.esri.core.geometry.PolygonUtils.IsPointInAnyOuterRing(polygon, testPointOut3, 0);
			NUnit.Framework.Assert.IsTrue(res == com.esri.core.geometry.PolygonUtils.PiPResult.PiPInside);
		}
		public static com.esri.core.geometry.MultiPoint MakeMultiPoint3()
		{
			com.esri.core.geometry.MultiPoint mpoint = new com.esri.core.geometry.MultiPoint();
			com.esri.core.geometry.Point2D pt1 = new com.esri.core.geometry.Point2D();
			pt1.x = 1.0;
			pt1.y = 1.0;
			com.esri.core.geometry.Point2D pt2 = new com.esri.core.geometry.Point2D();
			pt2.x = 5.0;
			pt2.y = 5.0;
			mpoint.Add(pt1.x, pt1.y);
			mpoint.Add(pt2.x, pt2.y);
			return mpoint;
		}
		private static com.esri.core.geometry.Point MakePoint()
		{
			com.esri.core.geometry.Point point = new com.esri.core.geometry.Point();
			com.esri.core.geometry.Point2D pt = new com.esri.core.geometry.Point2D();
			pt.SetCoords(0, 15);
			point.SetXY(pt);
			return point;
		}
 public static void testPointInAnyOuterRing()
 {
     com.esri.core.geometry.Polygon polygon = new com.esri.core.geometry.Polygon();
     // outer ring1
     polygon.startPath(-200, -100);
     polygon.lineTo(200, -100);
     polygon.lineTo(200, 100);
     polygon.lineTo(-190, 100);
     polygon.lineTo(-190, 90);
     polygon.lineTo(-200, 90);
     // hole
     polygon.startPath(-100, 50);
     polygon.lineTo(100, 50);
     polygon.lineTo(100, -40);
     polygon.lineTo(90, -40);
     polygon.lineTo(90, -50);
     polygon.lineTo(-100, -50);
     // island
     polygon.startPath(-10, -10);
     polygon.lineTo(10, -10);
     polygon.lineTo(10, 10);
     polygon.lineTo(-10, 10);
     // outer ring2
     polygon.startPath(300, 300);
     polygon.lineTo(310, 300);
     polygon.lineTo(310, 310);
     polygon.lineTo(300, 310);
     polygon.reverseAllPaths();
     com.esri.core.geometry.Point2D testPointIn1 = new com.esri.core.geometry.Point2D(
         1, 2);
     // inside the island
     com.esri.core.geometry.Point2D testPointIn2 = new com.esri.core.geometry.Point2D(
         190, 90);
     // inside, betwen outer
     // ring1 and the hole
     com.esri.core.geometry.Point2D testPointIn3 = new com.esri.core.geometry.Point2D(
         305, 305);
     // inside the outer ring2
     com.esri.core.geometry.Point2D testPointOut1 = new com.esri.core.geometry.Point2D
                                                        (300, 2);
     // outside any
     com.esri.core.geometry.Point2D testPointOut2 = new com.esri.core.geometry.Point2D
                                                        (-195, 95);
     // outside any (in the
     // concave area of outer
     // ring 2)
     com.esri.core.geometry.Point2D testPointOut3 = new com.esri.core.geometry.Point2D
                                                        (99, 49);
     // outside (in the hole)
     com.esri.core.geometry.PolygonUtils.PiPResult res;
     // is_point_in_polygon_2D
     res = com.esri.core.geometry.PolygonUtils.isPointInPolygon2D(polygon, testPointIn1
                                                                  , 0);
     NUnit.Framework.Assert.IsTrue(res == com.esri.core.geometry.PolygonUtils.PiPResult
                                   .PiPInside);
     res = com.esri.core.geometry.PolygonUtils.isPointInPolygon2D(polygon, testPointIn2
                                                                  , 0);
     NUnit.Framework.Assert.IsTrue(res == com.esri.core.geometry.PolygonUtils.PiPResult
                                   .PiPInside);
     res = com.esri.core.geometry.PolygonUtils.isPointInPolygon2D(polygon, testPointIn3
                                                                  , 0);
     NUnit.Framework.Assert.IsTrue(res == com.esri.core.geometry.PolygonUtils.PiPResult
                                   .PiPInside);
     res = com.esri.core.geometry.PolygonUtils.isPointInPolygon2D(polygon, testPointOut1
                                                                  , 0);
     NUnit.Framework.Assert.IsTrue(res == com.esri.core.geometry.PolygonUtils.PiPResult
                                   .PiPOutside);
     res = com.esri.core.geometry.PolygonUtils.isPointInPolygon2D(polygon, testPointOut2
                                                                  , 0);
     NUnit.Framework.Assert.IsTrue(res == com.esri.core.geometry.PolygonUtils.PiPResult
                                   .PiPOutside);
     res = com.esri.core.geometry.PolygonUtils.isPointInPolygon2D(polygon, testPointOut3
                                                                  , 0);
     NUnit.Framework.Assert.IsTrue(res == com.esri.core.geometry.PolygonUtils.PiPResult
                                   .PiPOutside);
     // Ispoint_in_any_outer_ring
     res = com.esri.core.geometry.PolygonUtils.isPointInAnyOuterRing(polygon, testPointIn1
                                                                     , 0);
     NUnit.Framework.Assert.IsTrue(res == com.esri.core.geometry.PolygonUtils.PiPResult
                                   .PiPInside);
     res = com.esri.core.geometry.PolygonUtils.isPointInAnyOuterRing(polygon, testPointIn2
                                                                     , 0);
     NUnit.Framework.Assert.IsTrue(res == com.esri.core.geometry.PolygonUtils.PiPResult
                                   .PiPInside);
     res = com.esri.core.geometry.PolygonUtils.isPointInAnyOuterRing(polygon, testPointIn3
                                                                     , 0);
     NUnit.Framework.Assert.IsTrue(res == com.esri.core.geometry.PolygonUtils.PiPResult
                                   .PiPInside);
     res = com.esri.core.geometry.PolygonUtils.isPointInAnyOuterRing(polygon, testPointOut1
                                                                     , 0);
     NUnit.Framework.Assert.IsTrue(res == com.esri.core.geometry.PolygonUtils.PiPResult
                                   .PiPOutside);
     res = com.esri.core.geometry.PolygonUtils.isPointInAnyOuterRing(polygon, testPointOut2
                                                                     , 0);
     NUnit.Framework.Assert.IsTrue(res == com.esri.core.geometry.PolygonUtils.PiPResult
                                   .PiPOutside);
     res = com.esri.core.geometry.PolygonUtils.isPointInAnyOuterRing(polygon, testPointOut3
                                                                     , 0);
     NUnit.Framework.Assert.IsTrue(res == com.esri.core.geometry.PolygonUtils.PiPResult
                                   .PiPInside);
 }
		public static void TestPointsArray()
		{
			com.esri.core.geometry.Point2D[] points = new com.esri.core.geometry.Point2D[6];
			int[] convex_hull = new int[6];
			for (int i = 0; i < 6; i++)
			{
				points[i] = new com.esri.core.geometry.Point2D();
			}
			points[0].x = 0;
			points[0].y = 0;
			points[1].x = 5;
			points[1].y = 10;
			points[2].x = 10;
			points[2].y = 0;
			points[3].x = 0;
			points[3].y = 5;
			points[4].x = 10;
			points[4].y = 5;
			points[5].x = 5;
			points[5].y = -5;
			com.esri.core.geometry.ConvexHull.Construct(points, 6, convex_hull);
			NUnit.Framework.Assert.IsTrue(convex_hull[0] == 0);
			NUnit.Framework.Assert.IsTrue(convex_hull[1] == 3);
			NUnit.Framework.Assert.IsTrue(convex_hull[2] == 1);
			NUnit.Framework.Assert.IsTrue(convex_hull[3] == 4);
			NUnit.Framework.Assert.IsTrue(convex_hull[4] == 2);
			NUnit.Framework.Assert.IsTrue(convex_hull[5] == 5);
		}
		public static com.esri.core.geometry.MultiPoint MakeMultiPoint2()
		{
			com.esri.core.geometry.MultiPoint mpoint = new com.esri.core.geometry.MultiPoint();
			com.esri.core.geometry.Point2D pt1 = new com.esri.core.geometry.Point2D();
			pt1.x = 1.0;
			pt1.y = 1.0;
			com.esri.core.geometry.Point2D pt2 = new com.esri.core.geometry.Point2D();
			pt2.x = 1.0;
			pt2.y = 1.0;
			com.esri.core.geometry.Point2D pt3 = new com.esri.core.geometry.Point2D();
			pt3.x = 15.0;
			pt3.y = 15.0;
			com.esri.core.geometry.Point2D pt4 = new com.esri.core.geometry.Point2D();
			pt4.x = 15.0;
			pt4.y = 15.0;
			com.esri.core.geometry.Point2D pt5 = new com.esri.core.geometry.Point2D();
			pt5.x = 1.0;
			pt5.y = 1.0;
			com.esri.core.geometry.Point2D pt6 = new com.esri.core.geometry.Point2D();
			pt6.x = 1.0;
			pt6.y = 1.0;
			com.esri.core.geometry.Point2D pt7 = new com.esri.core.geometry.Point2D();
			pt7.x = 15.0;
			pt7.y = 15.0;
			com.esri.core.geometry.Point2D pt8 = new com.esri.core.geometry.Point2D();
			pt8.x = 15.0;
			pt8.y = 15.0;
			com.esri.core.geometry.Point2D pt9 = new com.esri.core.geometry.Point2D();
			pt9.x = 15.0;
			pt9.y = 15.0;
			com.esri.core.geometry.Point2D pt10 = new com.esri.core.geometry.Point2D();
			pt10.x = 1.0;
			pt10.y = 1.0;
			com.esri.core.geometry.Point2D pt11 = new com.esri.core.geometry.Point2D();
			pt11.x = 15.0;
			pt11.y = 15.0;
			mpoint.Add(pt1.x, pt1.y);
			mpoint.Add(pt2.x, pt2.y);
			mpoint.Add(pt3.x, pt3.y);
			mpoint.Add(pt4.x, pt4.y);
			mpoint.Add(pt5.x, pt5.y);
			mpoint.Add(pt6.x, pt6.y);
			mpoint.Add(pt7.x, pt7.y);
			mpoint.Add(pt8.x, pt8.y);
			mpoint.Add(pt9.x, pt9.y);
			mpoint.Add(pt10.x, pt10.y);
			mpoint.Add(pt11.x, pt11.y);
			return mpoint;
		}
		public virtual void TestEnvelope2D_corners()
		{
			com.esri.core.geometry.Envelope2D env = new com.esri.core.geometry.Envelope2D(0, 1, 2, 3);
			NUnit.Framework.Assert.IsFalse(env.Equals(null));
			NUnit.Framework.Assert.IsTrue(env.Equals((object)new com.esri.core.geometry.Envelope2D(0, 1, 2, 3)));
			com.esri.core.geometry.Point2D pt2D = env.GetLowerLeft();
			NUnit.Framework.Assert.IsTrue(pt2D.Equals(com.esri.core.geometry.Point2D.Construct(0, 1)));
			pt2D = env.GetUpperLeft();
			NUnit.Framework.Assert.IsTrue(pt2D.Equals(com.esri.core.geometry.Point2D.Construct(0, 3)));
			pt2D = env.GetUpperRight();
			NUnit.Framework.Assert.IsTrue(pt2D.Equals(com.esri.core.geometry.Point2D.Construct(2, 3)));
			pt2D = env.GetLowerRight();
			NUnit.Framework.Assert.IsTrue(pt2D.Equals(com.esri.core.geometry.Point2D.Construct(2, 1)));
			{
				com.esri.core.geometry.Point2D[] corners = new com.esri.core.geometry.Point2D[4];
				env.QueryCorners(corners);
				NUnit.Framework.Assert.IsTrue(corners[0].Equals(com.esri.core.geometry.Point2D.Construct(0, 1)));
				NUnit.Framework.Assert.IsTrue(corners[1].Equals(com.esri.core.geometry.Point2D.Construct(0, 3)));
				NUnit.Framework.Assert.IsTrue(corners[2].Equals(com.esri.core.geometry.Point2D.Construct(2, 3)));
				NUnit.Framework.Assert.IsTrue(corners[3].Equals(com.esri.core.geometry.Point2D.Construct(2, 1)));
				env.QueryCorners(corners);
				NUnit.Framework.Assert.IsTrue(corners[0].Equals(env.QueryCorner(0)));
				NUnit.Framework.Assert.IsTrue(corners[1].Equals(env.QueryCorner(1)));
				NUnit.Framework.Assert.IsTrue(corners[2].Equals(env.QueryCorner(2)));
				NUnit.Framework.Assert.IsTrue(corners[3].Equals(env.QueryCorner(3)));
			}
			{
				com.esri.core.geometry.Point2D[] corners = new com.esri.core.geometry.Point2D[4];
				env.QueryCornersReversed(corners);
				NUnit.Framework.Assert.IsTrue(corners[0].Equals(com.esri.core.geometry.Point2D.Construct(0, 1)));
				NUnit.Framework.Assert.IsTrue(corners[1].Equals(com.esri.core.geometry.Point2D.Construct(2, 1)));
				NUnit.Framework.Assert.IsTrue(corners[2].Equals(com.esri.core.geometry.Point2D.Construct(2, 3)));
				NUnit.Framework.Assert.IsTrue(corners[3].Equals(com.esri.core.geometry.Point2D.Construct(0, 3)));
				env.QueryCornersReversed(corners);
				NUnit.Framework.Assert.IsTrue(corners[0].Equals(env.QueryCorner(0)));
				NUnit.Framework.Assert.IsTrue(corners[1].Equals(env.QueryCorner(3)));
				NUnit.Framework.Assert.IsTrue(corners[2].Equals(env.QueryCorner(2)));
				NUnit.Framework.Assert.IsTrue(corners[3].Equals(env.QueryCorner(1)));
			}
			NUnit.Framework.Assert.IsTrue(env.GetCenter().Equals(com.esri.core.geometry.Point2D.Construct(1, 2)));
			NUnit.Framework.Assert.IsFalse(env.ContainsExclusive(env.GetUpperLeft()));
			NUnit.Framework.Assert.IsTrue(env.Contains(env.GetUpperLeft()));
			NUnit.Framework.Assert.IsTrue(env.ContainsExclusive(env.GetCenter()));
		}
		public static com.esri.core.geometry.Point MakePoint2()
		{
			com.esri.core.geometry.Point point = new com.esri.core.geometry.Point();
			com.esri.core.geometry.Point2D pt = new com.esri.core.geometry.Point2D();
			pt.SetCoords(7, 7);
			point.SetXY(pt);
			return point;
		}
        internal virtual bool rgHelper(com.esri.core.geometry.RasterizedGeometry2D rg, com.esri.core.geometry.MultiPath
                                       mp)
        {
            com.esri.core.geometry.SegmentIterator iter = mp.querySegmentIterator();
            while (iter.nextPath())
            {
                while (iter.hasNextSegment())
                {
                    com.esri.core.geometry.Segment seg = iter.nextSegment();
                    int count = 20;
                    for (int i = 0; i < count; i++)
                    {
                        double t = (1.0 * i / count);
                        com.esri.core.geometry.Point2D pt = seg.getCoord2D(t);
                        com.esri.core.geometry.RasterizedGeometry2D.HitType hit = rg.queryPointInGeometry
                                                                                      (pt.x, pt.y);
                        if (hit != com.esri.core.geometry.RasterizedGeometry2D.HitType.Border)
                        {
                            return(false);
                        }
                    }
                }
            }
            if (mp.getType() != com.esri.core.geometry.Geometry.Type.Polygon)
            {
                return(true);
            }
            com.esri.core.geometry.Polygon    poly = (com.esri.core.geometry.Polygon)mp;
            com.esri.core.geometry.Envelope2D env  = new com.esri.core.geometry.Envelope2D();
            poly.queryEnvelope2D(env);
            int count_1 = 100;

            for (int iy = 0; iy < count_1; iy++)
            {
                double ty = 1.0 * iy / count_1;
                double y  = env.ymin * (1.0 - ty) + ty * env.ymax;
                for (int ix = 0; ix < count_1; ix++)
                {
                    double tx = 1.0 * ix / count_1;
                    double x  = env.xmin * (1.0 - tx) + tx * env.xmax;
                    com.esri.core.geometry.RasterizedGeometry2D.HitType hit = rg.queryPointInGeometry
                                                                                  (x, y);
                    com.esri.core.geometry.PolygonUtils.PiPResult res = com.esri.core.geometry.PolygonUtils
                                                                        .isPointInPolygon2D(poly, new com.esri.core.geometry.Point2D(x, y), 0);
                    if (res == com.esri.core.geometry.PolygonUtils.PiPResult.PiPInside)
                    {
                        bool bgood = (hit == com.esri.core.geometry.RasterizedGeometry2D.HitType.Border ||
                                      hit == com.esri.core.geometry.RasterizedGeometry2D.HitType.Inside);
                        if (!bgood)
                        {
                            return(false);
                        }
                    }
                    else
                    {
                        if (res == com.esri.core.geometry.PolygonUtils.PiPResult.PiPOutside)
                        {
                            bool bgood = (hit == com.esri.core.geometry.RasterizedGeometry2D.HitType.Border ||
                                          hit == com.esri.core.geometry.RasterizedGeometry2D.HitType.Outside);
                            if (!bgood)
                            {
                                return(false);
                            }
                        }
                        else
                        {
                            bool bgood = (hit == com.esri.core.geometry.RasterizedGeometry2D.HitType.Border);
                            if (!bgood)
                            {
                                return(false);
                            }
                        }
                    }
                }
            }
            return(true);
        }