|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface Chunk
A chunk is a sequence of bytes at a particular logical offset in a stream, and containing one or more "records". Chunks have various metadata, such as source, format, and pointers to record boundaries within the chunk.
Method Summary | |
---|---|
void |
addTag(String tag)
Add tag. |
String |
getApplication()
|
byte[] |
getData()
|
String |
getDataType()
|
Adaptor |
getInitiator()
Retrieve a reference to the adaptor that sent this event. |
int[] |
getRecordOffsets()
get/set the end offsets of records in the buffer. |
long |
getSeqID()
|
int |
getSerializedSizeEstimate()
Estimate the size of this Chunk on the wire, assuming each char of metadata takes two bytes to serialize. |
String |
getSource()
|
String |
getStreamName()
Get the name of the stream that this Chunk is a chunk of |
String |
getTag(String tagName)
Returns the value of a single tag, assuming tags are of the form tagname="val" |
String |
getTags()
|
void |
setApplication(String a)
|
void |
setData(byte[] logEvent)
|
void |
setDataType(String t)
|
void |
setRecordOffsets(int[] offsets)
|
void |
setSeqID(long l)
|
void |
setSource(String logSource)
|
void |
setStreamName(String streamName)
|
void |
write(DataOutput data)
|
Method Detail |
---|
String getSource()
void setSource(String logSource)
String getStreamName()
void setStreamName(String streamName)
String getApplication()
void setApplication(String a)
String getDataType()
void setDataType(String t)
byte[] getData()
void setData(byte[] logEvent)
logEvent
- the user data in the chunkint[] getRecordOffsets()
void setRecordOffsets(int[] offsets)
long getSeqID()
void setSeqID(long l)
Adaptor getInitiator()
int getSerializedSizeEstimate()
String getTags()
void addTag(String tag)
String getTag(String tagName)
tagName
- the tag to return
void write(DataOutput data) throws IOException
IOException
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |