|
CoherenceTM v3.3 Copyright© 2000-2007 by Oracle Corporation |
|||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||
java.lang.Objectcom.tangosol.util.Base
com.tangosol.io.AbstractReadBuffer
com.tangosol.io.AbstractByteArrayReadBuffer
com.tangosol.io.ByteArrayReadBuffer
public class ByteArrayReadBuffer
A ReadBuffer on top of a byte array.
| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from class com.tangosol.io.AbstractByteArrayReadBuffer |
|---|
AbstractByteArrayReadBuffer.ByteArrayBufferInput |
| Nested classes/interfaces inherited from class com.tangosol.io.AbstractReadBuffer |
|---|
AbstractReadBuffer.AbstractBufferInput |
| Nested classes/interfaces inherited from interface com.tangosol.io.ReadBuffer |
|---|
ReadBuffer.BufferInput |
| Field Summary |
|---|
| Fields inherited from class com.tangosol.io.AbstractByteArrayReadBuffer |
|---|
m_ab, m_cb, m_of |
| Fields inherited from class com.tangosol.io.AbstractReadBuffer |
|---|
NO_BINARY, NO_BYTES |
| Constructor Summary | |
|---|---|
protected |
ByteArrayReadBuffer()
Default constructor provided for subclasses. |
|
ByteArrayReadBuffer(byte[] ab)
Construct a ByteArrayReadBuffer object from a byte array. |
|
ByteArrayReadBuffer(byte[] ab,
int of,
int cb)
Construct a ByteArrayReadBuffer object from a portion of a byte array. |
|
ByteArrayReadBuffer(byte[] ab,
int of,
int cb,
boolean fCopy,
boolean fPrivate,
boolean fShallowClone)
Construct a ByteArrayReadBuffer object from a portion of a byte array. |
| Method Summary | |
|---|---|
Object |
clone()
Create a clone of this ByteArrayReadBuffer object. |
byte[] |
getRawByteArray()
Obtain the byte array that this ReadBuffer uses. |
int |
getRawOffset()
Determine the offset into the byte array returned from getRawByteArray() that this ReadBuffer uses. |
protected ReadBuffer |
instantiateReadBuffer(int of,
int cb)
Factory method: Instantiate a ReadBuffer for a portion of this ReadBuffer. |
protected boolean |
isByteArrayPrivate()
Determine if the underlying byte[] should be treated as private data. |
protected boolean |
isShallowCloneable()
Determine whether a clone can be made without cloning the byte array. |
String |
toString()
Provide a human-readable representation of the Binary object. |
| Methods inherited from class com.tangosol.io.AbstractByteArrayReadBuffer |
|---|
byteAt, copyBytes, instantiateBufferInput, length, resetRange, toBinary, toBinary, toByteArray |
| Methods inherited from class com.tangosol.io.AbstractReadBuffer |
|---|
checkBounds, equals, getBufferInput, getReadBuffer, toByteArray |
| Constructor Detail |
|---|
protected ByteArrayReadBuffer()
public ByteArrayReadBuffer(byte[] ab)
ab - an array of bytes
public ByteArrayReadBuffer(byte[] ab,
int of,
int cb)
ab - an array of bytesof - the offset into the byte arraycb - the number of bytes to extract
public ByteArrayReadBuffer(byte[] ab,
int of,
int cb,
boolean fCopy,
boolean fPrivate,
boolean fShallowClone)
ab - an array of bytesof - the offset into the byte arraycb - the number of bytes to extractfCopy - true to make a copy of the passed arrayfPrivate - true to treat the passed array as private datafShallowClone - true to allow cloning without copying the
underlying byte[]| Method Detail |
|---|
public byte[] getRawByteArray()
AbstractReadBuffer.toByteArray().
public int getRawOffset()
getRawByteArray() that this ReadBuffer uses. If the
underlying byte array is private, then this method will always
return zero because getRawByteArray() will always return
a copy of the portion of the byte array that this ReadBuffer
represents.
protected ReadBuffer instantiateReadBuffer(int of,
int cb)
instantiateReadBuffer in class AbstractReadBufferof - the beginning index, inclusivecb - the number of bytes to include in the resulting ReadBuffer
public Object clone()
clone in interface ReadBufferclone in class AbstractReadBufferpublic String toString()
protected boolean isByteArrayPrivate()
isByteArrayPrivate in class AbstractByteArrayReadBufferprotected boolean isShallowCloneable()
|
CoherenceTM v3.3 Copyright© 2000-2007 by Oracle Corporation |
|||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||