Examples of createLinearRing()


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

     * @throws Exception
     */
    @Test
    public void testSetTransformScale() throws Exception {
        GeometryFactory factory = new GeometryFactory();
        LinearRing linearRing = factory.createLinearRing(new Coordinate[]{
                new Coordinate(10, 10),
                new Coordinate(10, 20.5),
                new Coordinate(10, 20),
                new Coordinate(20, 20),
                new Coordinate(10, 10)
View Full Code Here

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

   
    @Test
    public void testSetGeometries() throws Exception {
        GeometryFactory factory = new GeometryFactory();
        int offset=0;
        LinearRing linearRing = factory.createLinearRing(new Coordinate[]{
                new Coordinate(offset+5, 7),
                new Coordinate(offset+8, 7),
                new Coordinate(offset+8, 8),
                new Coordinate(offset+5, 8),
                new Coordinate(offset+5, 7)
View Full Code Here

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

            }else if( i==1 ){
                geom=geomFac.createLineString(new Coordinate[]{
                        new Coordinate( 10,10), new Coordinate(10,20)
                });
            }else{
                geom=geomFac.createLinearRing(
                        new Coordinate[]{
                                new Coordinate( 20,10), new Coordinate(40,10),
                                new Coordinate( 40,40), new Coordinate(20,40),
                                new Coordinate( 20,10)
                        }
View Full Code Here

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

    @Test
    public void testMovePointOnGeometry() throws Exception {
      GeometryFactory fac = new GeometryFactory();
     
      double[] coords = new double[]{10,10, 10,20, 10,30, 30,30, 20,30, 10,10};
    LinearRing ring = fac.createLinearRing(new PackedCoordinateSequenceFactory().create(coords , 2));
      Polygon poly = fac.createPolygon(ring, new LinearRing[0]);
     
      bb.clear();
      geom =  bb.addGeometry(poly, "poly").values().iterator().next();
     
View Full Code Here

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

    public void setUp() throws Exception {
        GeometryFactory fac=new GeometryFactory();
        LineString line = fac.createLineString(new Coordinate[]{
           new Coordinate(0,10),new Coordinate(10,10), new Coordinate(20,10)
        });
        Polygon poly = fac.createPolygon(fac.createLinearRing(new Coordinate[]{
                new Coordinate(20,20),new Coordinate(40,20), new Coordinate(40,40),
                new Coordinate(20,40), new Coordinate(20,20)
             }), new LinearRing[0]);
   
        handler=new TestHandler();
View Full Code Here

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

    @Test
    public void testDiffOnMultipleGeoms() throws Exception {
        handler.resetEditBlackboard();
        GeometryFactory fac=new GeometryFactory();
        LinearRing ring=fac.createLinearRing(new Coordinate[]{
                new Coordinate(0,50),
                new Coordinate(50,50),
                new Coordinate(50,55),
                new Coordinate(0,55),
                new Coordinate(0,50),
View Full Code Here

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

   
    @Test
    public void testMultiGeometry() throws Exception {
        handler.resetEditBlackboard();
        GeometryFactory fac=new GeometryFactory();
        LinearRing ring1=fac.createLinearRing(new Coordinate[]{
                new Coordinate(0,0),
                new Coordinate(50,0),
                new Coordinate(50,10),
                new Coordinate(0,10),
                new Coordinate(0,0),
View Full Code Here

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

                new Coordinate(0,10),
                new Coordinate(0,0),
        });
        Polygon polygon1 = fac.createPolygon(ring1, new LinearRing[0]);

        LinearRing ring2=fac.createLinearRing(new Coordinate[]{
                new Coordinate(0,50),
                new Coordinate(50,50),
                new Coordinate(50,60),
                new Coordinate(0,60),
                new Coordinate(0,50),
View Full Code Here

Examples of org.geomajas.gwt.client.spatial.geometry.GeometryFactory.createLinearRing()

    button3.addClickHandler(new ClickHandler() {

      public void onClick(ClickEvent event) {
        map.getVectorContext().drawGroup(map.getGroup(RenderGroup.SCREEN), group2);
        GeometryFactory factory = map.getMapModel().getGeometryFactory();
        LinearRing shell = factory.createLinearRing(new Coordinate[] { new Coordinate(110, 10),
            new Coordinate(210, 10), new Coordinate(210, 110), new Coordinate(110, 110),
            new Coordinate(110, 10) });
        LinearRing hole = factory.createLinearRing(new Coordinate[] { new Coordinate(140, 40),
            new Coordinate(170, 40), new Coordinate(170, 70), new Coordinate(140, 70),
            new Coordinate(140, 40) });
View Full Code Here

Examples of org.geomajas.gwt.client.spatial.geometry.GeometryFactory.createLinearRing()

        map.getVectorContext().drawGroup(map.getGroup(RenderGroup.SCREEN), group2);
        GeometryFactory factory = map.getMapModel().getGeometryFactory();
        LinearRing shell = factory.createLinearRing(new Coordinate[] { new Coordinate(110, 10),
            new Coordinate(210, 10), new Coordinate(210, 110), new Coordinate(110, 110),
            new Coordinate(110, 10) });
        LinearRing hole = factory.createLinearRing(new Coordinate[] { new Coordinate(140, 40),
            new Coordinate(170, 40), new Coordinate(170, 70), new Coordinate(140, 70),
            new Coordinate(140, 40) });
        Polygon polygon = factory.createPolygon(shell, new LinearRing[] { hole });
        ShapeStyle style = new ShapeStyle("#9933EE", 0.5f, "#9900FF", 1, 2);
        map.getVectorContext().drawPolygon(group2, "Polygon", polygon, style);
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.