Package com.vividsolutions.jts.geom

Examples of com.vividsolutions.jts.geom.Polygon.normalize()


    assertEqualsExact(expectedValue, l);
  }

  public void testNormalizeEmptyPolygon() throws Exception {
    Polygon actualValue = (Polygon) reader.read("POLYGON EMPTY");
    actualValue.normalize();
    Polygon expectedValue = (Polygon) reader.read("POLYGON EMPTY");
    assertEqualsExact(expectedValue, actualValue);
  }

  public void testNormalizePolygon1() throws Exception {
View Full Code Here


  }

  public void testNormalizePolygon1() throws Exception {
    Polygon actualValue = (Polygon) reader.read(
          "POLYGON ((120 320, 240 200, 120 80, 20 200, 120 320), (60 200, 80 220, 80 200, 60 200), (160 200, 180 200, 180 220, 160 200), (120 140, 140 140, 140 160, 120 140), (140 240, 140 220, 120 260, 140 240))");
    actualValue.normalize();
    Polygon expectedValue = (Polygon) reader.read(
          "POLYGON ((20 200, 120 320, 240 200, 120 80, 20 200), (60 200, 80 200, 80 220, 60 200), (120 140, 140 140, 140 160, 120 140), (120 260, 140 220, 140 240, 120 260), (160 200, 180 200, 180 220, 160 200))");
    assertEqualsExact(expectedValue, actualValue);
  }
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.