org.jlab.coda.jevio
Class EvioNode

java.lang.Object
  extended by org.jlab.coda.jevio.EvioNode

public final class EvioNode
extends java.lang.Object

This class is used to store relevant info about an evio container (bank, segment, or tag segment), without having to de-serialize it into many objects and arrays.

Author:
timmer Date: 11/13/12 Time: 11:06 AM

Constructor Summary
EvioNode()
           
 
Method Summary
 int getDataLength()
          Get the length of this evio structure's data only (no header words) in 32-bit words.
 int getDataPosition()
          Get the file/buffer position of this evio structure's data.
 int getDataType()
          Get the evio type of the data this evio structure contains.
 DataType getDataTypeObj()
          Get the evio type of the data this evio structure contains as an object.
 int getEventNumber()
          If this object represents an event (top-level, evio bank), then returns its number (place in file or buffer) starting with 1.
 int getLength()
          Get the length of this evio structure (not including length word itself) in 32-bit words.
 int getNum()
          Get the num of this evio structure.
 int getPad()
          Get the padding of this evio structure.
 int getPosition()
          Get the file/buffer position of this evio structure.
 int getTag()
          Get the tag of this evio structure.
 int getType()
          Get the evio type of this evio structure, not what it contains.
 boolean isEvent()
          Does this object represent an event?
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

EvioNode

public EvioNode()
Method Detail

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object

getLength

public int getLength()
Get the length of this evio structure (not including length word itself) in 32-bit words.

Returns:
length of this evio structure (not including length word itself) in 32-bit words

getTag

public int getTag()
Get the tag of this evio structure.

Returns:
tag of this evio structure

getNum

public int getNum()
Get the num of this evio structure. Will be zero for tagsegments.

Returns:
num of this evio structure

getPad

public int getPad()
Get the padding of this evio structure. Will be zero for segments and tagsegments.

Returns:
padding of this evio structure

getPosition

public int getPosition()
Get the file/buffer position of this evio structure.

Returns:
file/buffer position of this evio structure

getType

public int getType()
Get the evio type of this evio structure, not what it contains. Call DataType.getDataType(int) on the returned value to get the object representation.

Returns:
evio type of this evio structure, not what it contains

getDataLength

public int getDataLength()
Get the length of this evio structure's data only (no header words) in 32-bit words.

Returns:
length of this evio structure's data only (no header words) in 32-bit words.

getDataPosition

public int getDataPosition()
Get the file/buffer position of this evio structure's data.

Returns:
file/buffer position of this evio structure's data

getDataType

public int getDataType()
Get the evio type of the data this evio structure contains. Call DataType.getDataType(int) on the returned value to get the object representation.

Returns:
evio type of the data this evio structure contains

getDataTypeObj

public DataType getDataTypeObj()
Get the evio type of the data this evio structure contains as an object.

Returns:
evio type of the data this evio structure contains as an object.

getEventNumber

public int getEventNumber()
If this object represents an event (top-level, evio bank), then returns its number (place in file or buffer) starting with 1. If not, return -1.

Returns:
event number if representing an event, else -1

isEvent

public boolean isEvent()
Does this object represent an event?

Returns:
true if this object represents and event, else false