Class RangeAggregator.Range
- java.lang.Object
-
- org.elasticsearch.search.aggregations.bucket.range.RangeAggregator.Range
-
- All Implemented Interfaces:
Writeable,ToXContent,ToXContentObject
- Direct Known Subclasses:
GeoDistanceAggregationBuilder.Range
- Enclosing class:
- RangeAggregator
public static class RangeAggregator.Range extends java.lang.Object implements Writeable, ToXContentObject
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface org.elasticsearch.common.xcontent.ToXContent
ToXContent.DelegatingMapParams, ToXContent.MapParams, ToXContent.Params
-
Nested classes/interfaces inherited from interface org.elasticsearch.common.io.stream.Writeable
Writeable.Reader<V>, Writeable.Writer<V>
-
-
Field Summary
Fields Modifier and Type Field Description protected doublefromstatic ParseFieldFROM_FIELDprotected java.lang.StringfromAsStrprotected java.lang.Stringkeystatic ParseFieldKEY_FIELDprotected doubletostatic ParseFieldTO_FIELDprotected java.lang.StringtoAsStr-
Fields inherited from interface org.elasticsearch.common.xcontent.ToXContent
EMPTY_PARAMS
-
-
Constructor Summary
Constructors Constructor Description Range(java.lang.String key, java.lang.Double from, java.lang.Double to)Range(java.lang.String key, java.lang.Double from, java.lang.String fromAsStr, java.lang.Double to, java.lang.String toAsStr)Range(java.lang.String key, java.lang.String from, java.lang.String to)Range(StreamInput in)Read from a stream.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanequals(java.lang.Object obj)static RangeAggregator.RangefromXContent(XContentParser parser)doublegetFrom()java.lang.StringgetFromAsString()java.lang.StringgetKey()doublegetTo()java.lang.StringgetToAsString()inthashCode()java.lang.StringtoString()XContentBuildertoXContent(XContentBuilder builder, ToXContent.Params params)voidwriteTo(StreamOutput out)Write this into the StreamOutput.-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface org.elasticsearch.common.xcontent.ToXContentObject
isFragment
-
-
-
-
Field Detail
-
KEY_FIELD
public static final ParseField KEY_FIELD
-
FROM_FIELD
public static final ParseField FROM_FIELD
-
TO_FIELD
public static final ParseField TO_FIELD
-
key
protected final java.lang.String key
-
from
protected final double from
-
fromAsStr
protected final java.lang.String fromAsStr
-
to
protected final double to
-
toAsStr
protected final java.lang.String toAsStr
-
-
Constructor Detail
-
Range
public Range(java.lang.String key, java.lang.Double from, java.lang.Double to)
-
Range
public Range(java.lang.String key, java.lang.String from, java.lang.String to)
-
Range
public Range(StreamInput in) throws java.io.IOException
Read from a stream.- Throws:
java.io.IOException
-
Range
public Range(java.lang.String key, java.lang.Double from, java.lang.String fromAsStr, java.lang.Double to, java.lang.String toAsStr)
-
-
Method Detail
-
writeTo
public void writeTo(StreamOutput out) throws java.io.IOException
Description copied from interface:WriteableWrite this into the StreamOutput.
-
getFrom
public double getFrom()
-
getTo
public double getTo()
-
getFromAsString
public java.lang.String getFromAsString()
-
getToAsString
public java.lang.String getToAsString()
-
getKey
public java.lang.String getKey()
-
toString
public java.lang.String toString()
- Overrides:
toStringin classjava.lang.Object
-
fromXContent
public static RangeAggregator.Range fromXContent(XContentParser parser) throws java.io.IOException
- Throws:
java.io.IOException
-
toXContent
public XContentBuilder toXContent(XContentBuilder builder, ToXContent.Params params) throws java.io.IOException
- Specified by:
toXContentin interfaceToXContent- Throws:
java.io.IOException
-
hashCode
public int hashCode()
- Overrides:
hashCodein classjava.lang.Object
-
equals
public boolean equals(java.lang.Object obj)
- Overrides:
equalsin classjava.lang.Object
-
-