Package org.opengis.geometry.coordinate

Examples of org.opengis.geometry.coordinate.LineString


    /**
     * @inheritDoc
     * @see org.opengis.geometry.coordinate.Factory#createLineString(java.util.List)
     */
    public LineString createLineString(final List/*<Position>*/ points) {
        LineString result = new LineStringImpl();
        PointArray pa = result.getControlPoints();
        List list = pa;
        Iterator it = points.iterator();
        while (it.hasNext()) {
//            Object o = it.next();
//            if (o instanceof DirectPosition) {
View Full Code Here


          return (LineString) segment1;
        }
      } else if (count > 0) {
      boolean allLineString = true;
      LineStringImpl lsi = new LineStringImpl();
      LineString ls = null;
      List retList = lsi.getControlPoints();
      Object lastPoint = null;
      List segList = null;
      for (int i = 0; i < count && allLineString; i++) {
          Object segment = curveSegments.get(0);
View Full Code Here

    dps.add(aGeomFactory.createDirectPosition( new double[] {30, 50} ));
    dps.add(aGeomFactory.createDirectPosition( new double[] {10, 30} ));
    dps.add(aGeomFactory.createDirectPosition( new double[] {20, 10} ));

//     create linestring from directpositions
    LineString line = aGeomFactory.createLineString(dps);

//     create curvesegments from line
    ArrayList<CurveSegment> segs = new ArrayList<CurveSegment>();
    segs.add(line);
View Full Code Here

              .createPosition(this.positionFactory
                  .createDirectPosition((aCoords[i]
                      .getCoordinates()))));
    }
    // Create List of CurveSegment´s (LineString´s)
    LineString lineString = new LineStringImpl(new PointArrayImpl( points ), 0.0); //this.geometryFactory.createLineString(points);
    List<CurveSegment> segments = new ArrayList<CurveSegment>();
    segments.add(lineString);
    return new CurveImpl(crs, segments); //this.primitiveFactory.createCurve(segments);
  }
View Full Code Here

TOP

Related Classes of org.opengis.geometry.coordinate.LineString

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.