add filter and global support

This commit is contained in:
kimchy 2010-08-01 17:08:44 +03:00
parent c5811eb060
commit e77d1d0147
1 changed files with 11 additions and 0 deletions

View File

@ -194,6 +194,7 @@ public class GeoDistanceFacetBuilder extends AbstractFacetBuilder {
}
builder.startObject(name);
builder.startObject(GeoDistanceFacetCollectorParser.NAME);
if (geohash != null) {
@ -235,6 +236,16 @@ public class GeoDistanceFacetBuilder extends AbstractFacetBuilder {
}
builder.endObject();
if (filter != null) {
builder.field("filter");
filter.toXContent(builder, params);
}
if (global != null) {
builder.field("global", global);
}
builder.endObject();
}