Package org.elasticsearch.common.bytes
Class ZeroBytesReference
java.lang.Object
org.elasticsearch.common.bytes.AbstractBytesReference
org.elasticsearch.common.bytes.ZeroBytesReference
- All Implemented Interfaces:
Comparable<BytesReference>
,BytesReference
,org.elasticsearch.xcontent.ToXContent
,org.elasticsearch.xcontent.ToXContentFragment
A
BytesReference
of the given length which contains all zeroes.-
Nested Class Summary
Nested classes/interfaces inherited from interface org.elasticsearch.xcontent.ToXContent
org.elasticsearch.xcontent.ToXContent.DelegatingMapParams, org.elasticsearch.xcontent.ToXContent.MapParams, org.elasticsearch.xcontent.ToXContent.Params
-
Field Summary
Fields inherited from class org.elasticsearch.common.bytes.AbstractBytesReference
length
Fields inherited from interface org.elasticsearch.xcontent.ToXContent
EMPTY, EMPTY_PARAMS
-
Constructor Summary
Constructors -
Method Summary
Methods inherited from class org.elasticsearch.common.bytes.AbstractBytesReference
compareTo, equals, getDoubleLE, getInt, getIntLE, getLongLE, hashCode, length, streamInput, toXContent, utf8ToString, writeTo
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface org.elasticsearch.common.bytes.BytesReference
array, arrayOffset, hasArray
Methods inherited from interface org.elasticsearch.xcontent.ToXContentFragment
isFragment
-
Constructor Details
-
ZeroBytesReference
public ZeroBytesReference(int length)
-
-
Method Details
-
indexOf
public int indexOf(byte marker, int from) - Specified by:
indexOf
in interfaceBytesReference
- Overrides:
indexOf
in classAbstractBytesReference
-
get
public byte get(int index) -
slice
-
ramBytesUsed
public long ramBytesUsed() -
toBytesRef
public org.apache.lucene.util.BytesRef toBytesRef() -
iterator
public org.apache.lucene.util.BytesRefIterator iterator()
-