protected class DetectorStreamBufferImpl.CurrentByteArray extends AbstractByteArray
ByteArray
.Modifier | Constructor and Description |
---|---|
protected |
CurrentByteArray() |
Modifier and Type | Method and Description |
---|---|
byte[] |
getBytes()
This method gets the underlying byte-array of this buffer.
|
int |
getBytesAvailable()
This method gets the number of bytes available in this array.
|
int |
getCurrentIndex()
This method gets the offset in the
byte array . |
int |
getMaximumIndex()
This method gets the maximum index in the
buffer . |
int |
getMinimumIndex()
This method gets the minimum index where to start reading in the
byte array . |
checkSubArray, createSubArray
public byte[] getBytes()
ByteArray
minimumIndex
(typically currentIndex
to
maximumIndex
. Only the creator of this object may modify this array.ByteArray.getCurrentIndex()
,
ByteArray.getMaximumIndex()
public int getBytesAvailable()
ByteArray
ByteArray.getMaximumIndex()
- ByteArray.getCurrentIndex()
+ 1
.getBytesAvailable
in interface ByteArray
getBytesAvailable
in interface ByteProvider
getBytesAvailable
in class AbstractByteArray
public int getMinimumIndex()
ByteArray
byte array
. It will be in the
range from 0
to maximumIndex
+ 1
. This is typically the same as the
current index
. However a mutable variant
of a ByteArray
may allow to modify (increase) the current-index
. The value
returned by this method can NOT be modified.public int getCurrentIndex()
ByteArray
byte array
.public int getMaximumIndex()
ByteArray
buffer
. It will be in the range from -1
to
ByteArray.getBytes()
.length - 1
. -1
) indicates that the buffer
does NOT contain data (payload).Copyright © 2001–2016 mmm-Team. All rights reserved.