public class GeoShapeFilterParser extends Object implements FilterParser
FilterParser
for filtering Documents based on Shape
s.
Only those fields mapped using GeoShapeFieldMapper
can be filtered
using this parser.
Format supported:
"field" : { "relation" : "intersects", "shape" : { "type" : "polygon", "coordinates" : [ [ [100.0, 0.0], [101.0, 0.0], [101.0, 1.0], [100.0, 1.0], [100.0, 0.0] ] ] } }
Modifier and Type | Class and Description |
---|---|
static class |
GeoShapeFilterParser.DEFAULTS |
Constructor and Description |
---|
GeoShapeFilterParser() |
Modifier and Type | Method and Description |
---|---|
String[] |
names()
The names this filter is registered under.
|
org.apache.lucene.search.Filter |
parse(QueryParseContext parseContext)
Parses the into a filter from the current parser location.
|
void |
setFetchService(ShapeFetchService fetchService) |
public static final String NAME
public String[] names()
FilterParser
names
in interface FilterParser
public org.apache.lucene.search.Filter parse(QueryParseContext parseContext) throws IOException, QueryParsingException
FilterParser
parse
in interface FilterParser
IOException
QueryParsingException
@Inject(optional=true) public void setFetchService(@Nullable ShapeFetchService fetchService)
Copyright © 2009–2015. All rights reserved.