| The Gaudi Framework v27r1

- Main Page
- Related Pages
- Modules
- Namespaces
- Classes
- Files

- Class List
- Class Index
- Class Hierarchy
- Class Members

Public Member Functions | Protected Member Functions | List of all members
NTuple::Tuple Class Reference

Abstract base class which allows the user to interact with the actual N tuple implementation. More...

`#include <GaudiKernel/NTuple.h>`

Inheritance diagram for NTuple::Tuple:
[legend]
Collaboration diagram for NTuple::Tuple:
[legend]

## Public Member Functions
| ~Tuple () override=default
| Standard destructor. More...
template<class TYPE >
StatusCode | item (const std::string &name, Item< TYPE > &result)
| Locate a scalar Item of data to the N tuple type safe. More...
template<class TYPE >
StatusCode | item (const std::string &name, const Item< TYPE > &result) const
| Locate a scalar Item of data to the N tuple type safe (CONST) More...
template<class TYPE >
StatusCode | item (const std::string &name, Array< TYPE > &result)
| Locate a Array of data to the N tuple type safe. More...
template<class TYPE >
StatusCode | item (const std::string &name, const Array< TYPE > &result) const
| Locate a Array of data to the N tuple type safe (CONST) More...
template<class TYPE >
StatusCode | item (const std::string &name, Matrix< TYPE > &result)
| Locate a Matrix of data to the N tuple type safe. More...
template<class TYPE >
StatusCode | item (const std::string &name, const Matrix< TYPE > &result) const
| Locate a Matrix of data to the N tuple type safe (CONST) More...
template<class TYPE >
StatusCode | addItem (const std::string &name, Item< TYPE > &itm)
| Add a scalar data item a N tuple. More...
template<class TYPE >
StatusCode | addItem (const std::string &name, Item< TYPE * > &itm)
| Add an simple object item to an N tuple. More...
StatusCode | addItem (const std::string &name, Item< IOpaqueAddress * > &itm)
| Add an address object item to an N tuple: specialized call. More...
template<class TYPE , class RANGE >
StatusCode | addItem (const std::string &name, Item< TYPE > &itm, const RANGE low, const RANGE high)
| Add a scalar data item a N tuple with a range. More...
template<class TYPE >
StatusCode | addItem (const std::string &name, long dim, Array< TYPE > &array)
| Add an fixed-size Array of data to a column wise N tuple. More...
template<class TYPE , class RANGE >
StatusCode | addItem (const std::string &name, long dim, Array< TYPE > &array, const RANGE low, const RANGE high)
| Add an fixed-size Array of data to a column wise N tuple with a range. More...
template<class TYPE , class INDEX , class RANGE >
StatusCode | addItem (const std::string &name, Item< INDEX > &index, Array< TYPE > &array, const RANGE low, const RANGE high)
| Add an indexed Array of data to a column wise N tuple with a range. More...
template<class TYPE , class INDEX , class RANGE >
StatusCode | addIndexedItem (const std::string &name, Item< INDEX > &index, Array< TYPE > &array, const RANGE low, const RANGE high)
| Add an indexed Array of data to a column wise N tuple with a range. More...
template<class TYPE , class INDEX >
StatusCode | addItem (const std::string &name, Item< INDEX > &index, Array< TYPE > &array)
| Add an indexed Array of data to a column wise N tuple. More...
template<class TYPE , class INDEX >
StatusCode | addIndexedItem (const std::string &name, Item< INDEX > &index, Array< TYPE > &array)
| Add an indexed Array of data to a column wise N tuple. More...
template<class TYPE >
StatusCode | addItem (const std::string &name, long cols, long rows, Matrix< TYPE > &matrix)
| Add an fixed size Matrix of data to a column wise N tuple. More...
template<class TYPE , class RANGE >
StatusCode | addItem (const std::string &name, long cols, long rows, Matrix< TYPE > &result, const RANGE low, const RANGE high)
| Add an fixed size Matrix of data to a column wise N tuple. More...
template<class TYPE , class INDEX >
StatusCode | addItem (const std::string &name, Item< INDEX > &index, Matrix< TYPE > &matrix, long rows)
| Add an variable size Matrix of data to a column wise N tuple. More...
template<class TYPE , class INDEX >
StatusCode | addIndexedItem (const std::string &name, Item< INDEX > &col_index, long rows, Matrix< TYPE > &matrix)
| Add an variable size Matrix of data to a column wise N tuple. More...
template<class TYPE , class INDEX , class RANGE >
StatusCode | addItem (const std::string &name, Item< INDEX > &index, Matrix< TYPE > &matrix, long rows, const RANGE low, const RANGE high)
| Add an variable size Matrix of data to a column wise N tuple. More...
template<class TYPE , class INDEX , class RANGE >
StatusCode | addIndexedItem (const std::string &name, Item< INDEX > &index, long rows, Matrix< TYPE > &matrix, const RANGE low, const RANGE high)
| Add an variable size Matrix of data to a column wise N tuple. More...
Public Member Functions inherited from DataObject
| DataObject ()
| Standard Constructor. More...
| DataObject (const DataObject &rhs)
| Copy Constructor. More...
DataObject & | operator= (const DataObject &rhs)
| Assignment Operator. More...
| DataObject (DataObject &&rhs)
| Move Constructor. More...
DataObject & | operator= (DataObject &&rhs)
| Move Assignment Operator. More...
virtual | ~DataObject ()
| Standard Destructor. More...
virtual unsigned long | addRef ()
| Add reference to object. More...
virtual unsigned long | release ()
| release reference to object More...
virtual const CLID & | clID () const
| Retrieve reference to class definition structure. More...
const std::string & | name () const
| Retreive DataObject name. It is the name when registered in the store. More...
virtual StatusCode | update ()
| Provide empty placeholder for internal object reconfiguration callback. More...
void | setRegistry (IRegistry *pRegistry)
| Set pointer to Registry. More...
IRegistry * | registry () const
| Get pointer to Registry. More...
LinkManager * | linkMgr () const
| Retrieve Link manager. More...
unsigned char | version () const
| Retrieve version number of this object representation. More...
void | setVersion (unsigned char vsn)
| Set version number of this object representation. More...
unsigned long | refCount () const
| Return the refcount. More...
virtual std::ostream & | fillStream (std::ostream &s) const
| Fill the output stream (ASCII) More...
Public Member Functions inherited from INTuple
virtual ItemContainer & | items ()=0
| Access item container. More...
virtual const ItemContainer & | items () const =0
| Access item container (CONST) More...
virtual char * | setBuffer (char *buff)=0
| Attach data buffer. More...
virtual const char * | buffer () const =0
| Access data buffer (CONST) More...
virtual char * | buffer ()=0
| Access data buffer. More...
virtual const std::string & | title () const =0
| Object title. More...
virtual void | reset ()=0
| Reset all entries to their default values. More...
virtual const INTupleItem * | find (const std::string &name) const =0
| Find an item row of the Ntuple (CONST) More...
virtual INTupleItem * | find (const std::string &name)=0
| Find an item row of the Ntuple. More...
virtual StatusCode | add (INTupleItem *item)=0
| Add an item row to the N tuple. More...
virtual StatusCode | remove (INTupleItem *item)=0
| Remove an item row (identified by pointer) from the N tuple. More...
virtual StatusCode | remove (const std::string &name)=0
| Remove an item row (identified by name) from the N tuple. More...
virtual StatusCode | attachSelector (ISelectStatement *sel)=0
| Attach selector. More...
virtual ISelectStatement * | selector ()=0
| Access selector. More...
virtual StatusCode | write ()=0
| Write record of the NTuple (Shortcut of writeRecord) More...
virtual StatusCode | writeRecord ()=0
| Write record of the NTuple. More...
virtual StatusCode | read ()=0
| Read record of the NTuple (Shortcut of readRecord) More...
virtual StatusCode | readRecord ()=0
| Read record of the NTuple. More...
virtual StatusCode | save ()=0
| Save the NTuple. More...
virtual | ~INTuple ()=default

