hep.aida.ref.tuple
Class Tuple

java.lang.Object
  extended by hep.aida.ref.event.AIDAObservable
      extended by hep.aida.ref.ManagedObject
          extended by hep.aida.ref.tuple.AbstractTuple
              extended by hep.aida.ref.tuple.Tuple
All Implemented Interfaces:
hep.aida.dev.IDevManagedObject, IManagedObject, ITuple, Connectable, FTuple

public class Tuple
extends AbstractTuple


Nested Class Summary
static class Tuple.TupleColumnFactory
           
 
Nested classes/interfaces inherited from class hep.aida.ref.tuple.AbstractTuple
AbstractTuple.AbstractTupleColumnFactory
 
Field Summary
 
Fields inherited from interface hep.aida.ref.tuple.FTuple
ROWS_UNKNOWN
 
Constructor Summary
Tuple(String name, String title, String[] columnName, Class[] columnType, String options)
           
Tuple(String name, String title, String columnsString, String options)
           
 
Method Summary
 void addRow()
          Add the current row to the ITuple.
 IBaseTupleColumn column(int column)
          Return a IBaseTupleColumn knowing its index.
 IBaseTupleColumn column(String name)
          Return a IBaseTupleColumn knowing its name.
 String columnDefaultString(int column)
           
 double columnMax(int column)
          Get the maximum value of a given column (if it can be converted to a double).
 double columnMean(int column)
          Get the mean value of a given column (if it can be converted to a double).
 double columnMin(int column)
          Get the minimum value of a given column (if it can be converted to a double).
 String columnName(int column)
          Get the name of a column from its index.
 double columnRms(int column)
          Get the RMS of a given column (if it can be converted to a double).
 int columns()
          Get the number of columns in the ITuple
 Class columnType(int column)
          Get the type of a give column.
 void columnValue(int column, FTupleCursor cursor, org.freehep.util.Value value)
           
 void columnValue(int column, org.freehep.util.Value value)
           
 void fill(int column, org.freehep.util.Value value)
           
 int findColumn(String name)
          Get the index within the ITuple of a given column.
 ITuple findTuple(int index)
          Get Folder at the current cursor position.
 boolean isInMemory()
           
 boolean providesColumnDefaultValues()
           
 void reset()
          Reset the ITuple.
 void resetRow()
          Clear the current(not yet added) row.
 int rows()
          Get the number of rows currently filled in the ITuple.
 boolean supportsMultipleCursors()
           
 boolean supportsRandomAccess()
           
 
Methods inherited from class hep.aida.ref.tuple.AbstractTuple
annotation, columnByIndex, columnByName, columnDefaultValue, columnNames, columnTypes, cursor, evaluateMax, evaluateMax, evaluateMin, evaluateMin, fill, fill, fill, fill, fill, fill, fill, fill, fill, fill, fill, fill, getBoolean, getByte, getChar, getDouble, getFloat, getInt, getLong, getObject, getOptions, getRow, getShort, getString, getTuple, newInternalCursor, next, project, project, project, project, project, project, project, project, project, project, project, project, project, project, project, project, project, project, project, project, project, project, project, project, project, project, project, project, project, project, project, project, setAnnotation, setRow, setTitle, skip, start, title, tuple
 
Methods inherited from class hep.aida.ref.ManagedObject
isFillable, name, setFillable, setName, type, typeForClass
 
Methods inherited from class hep.aida.ref.event.AIDAObservable
addListener, isConnected, removeAllListeners, removeListener, setConnected, setValid, setValidForAll
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface hep.aida.ref.tuple.FTuple
name
 
Methods inherited from interface hep.aida.ref.event.Connectable
isConnected, setConnected
 

Constructor Detail

Tuple

public Tuple(String name,
             String title,
             String[] columnName,
             Class[] columnType,
             String options)

Tuple

public Tuple(String name,
             String title,
             String columnsString,
             String options)
Method Detail

columnDefaultString

public String columnDefaultString(int column)
Specified by:
columnDefaultString in class AbstractTuple

providesColumnDefaultValues

public boolean providesColumnDefaultValues()
Overrides:
providesColumnDefaultValues in class AbstractTuple

findTuple

public ITuple findTuple(int index)
Get Folder at the current cursor position.

Specified by:
findTuple in interface ITuple
Specified by:
findTuple in class AbstractTuple
Parameters:
index - The column's index of the Folder.
Returns:
The folder.

fill

public void fill(int column,
                 org.freehep.util.Value value)
Specified by:
fill in class AbstractTuple

columnValue

public void columnValue(int column,
                        FTupleCursor cursor,
                        org.freehep.util.Value value)
Specified by:
columnValue in interface FTuple
Overrides:
columnValue in class AbstractTuple

columnValue

