FilterFactory2 ff = CommonFactoryFinder.getFilterFactory2(null);
// should match only "r1"
GeometryFactory gf = new GeometryFactory();
PackedCoordinateSequenceFactory sf = new PackedCoordinateSequenceFactory();
LineString ls = gf.createLinearRing(sf.create(new double[] { 2, 1, 2, 3, 0, 3, 2, 1}, 2));
Intersects is = ff.intersects(ff.property(aname("geom")), ff.literal(ls));
FeatureCollection features = dataStore.getFeatureSource(tname("road")).getFeatures(is);
checkSingleResult(features, "r1");
}