## Protected Member Functions
template<class TYPE >
StatusCode | i_item (const std::string &name, _Item< TYPE > *&result) const
| Locate a _Column of data to the N tuple type safe. More...
template<class TYPE >
StatusCode | i_item (const std::string &name, _Item< TYPE * > *&result) const
| Locate a _Column of data to the N tuple type unsafe for objects. More...
StatusCode | i_item (const std::string &name, _Item< IOpaqueAddress * > *&result) const
| Locate a _Column of data to the N tuple type safe. More...
template<class TYPE >
StatusCode | i_item (const std::string &name, _Array< TYPE > *&result) const
| Locate a _Array of data to the N tuple type safe. More...
template<class TYPE >
StatusCode | i_item (const std::string &name, _Matrix< TYPE > *&result) const
| Locate a _Matrix of data to the N tuple type safe. More...
template<class TYPE >
StatusCode | i_addItem (const std::string &name, long, const std::string &, TYPE low, TYPE high, _Item< TYPE > *&result)
| Add a _Item of data to the N tuple. More...
template<class TYPE >
StatusCode | i_addItem (const std::string &name, long dim, const std::string &index, TYPE low, TYPE high, _Array< TYPE > *&result)
| Add a _Item of data to the N tuple. More...
template<class TYPE >
StatusCode | i_addItem (const std::string &name, long dim1, long dim2, const std::string &index, TYPE low, TYPE high, _Matrix< TYPE > *&result)
| Add a _Item of data to the N tuple. More...
template<class TYPE >
StatusCode | i_addObject (const std::string &name, _Item< TYPE * > *&result, const std::type_info &)
Protected Member Functions inherited from INTuple
virtual INTupleItem * | i_find (const std::string &name) const =0
| Internally used by abstract classes. More...

## Additional Inherited Members
Public Types inherited from INTuple
typedef std::vector< INTupleItem * > | ItemContainer
Static Public Member Functions inherited from DataObject
static const CLID & | classID ()
| Retrieve reference to class definition structure (static access) More...

## Detailed Description

Abstract base class which allows the user to interact with the actual N tuple implementation.

The class is abstract, because the template methods must be instantiated by the compiler at compile time. Otherwise the references would be unresolved.

Definition at line 370 of file NTuple.h.

## Constructor & Destructor Documentation

NTuple::Tuple::~Tuple | ( |  | ) |
| override default

Standard destructor.

## Member Function Documentation

template<class TYPE , class INDEX , class RANGE >

StatusCode NTuple::Tuple::addIndexedItem | ( | const std::string & | name,
|  | Item< INDEX > & | index,
|  | Array< TYPE > & | array,
|  | const RANGE | low,
|  | const RANGE | high
| ) |  |
| inline

Add an indexed Array of data to a column wise N tuple with a range.

You should use this entry point to add a VARIABLE SIZE ARRAY to a column wise N-tuple. The dimension of the array is unspecified and depends on the data range, which you allowed for the index column.

Hence you have to be careful on the allowed data range of the index column, because the index column determines the total allocated memory.

Note: Checks on the data range are not implemented!

Parameters

  name | Name of the column in the column wise N-tuple
  index | Reference to the scalar index column used to determine the size of the array.
  array | Reference to the Array<TYPE> datatype, which should be connected to the N-tuple.
  low | Lower edge of client data values allowed to fill into the N-tuple array.
  high | Upper edge of client data values allowed to fill into the N-tuple array.

Returns
  StatusCode indicating success or failure.

Definition at line 743 of file NTuple.h.

748 {
749 return i_addItem( name,
750 index->range().distance(),
751 index->name(),
752 TYPE(low),
753 TYPE(high),
754 array.m_ptr);
755 }
Containers::array
struct GAUDI_API array
Parametrisation class for redirection array - like implementation.
Definition: KeyedObjectManager.h:27
NTuple::Tuple::i_addItem
StatusCode i_addItem(const std::string &name, long, const std::string &, TYPE low, TYPE high, _Item< TYPE > *&result)
Add a _Item of data to the N tuple.
Definition: NTuple.h:435
template<class TYPE , class INDEX >

StatusCode NTuple::Tuple::addIndexedItem | ( | const std::string & | name,
|  | Item< INDEX > & | index,
|  | Array< TYPE > & | array
| ) |  |
| inline

Add an indexed Array of data to a column wise N tuple.

You should use this entry point to add a VARIABLE SIZE ARRAY to a column wise N-tuple. The dimension of the array is unspecified and depends on the data range, which you allowed for the index column.

Hence, you have to be careful on the allowed data range of the index column, because the index column determines the total allocated memory.

Parameters

  name | Name of the column in the column wise N-tuple
  index | Reference to the scalar index column used to determine the size of the array.
  array | Reference to the Array<TYPE> datatype, which should be connected to the N-tuple.

Returns
  StatusCode indicating success or failure.

Definition at line 814 of file NTuple.h.

817 {
818 return i_addItem( name,
819 index->range().distance(),
820 index->name(),
821 Range<TYPE>::min(),
822 Range<TYPE>::max(),
823 array.m_ptr);
824 }
NTuple::Range::min
static TYP min()
Minimal number of data.
Definition: NTuple.h:76
NTuple::Range::max
static TYP max()
Maximal number of data.
Definition: NTuple.h:78
Containers::array
struct GAUDI_API array
Parametrisation class for redirection array - like implementation.
Definition: KeyedObjectManager.h:27
NTuple::Tuple::i_addItem
StatusCode i_addItem(const std::string &name, long, const std::string &, TYPE low, TYPE high, _Item< TYPE > *&result)
Add a _Item of data to the N tuple.
Definition: NTuple.h:435
template<class TYPE , class INDEX >

StatusCode NTuple::Tuple::addIndexedItem | ( | const std::string & | name,
|  | Item< INDEX > & | col_index,
|  | long | rows,
|  | Matrix< TYPE > & | matrix
| ) |  |
| inline

Add an variable size Matrix of data to a column wise N tuple.

You should use this entry point to add a VARIABLE SIZE MATRIX to a column wise N-tuple. The number of columns of the matrix is given by the allowed data range of the index column. The number of rows however, which are allowed in the matrix must be specified explicitly and cannot be variable.

Attention: Do not confuse with entry point to add a FIXED SIZE MATRIX.

Parameters

  name | Name of the column in the column wise N-tuple
  index | Reference to the scalar index column used to determine the number of data columns in the matrix
  rows | Number of data rows in the Matrix.
  matrix | Reference to the Matrix<TYPE> datatype, which should be connected to the N-tuple.

Returns
  StatusCode indicating success or failure.

Definition at line 958 of file NTuple.h.

962 {
963 return i_addItem( name,
964 col_index->range().distance(),
965 rows,
966 col_index->name(),
967 Range<TYPE>::min(),
968 Range<TYPE>::max(),
969 matrix.m_ptr);
970 }
NTuple::Range::min
static TYP min()
Minimal number of data.
Definition: NTuple.h:76
NTuple::Range::max
static TYP max()
Maximal number of data.
Definition: NTuple.h:78
NTuple::Tuple::i_addItem
StatusCode i_addItem(const std::string &name, long, const std::string &, TYPE low, TYPE high, _Item< TYPE > *&result)
Add a _Item of data to the N tuple.
Definition: NTuple.h:435
template<class TYPE , class INDEX , class RANGE >

StatusCode NTuple::Tuple::addIndexedItem | ( | const std::string & | name,
|  | Item< INDEX > & | index,
|  | long | rows,
|  | Matrix< TYPE > & | matrix,
|  | const RANGE | low,
|  | const RANGE | high
| ) |  |
| inline

Add an variable size Matrix of data to a column wise N tuple.

You should use this entry point to add a VARIABLE SIZE MATRIX to a column wise N-tuple. The number of columns of the matrix is given by the allowed data range of the index column. The number of rows however, which are allowed in the matrix must be specified explicitly and cannot be variable. Also the range of allowed data values to be filled into the data area of the matrix can be specified.

Note: Checks on the data range are not implemented! Attention: Do not confuse with entry point to add a FIXED SIZE MATRIX.

Parameters

  name | Name of the column in the column wise N-tuple
  index | Reference to the scalar index column used to determine the number of data columns in the matrix
  rows | Number of data rows in the Matrix.
  matrix | Reference to the Matrix<TYPE> datatype, which should be connected to the N-tuple.
  low | Lower edge of client data values allowed to fill into the N-tuple matrix.
  high | Upper edge of client data values allowed to fill into the N-tuple matrix.

Returns
  StatusCode indicating success or failure.

Definition at line 1049 of file NTuple.h.

1055 {
1056 return i_addItem( name,
1057 index->range().distance(),
1058 rows,
1059 index->name(),
1060 TYPE(low),
1061 TYPE(high),
1062 matrix.m_ptr);
1063 }
NTuple::Tuple::i_addItem
StatusCode i_addItem(const std::string &name, long, const std::string &, TYPE low, TYPE high, _Item< TYPE > *&result)
Add a _Item of data to the N tuple.
Definition: NTuple.h:435
template<class TYPE >

