Examples of points()


Examples of org.elasticsearch.index.search.geo.GeoPolygonFilter.points()

        DeletionAwareConstantScoreQuery constantScoreQuery = (DeletionAwareConstantScoreQuery) parsedQuery;
        GeoPolygonFilter filter = (GeoPolygonFilter) constantScoreQuery.getFilter();
        assertThat(filter.fieldName(), equalTo("location"));
        assertThat(filter.points().length, equalTo(3));
        assertThat(filter.points()[0].lat, closeTo(40, 0.00001));
        assertThat(filter.points()[0].lon, closeTo(-70, 0.00001));
        assertThat(filter.points()[1].lat, closeTo(30, 0.00001));
        assertThat(filter.points()[1].lon, closeTo(-80, 0.00001));
        assertThat(filter.points()[2].lat, closeTo(20, 0.00001));
        assertThat(filter.points()[2].lon, closeTo(-90, 0.00001));
    }
View Full Code Here

Examples of org.elasticsearch.index.search.geo.GeoPolygonFilter.points()

        GeoPolygonFilter filter = (GeoPolygonFilter) constantScoreQuery.getFilter();
        assertThat(filter.fieldName(), equalTo("location"));
        assertThat(filter.points().length, equalTo(3));
        assertThat(filter.points()[0].lat, closeTo(40, 0.00001));
        assertThat(filter.points()[0].lon, closeTo(-70, 0.00001));
        assertThat(filter.points()[1].lat, closeTo(30, 0.00001));
        assertThat(filter.points()[1].lon, closeTo(-80, 0.00001));
        assertThat(filter.points()[2].lat, closeTo(20, 0.00001));
        assertThat(filter.points()[2].lon, closeTo(-90, 0.00001));
    }
View Full Code Here

