Package org.postgis

Examples of org.postgis.LinearRing


   * @return The Polygon object.
   */
  public Polygon createPolygon(Point[] points) {
    Polygon result;
   
    result = new Polygon(new LinearRing[] {new LinearRing(points)});
    result.srid = 4326;
   
    return result;
  }
View Full Code Here


        return locationStore.getNodeLocation(nodeId);
    }
 
  private Polygon createWayBbox(double left, double right, double bottom, double top) {
    Point[] points;
    LinearRing ring;
    Polygon bbox;
   
    points = new Point[5];
    points[0] = new Point(left, bottom);
    points[1] = new Point(left, top);
    points[2] = new Point(right, top);
    points[3] = new Point(right, bottom);
    points[4] = new Point(left, bottom);
   
    ring = new LinearRing(points);
   
    bbox = new Polygon(new LinearRing[] {ring});
    bbox.srid = 4326;
   
    return bbox;
View Full Code Here

        return locationStore.getNodeLocation(nodeId);
    }
 
  private Polygon createWayBbox(double left, double right, double bottom, double top) {
    Point[] points;
    LinearRing ring;
    Polygon bbox;
   
    points = new Point[5];
    points[0] = new Point(left, bottom);
    points[1] = new Point(left, top);
    points[2] = new Point(right, top);
    points[3] = new Point(right, bottom);
    points[4] = new Point(left, bottom);
   
    ring = new LinearRing(points);
   
    bbox = new Polygon(new LinearRing[] {ring});
    bbox.srid = 4326;
   
    return bbox;
View Full Code Here

        return new LineString(points);
    }

    private LinearRing parseLinearRing(ValueGetter data, boolean haveZ, boolean haveM) {
        Point[] points = parsePointArray(data, haveZ, haveM);
        return new LinearRing(points);
    }
View Full Code Here

        String ptg_str = "POINT(10 10 20)";
        String lr_str = "(10 10 20,34 34 34, 23 19 23 , 10 10 11)";

        System.out.println("LinearRing Test:");
        System.out.println("\t" + lr_str);
        LinearRing lr = new LinearRing(lr_str);
        System.out.println("\t" + lr.toString());

        System.out.println();

        System.out.println("Point Test:");
        System.out.println("\t" + ptg_str);
View Full Code Here

   * @return The Polygon object.
   */
  public Polygon createPolygon(Point[] points) {
    Polygon result;
   
    result = new Polygon(new LinearRing[] {new LinearRing(points)});
    result.srid = 4326;
   
    return result;
  }
View Full Code Here

TOP

Related Classes of org.postgis.LinearRing

Copyright © 2018 www.massapicom. 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.