StatusCode NTuple::Tuple::addItem | ( | const std::string & | name,
|  | Item< TYPE > & | itm
| ) |  |
| inline

Add a scalar data item a N tuple.

Use this entry point to connect any allowed scalar data type to an N-tuple. The value filled, may have any range. Do NOT use this entry point to specify an index column in a column wise N-tuple.

Parameters

  name | Name of the column in the column wise N-tuple
  itm | Reference to the Item<TYPE> datatype, which should be connected to the N-tuple.

Returns
  StatusCode indicating success or failure.

Definition at line 554 of file NTuple.h.

554 {
555 typedef Range<TYPE> _R;
556 return i_addItem(name, 1, "", _R::min(), _R::max(), itm.m_ptr);
557 }
ana.itm
tuple itm
Definition: ana.py:57
NTuple::Tuple::i_addItem
StatusCode i_addItem(const std::string &name, long, const std::string &, TYPE low, TYPE high, _Item< TYPE > *&result)
Add a _Item of data to the N tuple.
Definition: NTuple.h:435
template<class TYPE >

StatusCode NTuple::Tuple::addItem | ( | const std::string & | name,
|  | Item< TYPE * > & | itm
| ) |  |
| inline

Add an simple object item to an N tuple.

Parameters

  name | Name of the column in the column wise N-tuple
  itm | Reference to the Item<TYPE> datatype, which should be connected to the N-tuple.

Returns
  StatusCode indicating success or failure.

Definition at line 568 of file NTuple.h.

568 {
569 return i_addObject(name,itm.m_ptr,typeid(TYPE));
570 }
ana.itm
tuple itm
Definition: ana.py:57
NTuple::Tuple::i_addObject
StatusCode i_addObject(const std::string &name, _Item< TYPE * > *&result, const std::type_info &)
Definition: NTuple.h:491

StatusCode NTuple::Tuple::addItem | ( | const std::string & | name,
|  | Item< IOpaqueAddress * > & | itm
| ) |  |
| inline

Add an address object item to an N tuple: specialized call.

Parameters

  name | Name of the column in the column wise N-tuple
  itm | Reference to the Item<TYPE> datatype, which should be connected to the N-tuple.

Returns
  StatusCode indicating success or failure.

Definition at line 581 of file NTuple.h.

581 {
582 typedef Range<IOpaqueAddress*> _R;
583 return i_addItem(name, 1, "", _R::min(), _R::max(), itm.m_ptr);
584 }
ana.itm
tuple itm
Definition: ana.py:57
NTuple::Tuple::i_addItem
StatusCode i_addItem(const std::string &name, long, const std::string &, TYPE low, TYPE high, _Item< TYPE > *&result)
Add a _Item of data to the N tuple.
Definition: NTuple.h:435
template<class TYPE , class RANGE >

StatusCode NTuple::Tuple::addItem | ( | const std::string & | name,
|  | Item< TYPE > & | itm,
|  | const RANGE | low,
|  | const RANGE | high
| ) |  |
| inline

Add a scalar data item a N tuple with a range.

Typically this entry point is used to specuify index column with a fixed data range for a column wise N-tuple.

Note: Checks on the data range are not implemented!

Parameters

  name | Name of the column in the column wise N-tuple
  itm | Reference to the Item<TYPE> datatype, which should be connected to the N-tuple.
  low | Lower edge of client data values allowed to fill into the N-tuple array.
  high | Upper edge of client data values allowed to fill into the N-tuple array.

Returns
  StatusCode indicating success or failure.

Definition at line 604 of file NTuple.h.

608 {
609 return i_addItem( name, 1, "", TYPE(low), TYPE(high), itm.m_ptr);
610 }
ana.itm
tuple itm
Definition: ana.py:57
NTuple::Tuple::i_addItem
StatusCode i_addItem(const std::string &name, long, const std::string &, TYPE low, TYPE high, _Item< TYPE > *&result)
Add a _Item of data to the N tuple.
Definition: NTuple.h:435
template<class TYPE >

StatusCode NTuple::Tuple::addItem | ( | const std::string & | name,
|  | long | dim,
|  | Array< TYPE > & | array
| ) |  |
| inline

Add an fixed-size Array of data to a column wise N tuple.

You should use this entry point to add a FIXED SIZE ARRAY to a column wise N-tuple. The dimension of the array must be specified.

Parameters

  name | Name of the column in the column wise N-tuple
  dim | Length of the array to be added to the N-tuple
  array | Reference to the Array<TYPE> datatype, which should be connected to the N-tuple.

Returns
  StatusCode indicating success or failure.

Definition at line 626 of file NTuple.h.

629 {
630 return i_addItem(name,
631 dim,
632 "",
633 Range<TYPE>::min(),
634 Range<TYPE>::max(),
635 array.m_ptr);
636 }
Containers::array
struct GAUDI_API array
Parametrisation class for redirection array - like implementation.
Definition: KeyedObjectManager.h:27
NTuple::Tuple::i_addItem
StatusCode i_addItem(const std::string &name, long, const std::string &, TYPE low, TYPE high, _Item< TYPE > *&result)
Add a _Item of data to the N tuple.
Definition: NTuple.h:435
template<class TYPE , class RANGE >

StatusCode NTuple::Tuple::addItem | ( | const std::string & | name,
|  | long | dim,
|  | Array< TYPE > & | array,
|  | const RANGE | low,
|  | const RANGE | high
| ) |  |
| inline

Add an fixed-size Array of data to a column wise N tuple with a range.

You should use this entry point to add a FIXED SIZE ARRAY to a column wise N-tuple. The dimension of the array must be specified.

