@Deprecated
public class Record
extends java.lang.Object
RECORD HEADER STRUCTURE ( 48 bytes, 12 integers (32 bit) )
+----------------------------------+
| ID word (0x43455248) |
+----------------------------------+
+ Record Length |
+----------------------------------+
+ Data Length Uncompressed |
+------+---------------------------+
+ CT | Data Length Compressed | // CT = compression type (8 bits)
+------+---------------------------+
+ Number of events in the record |
+----------------------------------+
+ Record Header length |
+----------------------------------+
+ Index Description Length |
+----------------------------------+
+ Reserved |
+----------------------------------+
+ UID FIRST LOW |
+----------------------------------+
+ UID FIRST HIGH |
+----------------------------------+
+ UID SECOND LOW |
+----------------------------------+
+ UID SECOND HIGH |
+----------------------------------+
NOTE: THIS CLASS IS NOT USED IN EVIO!
HIPO Record Class that creates records of data buffers (agnostic to what the data represents).Constructor and Description |
---|
Record()
Deprecated.
|
Modifier and Type | Method and Description |
---|---|
boolean |
addEvent(byte[] buffer)
Deprecated.
add new byte[] array into the record.
|
java.nio.ByteBuffer |
build()
Deprecated.
Builds a byte[] array of the record.
|
void |
build(java.nio.ByteBuffer userHeader)
Deprecated.
|
static int |
decodeCompressionLength(int word)
Deprecated.
|
static int |
decodeCompressionType(int word)
Deprecated.
|
static int |
encodeCompressionWord(int compression,
int length)
Deprecated.
|
CompressionType |
getCompressionType()
Deprecated.
Gets the compression type for the record.
|
int |
getEntries()
Deprecated.
returns number of arrays in the record.
|
byte[] |
getEvent(int index)
Deprecated.
returns a copy of the event with index = index.
|
byte[] |
getEventNoCopy(int index)
Deprecated.
Returns a reference to the byte[] array
stored at position index.
|
static Record |
initBinary(byte[] buffer)
Deprecated.
|
void |
reset()
Deprecated.
Resets the content of the record.
|
Record |
setCompressionType(CompressionType compression)
Deprecated.
Sets compression type for the record.
|
Record |
setCompressionType(int compression)
Deprecated.
Sets compression type for the record.
|
void |
setMaximumCapacity(int max_capacity)
Deprecated.
Sets the maximum capacity of the record.
|
void |
show()
Deprecated.
|
public Record setCompressionType(CompressionType compression)
compression
- compression type as enum.public Record setCompressionType(int compression)
compression
- compression type as int.public CompressionType getCompressionType()
public void setMaximumCapacity(int max_capacity)
max_capacity
- maximum capacity of the record.public boolean addEvent(byte[] buffer)
buffer
- array to add to the recordpublic byte[] getEventNoCopy(int index)
index
- array positionpublic byte[] getEvent(int index)
index
- order in the arraypublic void build(java.nio.ByteBuffer userHeader)
public java.nio.ByteBuffer build()
public void reset()
public int getEntries()
public static int encodeCompressionWord(int compression, int length)
public static int decodeCompressionType(int word)
public static int decodeCompressionLength(int word)
public static Record initBinary(byte[] buffer)
public void show()