Examples of equalsExact()


Examples of com.vividsolutions.jts.geom.LineString.equalsExact()

        // retrieve it back
        SimpleFeatureIterator fi = fs.getFeatures(FF.id(new HashSet<FeatureId>(fids))).features();
        assertTrue(fi.hasNext());
        SimpleFeature f = fi.next();
        assertTrue(ls.equalsExact((Geometry) f.getDefaultGeometry()));
        fi.close();
    }

    public void testCreateSchemaAndInsertPolyTriangle() throws Exception {
        LiteCoordinateSequenceFactory csf = new LiteCoordinateSequenceFactory();
View Full Code Here

Examples of com.vividsolutions.jts.geom.LineString.equalsExact()

        assertEquals(epsg4326, fr.getFeatureType().getCoordinateReferenceSystem());
        assertEquals(epsg4326, fr.getFeatureType().getGeometryDescriptor()
                .getCoordinateReferenceSystem());
        assertTrue(fr.hasNext());
        SimpleFeature f = fr.next();
        assertTrue(expected.equalsExact((Geometry) f.getDefaultGeometry()));
        fr.close();
    }

}
View Full Code Here

Examples of com.vividsolutions.jts.geom.LineString.equalsExact()

   
    @Test
    public void testCross() throws Exception {
        LineString ls = (LineString) wkt.read("LINESTRING(-5 -5, 15 15)");
        LineString clipped = (LineString) clipper.clip(ls, false);
        assertTrue(clipped.equalsExact(wkt.read("LINESTRING(0 0, 10 10)")));
        showResult("Cross", ls, clipped);
    }
   
    @Test
    public void testTouchLine() throws Exception {
View Full Code Here

Examples of com.vividsolutions.jts.geom.LineString.equalsExact()

   
    @Test
    public void testTouchLine() throws Exception {
        LineString ls = (LineString) wkt.read("LINESTRING(0 0, 0 10)");
        LineString clipped = (LineString) clipper.clip(ls, false);
        assertTrue(clipped.equalsExact(ls));
        showResult("Touch border", ls, clipped);
    }
   
    @Test
    public void testTouchPoint() throws Exception {
View Full Code Here

Examples of com.vividsolutions.jts.geom.LineString.equalsExact()

  public void test1() throws Exception {
    WKTReader reader = new WKTReader(new GeometryFactory(new PrecisionModel(1), 0));
    LineString lineString = (LineString) reader.read("LINESTRING (30 220, 240 220, 240 220)");
    LineString convexHull = (LineString) reader.read("LINESTRING (30 220, 240 220)");
    assertTrue(convexHull.equalsExact(lineString.convexHull()));
  }

  public void test2() throws Exception {
    WKTReader reader = new WKTReader(new GeometryFactory(new PrecisionModel(1), 0));
    Geometry geometry = reader.read("MULTIPOINT (130 240, 130 240, 130 240, 570 240, 570 240, 570 240, 650 240)");
View Full Code Here

Examples of com.vividsolutions.jts.geom.LineString.equalsExact()

  public void test2() throws Exception {
    WKTReader reader = new WKTReader(new GeometryFactory(new PrecisionModel(1), 0));
    Geometry geometry = reader.read("MULTIPOINT (130 240, 130 240, 130 240, 570 240, 570 240, 570 240, 650 240)");
    LineString convexHull = (LineString) reader.read("LINESTRING (130 240, 650 240)");
    assertTrue(convexHull.equalsExact(geometry.convexHull()));
  }

  public void test3() throws Exception {
    WKTReader reader = new WKTReader(new GeometryFactory(new PrecisionModel(1), 0));
    Geometry geometry = reader.read("MULTIPOINT (0 0, 0 0, 10 0)");
View Full Code Here

Examples of com.vividsolutions.jts.geom.LineString.equalsExact()

  public void test3() throws Exception {
    WKTReader reader = new WKTReader(new GeometryFactory(new PrecisionModel(1), 0));
    Geometry geometry = reader.read("MULTIPOINT (0 0, 0 0, 10 0)");
    LineString convexHull = (LineString) reader.read("LINESTRING (0 0, 10 0)");
    assertTrue(convexHull.equalsExact(geometry.convexHull()));
  }

  public void test4() throws Exception {
    WKTReader reader = new WKTReader(new GeometryFactory(new PrecisionModel(1), 0));
    Geometry geometry = reader.read("MULTIPOINT (0 0, 10 0, 10 0)");
View Full Code Here

Examples of com.vividsolutions.jts.geom.LineString.equalsExact()

  public void test4() throws Exception {
    WKTReader reader = new WKTReader(new GeometryFactory(new PrecisionModel(1), 0));
    Geometry geometry = reader.read("MULTIPOINT (0 0, 10 0, 10 0)");
    LineString convexHull = (LineString) reader.read("LINESTRING (0 0, 10 0)");
    assertTrue(convexHull.equalsExact(geometry.convexHull()));
  }

  public void test5() throws Exception {
    WKTReader reader = new WKTReader(new GeometryFactory(new PrecisionModel(1), 0));
    Geometry geometry = reader.read("MULTIPOINT (0 0, 5 0, 10 0)");
View Full Code Here

Examples of com.vividsolutions.jts.geom.LineString.equalsExact()

  public void test5() throws Exception {
    WKTReader reader = new WKTReader(new GeometryFactory(new PrecisionModel(1), 0));
    Geometry geometry = reader.read("MULTIPOINT (0 0, 5 0, 10 0)");
    LineString convexHull = (LineString) reader.read("LINESTRING (0 0, 10 0)");
    assertTrue(convexHull.equalsExact(geometry.convexHull()));
  }

  public void test6() throws Exception {
    WKTReader reader = new WKTReader(new GeometryFactory(new PrecisionModel(1), 0));
    Geometry actualGeometry = reader.read("MULTIPOINT (0 0, 5 1, 10 0)").convexHull();
View Full Code Here

Examples of com.vividsolutions.jts.geom.LineString.equalsExact()

  public void test7() throws Exception {
    WKTReader reader = new WKTReader(new GeometryFactory(new PrecisionModel(1), 0));
    Geometry geometry = reader.read("MULTIPOINT (0 0, 0 0, 5 0, 5 0, 10 0, 10 0)");
    LineString convexHull = (LineString) reader.read("LINESTRING (0 0, 10 0)");
    assertTrue(convexHull.equalsExact(geometry.convexHull()));
  }



}
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.