Note: Checks on the data range are not implemented!

Parameters

  name | Name of the column in the column wise N-tuple
  dim | Length of the array to be added to the N-tuple
  array | Reference to the Array<TYPE> datatype, which should be connected to the N-tuple.
  low | Lower edge of client data values allowed to fill into the N-tuple array.
  high | Upper edge of client data values allowed to fill into the N-tuple array.

Returns
  StatusCode indicating success or failure.

Definition at line 658 of file NTuple.h.

663 {
664 return i_addItem(name,
665 dim,
666 "",
667 TYPE(low),
668 TYPE(high),
669 array.m_ptr);
670 }
Containers::array
struct GAUDI_API array
Parametrisation class for redirection array - like implementation.
Definition: KeyedObjectManager.h:27
NTuple::Tuple::i_addItem
StatusCode i_addItem(const std::string &name, long, const std::string &, TYPE low, TYPE high, _Item< TYPE > *&result)
Add a _Item of data to the N tuple.
Definition: NTuple.h:435
template<class TYPE , class INDEX , class RANGE >

StatusCode NTuple::Tuple::addItem | ( | const std::string & | name,
|  | Item< INDEX > & | index,
|  | Array< TYPE > & | array,
|  | const RANGE | low,
|  | const RANGE | high
| ) |  |
| inline

Add an indexed Array of data to a column wise N tuple with a range.

You should use this entry point to add a VARIABLE SIZE ARRAY to a column wise N-tuple. The dimension of the array is unspecified and depends on the data range, which you allowed for the index column.

Hence you have to be careful on the allowed data range of the index column, because the index column determines the total allocated memory.

Note: Checks on the data range are not implemented!

Note: Due to confusion with the entry point to connecting a fixed size array the use of this function is DEPRECATED *** please use addIndexedItem(...) instead.

Parameters

  name | Name of the column in the column wise N-tuple
  index | Reference to the scalar index column used to determine the size of the array.
  array | Reference to the Array<TYPE> datatype, which should be connected to the N-tuple.
  low | Lower edge of client data values allowed to fill into the N-tuple array.
  high | Upper edge of client data values allowed to fill into the N-tuple array.

Returns
  StatusCode indicating success or failure.

Definition at line 703 of file NTuple.h.

708 {
709 return i_addItem( name,
710 index->range().distance(),
711 index->name(),
712 TYPE(low),
713 TYPE(high),
714 array.m_ptr);
715 }
Containers::array
struct GAUDI_API array
Parametrisation class for redirection array - like implementation.
Definition: KeyedObjectManager.h:27
NTuple::Tuple::i_addItem
StatusCode i_addItem(const std::string &name, long, const std::string &, TYPE low, TYPE high, _Item< TYPE > *&result)
Add a _Item of data to the N tuple.
Definition: NTuple.h:435
template<class TYPE , class INDEX >

StatusCode NTuple::Tuple::addItem | ( | const std::string & | name,
|  | Item< INDEX > & | index,
|  | Array< TYPE > & | array
| ) |  |
| inline

Add an indexed Array of data to a column wise N tuple.

You should use this entry point to add a VARIABLE SIZE ARRAY to a column wise N-tuple. The dimension of the array is unspecified and depends on the data range, which you allowed for the index column.

Hence, you have to be careful on the allowed data range of the index column, because the index column determines the total allocated memory.

Note: Due to confusion with the entry point to connecting a fixed size array the use of this member function is DEPRECATED *** please use addIndexedItem(...) instead.

Parameters

  name | Name of the column in the column wise N-tuple
  index | Reference to the scalar index column used to determine the size of the array.
  array | Reference to the Array<TYPE> datatype, which should be connected to the N-tuple.

Returns
  StatusCode indicating success or failure.

Definition at line 782 of file NTuple.h.

785 {
786 return i_addItem( name,
787 index->range().distance(),
788 index->name(),
789 Range<TYPE>::min(),
790 Range<TYPE>::max(),
791 array.m_ptr);
792 }
NTuple::Range::min
static TYP min()
Minimal number of data.
Definition: NTuple.h:76
NTuple::Range::max
static TYP max()
Maximal number of data.
Definition: NTuple.h:78
Containers::array
struct GAUDI_API array
Parametrisation class for redirection array - like implementation.
Definition: KeyedObjectManager.h:27
NTuple::Tuple::i_addItem
StatusCode i_addItem(const std::string &name, long, const std::string &, TYPE low, TYPE high, _Item< TYPE > *&result)
Add a _Item of data to the N tuple.
Definition: NTuple.h:435
template<class TYPE >

StatusCode NTuple::Tuple::addItem | ( | const std::string & | name,
|  | long | cols,
|  | long | rows,
|  | Matrix< TYPE > & | matrix
| ) |  |
| inline

Add an fixed size Matrix of data to a column wise N tuple.

You should use this entry point to add a FIXED SIZE MATRIX to a column wise N-tuple. The dimension of the matrix must be specified.

Attention: Do not confuse with entry point to add a VARIABLE SIZE MATRIX!

Parameters

  name | Name of the column in the column wise N-tuple
  cols | Number of data columns in the Matrix.
  rows | Number of data rows in the Matrix.
  matrix | Reference to the Matrix<TYPE> datatype, which should be connected to the N-tuple.

Returns
  StatusCode indicating success or failure.

Definition at line 844 of file NTuple.h.

848 {
849 return i_addItem(name,
850 cols,
851 rows,
852 "",
853 Range<TYPE>::min(),
854 Range<TYPE>::max(),
855 matrix.m_ptr);
856 }
NTuple::Tuple::i_addItem
StatusCode i_addItem(const std::string &name, long, const std::string &, TYPE low, TYPE high, _Item< TYPE > *&result)
Add a _Item of data to the N tuple.
Definition: NTuple.h:435
template<class TYPE , class RANGE >

