Examples of createPolygon()


Examples of com.vividsolutions.jts.geom.GeometryFactory.createPolygon()

        new Coordinate(0,512),
        new Coordinate(0,256),
       
    });
   
    Polygon poly2=factory.createPolygon( ring2, new LinearRing[]{});
   
    SimpleFeature[] features=UDIGTestUtil.createTestFeatures("testType", new Geometry[]{poly1, poly2},new String[]{}//$NON-NLS-1$
        DefaultEngineeringCRS.CARTESIAN_2D);
    map=MapTests.createNonDynamicMapAndRenderer(MapTests.createGeoResource(features, true), new Dimension(w,h));
    StyleBuilder sb=new StyleBuilder();
View Full Code Here

Examples of com.vividsolutions.jts.geom.GeometryFactory.createPolygon()

        LinearRing r2 = builder.safeCreateGeometry(LinearRing.class, new Coordinate[]{
            new Coordinate(2,2), new Coordinate(8,2), new Coordinate(8,8), new Coordinate(2,2),
        });
       
        GeometryFactory fac=new GeometryFactory();
        Polygon poly = fac.createPolygon(r1, new LinearRing[]{r2});
        setSource("Polygon", poly);
       
        copyFeatures(MultiPolygon.class, 1);
    }
   
View Full Code Here

Examples of com.vividsolutions.jts.geom.GeometryFactory.createPolygon()

        LinearRing r2 = builder.safeCreateGeometry(LinearRing.class, new Coordinate[]{
            new Coordinate(2,2), new Coordinate(8,2), new Coordinate(8,8), new Coordinate(2,2),
        });
       
        GeometryFactory fac=new GeometryFactory();
        Polygon poly = fac.createPolygon(r1, new LinearRing[]{r2});
        setSource("Polygon", poly);
       
        copyFeatures(MultiLineString.class, 1);
       
        ILayer layer = targetMap.getMapLayers().get(0);
View Full Code Here

Examples of com.vividsolutions.jts.geom.GeometryFactory.createPolygon()

        LinearRing r2 = builder.safeCreateGeometry(LinearRing.class, new Coordinate[]{
            new Coordinate(2,2), new Coordinate(8,2), new Coordinate(8,8), new Coordinate(2,2),
        });
       
        GeometryFactory fac=new GeometryFactory();
        Polygon poly = fac.createPolygon(r1, new LinearRing[]{r2});
        setSource("Polygon", poly);
       
        copyFeatures(LineString.class, 2);

    }
View Full Code Here

Examples of com.vividsolutions.jts.geom.GeometryFactory.createPolygon()

        LinearRing r2 = builder.safeCreateGeometry(LinearRing.class, new Coordinate[]{
            new Coordinate(2,2), new Coordinate(8,2), new Coordinate(8,8), new Coordinate(2,2),
        });
       
        GeometryFactory fac=new GeometryFactory();
        Polygon poly = fac.createPolygon(r1, new LinearRing[]{r2});
        setSource("Polygon", poly);
       
        copyFeatures(LinearRing.class, 2);
    }
   
View Full Code Here

Examples of com.vividsolutions.jts.geom.GeometryFactory.createPolygon()

        LinearRing r2 = builder.safeCreateGeometry(LinearRing.class, new Coordinate[]{
            new Coordinate(2,2), new Coordinate(8,2), new Coordinate(8,8), new Coordinate(2,2),
        });
       
        GeometryFactory fac=new GeometryFactory();
        Polygon poly = fac.createPolygon(r1, new LinearRing[]{r2});
        setSource("MultiPolygon", fac.createMultiPolygon(new Polygon[]{poly}));
       
        copyFeatures(LineString.class, 2);
       
        ILayer layer = targetMap.getMapLayers().get(0);
View Full Code Here

Examples of com.vividsolutions.jts.geom.GeometryFactory.createPolygon()

        LinearRing r2 = builder.safeCreateGeometry(LinearRing.class, new Coordinate[]{
            new Coordinate(2,2), new Coordinate(8,2), new Coordinate(8,8), new Coordinate(2,2),
        });
       
        GeometryFactory fac=new GeometryFactory();
        Polygon poly = fac.createPolygon(r1, new LinearRing[]{r2});
        setSource("MultiPolygon", fac.createMultiPolygon(new Polygon[]{poly, fac.createPolygon(r2, new LinearRing[0])}));
       
        copyFeatures(Polygon.class, 2);
    }
   
View Full Code Here

Examples of com.vividsolutions.jts.geom.GeometryFactory.createPolygon()

            new Coordinate(2,2), new Coordinate(8,2), new Coordinate(8,8), new Coordinate(2,2),
        });
       
        GeometryFactory fac=new GeometryFactory();
        Polygon poly = fac.createPolygon(r1, new LinearRing[]{r2});
        setSource("MultiPolygon", fac.createMultiPolygon(new Polygon[]{poly, fac.createPolygon(r2, new LinearRing[0])}));
       
        copyFeatures(Polygon.class, 2);
    }
   
    @SuppressWarnings("deprecation")
View Full Code Here

Examples of com.vividsolutions.jts.geom.GeometryFactory.createPolygon()

        LinearRing r2 = builder.safeCreateGeometry(LinearRing.class, new Coordinate[]{
            new Coordinate(2,2), new Coordinate(8,2), new Coordinate(8,8), new Coordinate(2,2),
        });
       
        GeometryFactory fac=new GeometryFactory();
        Polygon poly = fac.createPolygon(r1, new LinearRing[]{r2});
        setSource("Polygon", poly);
       
        copyFeatures(LineString.class, 2);
       
        ILayer layer = targetMap.getMapLayers().get(0);
View Full Code Here

Examples of com.vividsolutions.jts.geom.GeometryFactory.createPolygon()

      // try to create a linearRing.
      LinearRing ring;
      try {
        ring = factory.createLinearRing(closedLine);
        // Create the polygon geometry and add to the list.
        Geometry polygonGeometry = factory.createPolygon(ring, null);
        ringsList.add(polygonGeometry);
      } catch (Exception e) {
        // Couldn't create a ring from this geometry,so continue.
        continue;
      }
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.