Examples of org.elasticsearch.index.search.geo.GeoPolygonFilter.points()

        assertThat(filter.fieldName(), equalTo("location"));
        assertThat(filter.points().length, equalTo(3));
        assertThat(filter.points()[0].lat, closeTo(40, 0.00001));
        assertThat(filter.points()[0].lon, closeTo(-70, 0.00001));
        assertThat(filter.points()[1].lat, closeTo(30, 0.00001));
        assertThat(filter.points()[1].lon, closeTo(-80, 0.00001));
        assertThat(filter.points()[2].lat, closeTo(20, 0.00001));
        assertThat(filter.points()[2].lon, closeTo(-90, 0.00001));
    }

    @Test public void testGeoPolygonFilter3() throws IOException {
View Full Code Here

Examples of org.elasticsearch.index.search.geo.GeoPolygonFilter.points()

        assertThat(filter.points().length, equalTo(3));
        assertThat(filter.points()[0].lat, closeTo(40, 0.00001));
        assertThat(filter.points()[0].lon, closeTo(-70, 0.00001));
        assertThat(filter.points()[1].lat, closeTo(30, 0.00001));
        assertThat(filter.points()[1].lon, closeTo(-80, 0.00001));
        assertThat(filter.points()[2].lat, closeTo(20, 0.00001));
        assertThat(filter.points()[2].lon, closeTo(-90, 0.00001));
    }

    @Test public void testGeoPolygonFilter3() throws IOException {
        IndexQueryParserService queryParser = queryParser();
View Full Code Here

Examples of org.elasticsearch.index.search.geo.GeoPolygonFilter.points()

        assertThat(filter.points()[0].lat, closeTo(40, 0.00001));
        assertThat(filter.points()[0].lon, closeTo(-70, 0.00001));
        assertThat(filter.points()[1].lat, closeTo(30, 0.00001));
        assertThat(filter.points()[1].lon, closeTo(-80, 0.00001));
        assertThat(filter.points()[2].lat, closeTo(20, 0.00001));
        assertThat(filter.points()[2].lon, closeTo(-90, 0.00001));
    }

    @Test public void testGeoPolygonFilter3() throws IOException {
        IndexQueryParserService queryParser = queryParser();
        String query = copyToStringFromClasspath("/org/elasticsearch/index/query/geo_polygon3.json");
View Full Code Here

Examples of org.elasticsearch.index.search.geo.GeoPolygonFilter.points()

        Query parsedQuery = queryParser.parse(query).query();
        assertThat(parsedQuery, instanceOf(DeletionAwareConstantScoreQuery.class));
        DeletionAwareConstantScoreQuery constantScoreQuery = (DeletionAwareConstantScoreQuery) parsedQuery;
        GeoPolygonFilter filter = (GeoPolygonFilter) constantScoreQuery.getFilter();
        assertThat(filter.fieldName(), equalTo("location"));
        assertThat(filter.points().length, equalTo(3));
        assertThat(filter.points()[0].lat, closeTo(40, 0.00001));
        assertThat(filter.points()[0].lon, closeTo(-70, 0.00001));
        assertThat(filter.points()[1].lat, closeTo(30, 0.00001));
        assertThat(filter.points()[1].lon, closeTo(-80, 0.00001));
        assertThat(filter.points()[2].lat, closeTo(20, 0.00001));
View Full Code Here

Examples of org.elasticsearch.index.search.geo.GeoPolygonFilter.points()

        assertThat(parsedQuery, instanceOf(DeletionAwareConstantScoreQuery.class));
        DeletionAwareConstantScoreQuery constantScoreQuery = (DeletionAwareConstantScoreQuery) parsedQuery;
        GeoPolygonFilter filter = (GeoPolygonFilter) constantScoreQuery.getFilter();
        assertThat(filter.fieldName(), equalTo("location"));
        assertThat(filter.points().length, equalTo(3));
        assertThat(filter.points()[0].lat, closeTo(40, 0.00001));
        assertThat(filter.points()[0].lon, closeTo(-70, 0.00001));
        assertThat(filter.points()[1].lat, closeTo(30, 0.00001));
        assertThat(filter.points()[1].lon, closeTo(-80, 0.00001));
        assertThat(filter.points()[2].lat, closeTo(20, 0.00001));
        assertThat(filter.points()[2].lon, closeTo(-90, 0.00001));
View Full Code Here

Examples of org.elasticsearch.index.search.geo.GeoPolygonFilter.points()

        DeletionAwareConstantScoreQuery constantScoreQuery = (DeletionAwareConstantScoreQuery) parsedQuery;
        GeoPolygonFilter filter = (GeoPolygonFilter) constantScoreQuery.getFilter();
        assertThat(filter.fieldName(), equalTo("location"));
        assertThat(filter.points().length, equalTo(3));
        assertThat(filter.points()[0].lat, closeTo(40, 0.00001));
        assertThat(filter.points()[0].lon, closeTo(-70, 0.00001));
        assertThat(filter.points()[1].lat, closeTo(30, 0.00001));
        assertThat(filter.points()[1].lon, closeTo(-80, 0.00001));
        assertThat(filter.points()[2].lat, closeTo(20, 0.00001));
        assertThat(filter.points()[2].lon, closeTo(-90, 0.00001));
    }
View Full Code Here

Examples of org.elasticsearch.index.search.geo.GeoPolygonFilter.points()

        GeoPolygonFilter filter = (GeoPolygonFilter) constantScoreQuery.getFilter();
        assertThat(filter.fieldName(), equalTo("location"));
        assertThat(filter.points().length, equalTo(3));
        assertThat(filter.points()[0].lat, closeTo(40, 0.00001));
        assertThat(filter.points()[0].lon, closeTo(-70, 0.00001));
        assertThat(filter.points()[1].lat, closeTo(30, 0.00001));
        assertThat(filter.points()[1].lon, closeTo(-80, 0.00001));
        assertThat(filter.points()[2].lat, closeTo(20, 0.00001));
        assertThat(filter.points()[2].lon, closeTo(-90, 0.00001));
    }
View Full Code Here

Examples of org.elasticsearch.index.search.geo.GeoPolygonFilter.points()

        assertThat(filter.fieldName(), equalTo("location"));
        assertThat(filter.points().length, equalTo(3));
        assertThat(filter.points()[0].lat, closeTo(40, 0.00001));
        assertThat(filter.points()[0].lon, closeTo(-70, 0.00001));
        assertThat(filter.points()[1].lat, closeTo(30, 0.00001));
        assertThat(filter.points()[1].lon, closeTo(-80, 0.00001));
        assertThat(filter.points()[2].lat, closeTo(20, 0.00001));
        assertThat(filter.points()[2].lon, closeTo(-90, 0.00001));
    }

    @Test public void testGeoPolygonFilter4() throws IOException {
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.