StatusCode NTuple::Tuple::addItem | ( | const std::string & | name,
|  | long | cols,
|  | long | rows,
|  | Matrix< TYPE > & | result,
|  | const RANGE | low,
|  | const RANGE | high
| ) |  |
| inline

Add an fixed size Matrix of data to a column wise N tuple.

You should use this entry point to add a FIXED SIZE MATRIX to a column wise N-tuple. The dimension of the matrix must be specified.

Note: Checks on the data range are not implemented! Attention: Do not confuse with entry point to add a VARIABLE SIZE MATRIX!

Parameters

  name | Name of the column in the column wise N-tuple
  cols | Number of data columns in the Matrix.
  rows | Number of data rows in the Matrix.
  matrix | Reference to the Matrix<TYPE> datatype, which should be connected to the N-tuple.
  low | Lower edge of client data values allowed to fill into the N-tuple matrix.
  high | Upper edge of client data values allowed to fill into the N-tuple matrix.

Returns
  StatusCode indicating success or failure.

Definition at line 881 of file NTuple.h.

887 {
888 return i_addItem(name,
889 cols,
890 rows,
891 "",
892 TYPE(low),
893 TYPE(high),
894 result.m_ptr);
895 }
NTuple::Tuple::i_addItem
StatusCode i_addItem(const std::string &name, long, const std::string &, TYPE low, TYPE high, _Item< TYPE > *&result)
Add a _Item of data to the N tuple.
Definition: NTuple.h:435
template<class TYPE , class INDEX >

StatusCode NTuple::Tuple::addItem | ( | const std::string & | name,
|  | Item< INDEX > & | index,
|  | Matrix< TYPE > & | matrix,
|  | long | rows
| ) |  |
| inline

Add an variable size Matrix of data to a column wise N tuple.

You should use this entry point to add a VARIABLE SIZE MATRIX to a column wise N-tuple. The number of columns of the matrix is given by the allowed data range of the index column. The number of rows however, which are allowed in the matrix must be specified explicitly and cannot be variable.

Attention: Do not confuse with entry point to add a FIXED SIZE MATRIX.

Note: Due to confusion with the entry point to connecting a fixed size matrix the use of this member function is DEPRECATED *** please use addIndexedItem(...) instead.

Parameters

  name | Name of the column in the column wise N-tuple
  index | Reference to the scalar index column used to determine the number of data columns in the matrix
  matrix | Reference to the Matrix<TYPE> datatype, which should be connected to the N-tuple.
  rows | Number of data rows in the Matrix.

Returns
  StatusCode indicating success or failure.

Definition at line 923 of file NTuple.h.

927 {
928 return i_addItem( name,
929 index->range().distance(),
930 rows,
931 index->name(),
932 Range<TYPE>::min(),
933 Range<TYPE>::max(),
934 matrix.m_ptr);
935 }
NTuple::Range::min
static TYP min()
Minimal number of data.
Definition: NTuple.h:76
NTuple::Range::max
static TYP max()
Maximal number of data.
Definition: NTuple.h:78
NTuple::Tuple::i_addItem
StatusCode i_addItem(const std::string &name, long, const std::string &, TYPE low, TYPE high, _Item< TYPE > *&result)
Add a _Item of data to the N tuple.
Definition: NTuple.h:435
template<class TYPE , class INDEX , class RANGE >

StatusCode NTuple::Tuple::addItem | ( | const std::string & | name,
|  | Item< INDEX > & | index,
|  | Matrix< TYPE > & | matrix,
|  | long | rows,
|  | const RANGE | low,
|  | const RANGE | high
| ) |  |
| inline

Add an variable size Matrix of data to a column wise N tuple.

You should use this entry point to add a VARIABLE SIZE MATRIX to a column wise N-tuple. The number of columns of the matrix is given by the allowed data range of the index column. The number of rows however, which are allowed in the matrix must be specified explicitly and cannot be variable. Also the range of allowed data values to be filled into the data area of the matrix can be specified.

Note: Checks on the data range are not implemented! Attention: Do not confuse with entry point to add a FIXED SIZE MATRIX.

Note: Due to confusion with the entry point to connecting a fixed size matrix the use of this member function is DEPRECATED *** please use addIndexedItem(...) instead.

Parameters

  name | Name of the column in the column wise N-tuple
  index | Reference to the scalar index column used to determine the number of data columns in the matrix
  matrix | Reference to the Matrix<TYPE> datatype, which should be connected to the N-tuple.
  rows | Number of data rows in the Matrix.
  low | Lower edge of client data values allowed to fill into the N-tuple matrix.
  high | Upper edge of client data values allowed to fill into the N-tuple matrix.

Returns
  StatusCode indicating success or failure.

Definition at line 1005 of file NTuple.h.

1011 {
1012 return i_addItem( name,
1013 index->range().distance(),
1014 rows,
1015 index->name(),
1016 TYPE(low),
1017 TYPE(high),
1018 matrix.m_ptr);
1019 }
NTuple::Tuple::i_addItem
StatusCode i_addItem(const std::string &name, long, const std::string &, TYPE low, TYPE high, _Item< TYPE > *&result)
Add a _Item of data to the N tuple.
Definition: NTuple.h:435
template<class TYPE >

StatusCode NTuple::Tuple::i_addItem | ( | const std::string & | name,
|  | long | ,
|  | const std::string & | ,
|  | TYPE | low,
|  | TYPE | high,
|  | _Item< TYPE > *& | result
| ) |  |
| inline protected

Add a _Item of data to the N tuple.

Definition at line 435 of file NTuple.h.