public void columnValue(int column,
                        org.freehep.util.Value value)
Specified by:
columnValue in class AbstractTuple

isInMemory

public boolean isInMemory()
Specified by:
isInMemory in interface FTuple
Overrides:
isInMemory in class AbstractTuple

supportsMultipleCursors

public boolean supportsMultipleCursors()
Specified by:
supportsMultipleCursors in interface FTuple
Overrides:
supportsMultipleCursors in class AbstractTuple

supportsRandomAccess

public boolean supportsRandomAccess()
Specified by:
supportsRandomAccess in interface FTuple
Overrides:
supportsRandomAccess in class AbstractTuple

addRow

public void addRow()
Description copied from interface: ITuple
Add the current row to the ITuple. This method should be called after fill has been called for the columns; unfilled columns will be filled with their default value.

Specified by:
addRow in interface ITuple
Specified by:
addRow in class AbstractTuple

resetRow

public void resetRow()
Description copied from interface: ITuple
Clear the current(not yet added) row.

Specified by:
resetRow in interface ITuple
Specified by:
resetRow in class AbstractTuple

reset

public void reset()
Description copied from interface: ITuple
Reset the ITuple. All the rows are reset. The ITuple is as just created.

Specified by:
reset in interface ITuple
Specified by:
reset in class AbstractTuple

rows

public int rows()
Description copied from interface: ITuple
Get the number of rows currently filled in the ITuple.

Specified by:
rows in interface ITuple
Specified by:
rows in interface FTuple
Specified by:
rows in class AbstractTuple
Returns:
The number of rows. -1 if empty or if it cannot be determined.

findColumn

public int findColumn(String name)
Description copied from interface: ITuple
Get the index within the ITuple of a given column.

Specified by:
findColumn in interface ITuple
Specified by:
findColumn in class AbstractTuple
Parameters:
name - The colum's name.
Returns:
The corresponding column's index. Note: in C++ -1 may be returned if the column does not exist.

columnName

public String columnName(int column)
Description copied from interface: ITuple
Get the name of a column from its index.

Specified by:
columnName in interface ITuple
Specified by:
columnName in interface FTuple
Specified by:
columnName in class AbstractTuple
Parameters:
column - The column's index.
Returns:
The column's name.

columnType

public Class columnType(int column)
Description copied from interface: ITuple
Get the type of a give column.

Specified by:
columnType in interface ITuple
Specified by:
columnType in interface FTuple
Specified by:
columnType in class AbstractTuple
Parameters:
column - The column's index.
Returns:
The column's Class.

columnMin

public double columnMin(int column)
Description copied from interface: ITuple
Get the minimum value of a given column (if it can be converted to a double).

Specified by:
columnMin in interface ITuple
Specified by:
columnMin in class AbstractTuple
Parameters:
column - The column's index.
Returns:
The column's minimum value. In Java Double.NaN might be returned.

columnMax

public double columnMax(int column)
Description copied from interface: ITuple
Get the maximum value of a given column (if it can be converted to a double).

Specified by:
columnMax in interface ITuple
Specified by:
columnMax in class AbstractTuple
Parameters:
column - The column's index.
Returns:
The column's maximum value. In Java Double.NaN might be returned.

columnMean

public double columnMean(int column)
Description copied from interface: ITuple
Get the mean value of a given column (if it can be converted to a double).

Specified by:
columnMean in interface ITuple
Specified by:
columnMean in class AbstractTuple
Parameters:
column - The column's index.
Returns:
The column's mean value. In Java Double.NaN might be returned.

columnRms

public double columnRms(int column)
Description copied from interface: ITuple
Get the RMS of a given column (if it can be converted to a double).

Specified by:
columnRms in interface ITuple
Specified by:
columnRms in class AbstractTuple
Parameters:
column - The column's index.
Returns:
The column's RMS. In Java Double.NaN might be returned.

columns

public int columns()
Description copied from interface: ITuple
Get the number of columns in the ITuple

Specified by:
columns in interface ITuple
Specified by:
columns in interface FTuple
Specified by:
columns in class AbstractTuple
Returns:
The number of columns.

column

public IBaseTupleColumn column(int column)
Description copied from interface: ITuple
Return a IBaseTupleColumn knowing its index.

Specified by:
column in interface ITuple
Overrides:
column in class AbstractTuple
Parameters:
column - The column's index within the ITuple.
Returns:
The IBaseTupleColumn. In C++, return 0 if not found.

column

public IBaseTupleColumn column(String name)
Description copied from interface: ITuple
Return a IBaseTupleColumn knowing its name.

Specified by:
column in interface ITuple
Overrides:
column in class AbstractTuple
Parameters:
name - The colum's name.
Returns:
The IBaseTupleColumn. In C++, return 0 if not found.


jHepWork 3.2 © jWork.org