@@ -30,6 +30,12 @@ public interface IHistogramAggregator : IBucketAggregator
30
30
31
31
[ JsonProperty ( "extended_bounds" ) ]
32
32
IDictionary < string , object > ExtendedBounds { get ; set ; }
33
+
34
+ [ JsonProperty ( "pre_offset" ) ]
35
+ long ? PreOffset { get ; set ; }
36
+
37
+ [ JsonProperty ( "post_offset" ) ]
38
+ long ? PostOffset { get ; set ; }
33
39
}
34
40
35
41
public class HistogramAggregator : BucketAggregator , IHistogramAggregator
@@ -41,6 +47,8 @@ public class HistogramAggregator : BucketAggregator, IHistogramAggregator
41
47
public int ? MinimumDocumentCount { get ; set ; }
42
48
public IDictionary < string , string > Order { get ; set ; }
43
49
public IDictionary < string , object > ExtendedBounds { get ; set ; }
50
+ public long ? PreOffset { get ; set ; }
51
+ public long ? PostOffset { get ; set ; }
44
52
}
45
53
46
54
public class HistogramAggregationDescriptor < T > : BucketAggregationBaseDescriptor < HistogramAggregationDescriptor < T > , T > , IHistogramAggregator
@@ -62,6 +70,10 @@ public class HistogramAggregationDescriptor<T> : BucketAggregationBaseDescriptor
62
70
63
71
IDictionary < string , object > IHistogramAggregator . ExtendedBounds { get ; set ; }
64
72
73
+ long ? IHistogramAggregator . PreOffset { get ; set ; }
74
+
75
+ long ? IHistogramAggregator . PostOffset { get ; set ; }
76
+
65
77
public HistogramAggregationDescriptor < T > Field ( string field )
66
78
{
67
79
Self . Field = field ;
@@ -116,5 +128,16 @@ public HistogramAggregationDescriptor<T> ExtendedBounds(double min, double max)
116
128
return this ;
117
129
}
118
130
131
+ public HistogramAggregationDescriptor < T > PreOffset ( long preOffset )
132
+ {
133
+ Self . PreOffset = preOffset ;
134
+ return this ;
135
+ }
136
+
137
+ public HistogramAggregationDescriptor < T > PostOffset ( long postOffset )
138
+ {
139
+ Self . PostOffset = postOffset ;
140
+ return this ;
141
+ }
119
142
}
120
143
}
0 commit comments