440 {
441 if ( !i_find(name) ) {
442 TYPE nil;
443 nil = 0;
444 return add( result = _Item<TYPE>::create(this, name, typeid(TYPE), low, high, nil) );
445 }
446 return StatusCode::FAILURE;
447 }
INTuple::add
virtual StatusCode add(INTupleItem *item)=0
Add an item row to the N tuple.
StatusCode::FAILURE
Definition: StatusCode.h:29
INTuple::i_find
virtual INTupleItem * i_find(const std::string &name) const =0
Internally used by abstract classes.
template<class TYPE >

StatusCode NTuple::Tuple::i_addItem | ( | const std::string & | name,
|  | long | dim,
|  | const std::string & | index,
|  | TYPE | low,
|  | TYPE | high,
|  | _Array< TYPE > *& | result
| ) |  |
| inline protected

Add a _Item of data to the N tuple.

Definition at line 450 of file NTuple.h.

455 {
456 if ( !i_find(name) && clID() == CLID_ColumnWiseTuple ) {
457 return add( result = _Array<TYPE>::create(this,
458 name,
459 typeid(TYPE),
460 index,
461 dim,
462 low,
463 high,
464 TYPE(0)) );
465 }
466 return StatusCode::FAILURE;
467 }
INTuple::add
virtual StatusCode add(INTupleItem *item)=0
Add an item row to the N tuple.
DataObject::clID
virtual const CLID & clID() const
Retrieve reference to class definition structure.
Definition: DataObject.cpp:68
StatusCode::FAILURE
Definition: StatusCode.h:29
INTuple::i_find
virtual INTupleItem * i_find(const std::string &name) const =0
Internally used by abstract classes.
template<class TYPE >

StatusCode NTuple::Tuple::i_addItem | ( | const std::string & | name,
|  | long | dim1,
|  | long | dim2,
|  | const std::string & | index,
|  | TYPE | low,
|  | TYPE | high,
|  | _Matrix< TYPE > *& | result
| ) |  |
| inline protected

Add a _Item of data to the N tuple.

Definition at line 470 of file NTuple.h.

476 {
477 if ( !i_find(name) && clID() == CLID_ColumnWiseTuple ) {
478 return add( result = _Matrix<TYPE>::create(this,
479 name,
480 typeid(TYPE),
481 index,
482 dim1,
483 dim2,
484 low,
485 high,
486 TYPE(0)) );
487 }
488 return StatusCode::FAILURE;
489 }
INTuple::add
virtual StatusCode add(INTupleItem *item)=0
Add an item row to the N tuple.
DataObject::clID
virtual const CLID & clID() const
Retrieve reference to class definition structure.
Definition: DataObject.cpp:68
StatusCode::FAILURE
Definition: StatusCode.h:29
INTuple::i_find
virtual INTupleItem * i_find(const std::string &name) const =0
Internally used by abstract classes.
template<class TYPE >

StatusCode NTuple::Tuple::i_addObject | ( | const std::string & | name,
|  | _Item< TYPE * > *& | result,
|  | const std::type_info & |
| ) |  |
| inline protected

Definition at line 491 of file NTuple.h.

491 {
492 if ( !i_find(name) && clID() == CLID_ColumnWiseTuple ) {
493 return add( result = (_Item<TYPE*>*)_Item<void*>::create(this, name, typeid(TYPE),0,0,0) );
494 }
495 return StatusCode::FAILURE;
496 }
INTuple::add
virtual StatusCode add(INTupleItem *item)=0
Add an item row to the N tuple.
DataObject::clID
virtual const CLID & clID() const
Retrieve reference to class definition structure.
Definition: DataObject.cpp:68
StatusCode::FAILURE
Definition: StatusCode.h:29
INTuple::i_find
virtual INTupleItem * i_find(const std::string &name) const =0
Internally used by abstract classes.
template<class TYPE >

StatusCode NTuple::Tuple::i_item | ( | const std::string & | name,
|  | _Item< TYPE > *& | result
| ) |  | const
| inline protected

Locate a _Column of data to the N tuple type safe.

Definition at line 374 of file NTuple.h.

375 {
376 try {
377 result = dynamic_cast< _Item<TYPE>* > (i_find(name));
378 }
379 catch (...) {
380 result = nullptr;
381 }
382 return result ? StatusCode::SUCCESS : StatusCode::FAILURE;
383 }
StatusCode::FAILURE
Definition: StatusCode.h:29
StatusCode::SUCCESS
Definition: StatusCode.h:30
INTuple::i_find
virtual INTupleItem * i_find(const std::string &name) const =0
Internally used by abstract classes.
template<class TYPE >

StatusCode NTuple::Tuple::i_item | ( | const std::string & | name,
|  | _Item< TYPE * > *& | result
| ) |  | const
| inline protected

Locate a _Column of data to the N tuple type unsafe for objects.

Definition at line 385 of file NTuple.h.

386 {
387 try {
388 _Item<void*>* p = dynamic_cast< _Item<void*>* > (i_find(name));
389 result = (_Item<TYPE*>*)p;
390 }
391 catch (...) {
392 result = nullptr;
393 }
394 return result ? StatusCode::SUCCESS : StatusCode::FAILURE;
395 }
StatusCode::FAILURE
Definition: StatusCode.h:29
StatusCode::SUCCESS
Definition: StatusCode.h:30
INTuple::i_find
virtual INTupleItem * i_find(const std::string &name) const =0
Internally used by abstract classes.

StatusCode NTuple::Tuple::i_item | ( | const std::string & | name,
|  | _Item< IOpaqueAddress * > *& | result
| ) |  | const
| inline protected

Locate a _Column of data to the N tuple type safe.

Definition at line 397 of file NTuple.h.

