public interface IDataSegment
This interface defines all methods, which a class must to support, if it is a DataSegment.
| Modifier and Type | Method and Description |
|---|---|
int |
append(ByteBuffer src,
int len)
This method appends
len bytes from the given ByteBuffer at the end of the
data buffer of this instance. |
void |
clear()
Clears all made settings of this object.
|
int |
deserialize(ByteBuffer src,
int len)
Deprecated.
|
int |
getLength()
Returns the length, which is really used by the
dataBuffer. |
SettingsMap |
getSettings()
Returns a
SettingsMap instance of this IDataSegment instance. |
IDataSegmentIterator |
iterator()
Returns an iterator over the chunks of this data segment in proper
sequence.
|
int |
serialize(ByteBuffer dst,
int off)
Deprecated.
|
int |
setDataBuffer(ByteBuffer src,
int off,
int len)
Sets the data buffer to the given buffer
src. |
@Deprecated int deserialize(ByteBuffer src, int len)
len bytes from the given ByteBuffer.src - Source ByteBuffer object.len - The number of bytes to import from src.len.int append(ByteBuffer src, int len)
len bytes from the given ByteBuffer at the end of the
data buffer of this instance.src - Source ByteBuffer object.len - The number of bytes to append from src.@Deprecated int serialize(ByteBuffer dst, int off)
ByteBuffer object, which is padded to a
integer number of 4 byte words.dst - Destination ByteBuffer object.off - Start position in dst, where to serialize.IDataSegmentIterator iterator()
SettingsMap getSettings() throws InternetSCSIException
SettingsMap instance of this IDataSegment instance. This is only
useful with a TextParameterDataSegment instance.TextParameterDataSegment instance.InternetSCSIException - if any violation of the iSCSI Standard occurs.void clear()
int getLength()
dataBuffer.int setDataBuffer(ByteBuffer src, int off, int len)
src. Starting from
the position offset with length of len.src - The buffer to read from.off - The start offset to read from.len - The number of bytes to read.Copyright © 2013 University of Konstanz, Distributed Systems Group. All Rights Reserved.