398 {
399 try {
400 result = dynamic_cast< _Item<IOpaqueAddress*>* > (i_find(name));
401 }
402 catch (...) {
403 result = nullptr;
404 }
405 return result ? StatusCode::SUCCESS : StatusCode::FAILURE;
406 }
StatusCode::FAILURE
Definition: StatusCode.h:29
StatusCode::SUCCESS
Definition: StatusCode.h:30
INTuple::i_find
virtual INTupleItem * i_find(const std::string &name) const =0
Internally used by abstract classes.
template<class TYPE >

StatusCode NTuple::Tuple::i_item | ( | const std::string & | name,
|  | _Array< TYPE > *& | result
| ) |  | const
| inline protected

Locate a _Array of data to the N tuple type safe.

Definition at line 408 of file NTuple.h.

409 {
410 try {
411 if ( clID() == CLID_ColumnWiseTuple ) {
412 result = dynamic_cast< _Array<TYPE>* > (i_find(name));
413 }
414 }
415 catch (...) {
416 result = nullptr;
417 }
418 return result ? StatusCode::SUCCESS : StatusCode::FAILURE;
419 }
DataObject::clID
virtual const CLID & clID() const
Retrieve reference to class definition structure.
Definition: DataObject.cpp:68
StatusCode::FAILURE
Definition: StatusCode.h:29
StatusCode::SUCCESS
Definition: StatusCode.h:30
INTuple::i_find
virtual INTupleItem * i_find(const std::string &name) const =0
Internally used by abstract classes.
template<class TYPE >

StatusCode NTuple::Tuple::i_item | ( | const std::string & | name,
|  | _Matrix< TYPE > *& | result
| ) |  | const
| inline protected

Locate a _Matrix of data to the N tuple type safe.

Definition at line 421 of file NTuple.h.

422 {
423 try {
424 if ( clID() == CLID_ColumnWiseTuple ) {
425 result = dynamic_cast< _Matrix<TYPE>* > (i_find(name));
426 }
427 }
428 catch (...) {
429 result = nullptr;
430 }
431 return result ? StatusCode::SUCCESS : StatusCode::FAILURE;
432 }
DataObject::clID
virtual const CLID & clID() const
Retrieve reference to class definition structure.
Definition: DataObject.cpp:68
StatusCode::FAILURE
Definition: StatusCode.h:29
StatusCode::SUCCESS
Definition: StatusCode.h:30
INTuple::i_find
virtual INTupleItem * i_find(const std::string &name) const =0
Internally used by abstract classes.
template<class TYPE >

StatusCode NTuple::Tuple::item | ( | const std::string & | name,
|  | Item< TYPE > & | result
| ) |  |
| inline

Locate a scalar Item of data to the N tuple type safe.

Definition at line 503 of file NTuple.h.

505 {
506 return i_item(name, result.m_ptr);
507 }
NTuple::Tuple::i_item
StatusCode i_item(const std::string &name, _Item< TYPE > *&result) const
Locate a _Column of data to the N tuple type safe.
Definition: NTuple.h:374
template<class TYPE >

StatusCode NTuple::Tuple::item | ( | const std::string & | name,
|  | const Item< TYPE > & | result
| ) |  | const
| inline

Locate a scalar Item of data to the N tuple type safe (CONST)

Definition at line 509 of file NTuple.h.

511 {
512 return i_item(name, result.m_ptr);
513 }
NTuple::Tuple::i_item
StatusCode i_item(const std::string &name, _Item< TYPE > *&result) const
Locate a _Column of data to the N tuple type safe.
Definition: NTuple.h:374
template<class TYPE >

StatusCode NTuple::Tuple::item | ( | const std::string & | name,
|  | Array< TYPE > & | result
| ) |  |
| inline

Locate a Array of data to the N tuple type safe.

Definition at line 516 of file NTuple.h.

517 {
518 return i_item(name, result.m_ptr);
519 }
NTuple::Tuple::i_item
StatusCode i_item(const std::string &name, _Item< TYPE > *&result) const
Locate a _Column of data to the N tuple type safe.
Definition: NTuple.h:374
template<class TYPE >

StatusCode NTuple::Tuple::item | ( | const std::string & | name,
|  | const Array< TYPE > & | result
| ) |  | const
| inline

Locate a Array of data to the N tuple type safe (CONST)

Definition at line 521 of file NTuple.h.

523 {
524 return i_item(name, result.m_ptr);
525 }
NTuple::Tuple::i_item
StatusCode i_item(const std::string &name, _Item< TYPE > *&result) const
Locate a _Column of data to the N tuple type safe.
Definition: NTuple.h:374
template<class TYPE >

StatusCode NTuple::Tuple::item | ( | const std::string & | name,
|  | Matrix< TYPE > & | result
| ) |  |
| inline

Locate a Matrix of data to the N tuple type safe.

Definition at line 527 of file NTuple.h.

529 {
530 return i_item(name, result.m_ptr);
531 }
NTuple::Tuple::i_item
StatusCode i_item(const std::string &name, _Item< TYPE > *&result) const
Locate a _Column of data to the N tuple type safe.
Definition: NTuple.h:374
template<class TYPE >

StatusCode NTuple::Tuple::item | ( | const std::string & | name,
|  | const Matrix< TYPE > & | result
| ) |  | const
| inline

Locate a Matrix of data to the N tuple type safe (CONST)

Definition at line 534 of file NTuple.h.

536 {
537 return i_item(name, result.m_ptr);
538 }
NTuple::Tuple::i_item
StatusCode i_item(const std::string &name, _Item< TYPE > *&result) const
Locate a _Column of data to the N tuple type safe.
Definition: NTuple.h:374

The documentation for this class was generated from the following file:

- GaudiKernel/GaudiKernel/NTuple.h