Gaudi Framework, version v20r2

Generated: 18 Jul 2008

NTuple::_Array< TYP > Class Template Reference

#include <NTuple.h>

Inheritance diagram for NTuple::_Array< TYP >:

Inheritance graph
[legend]
Collaboration diagram for NTuple::_Array< TYP >:

Collaboration graph
[legend]
List of all members.

Detailed Description

template<class TYP>
class NTuple::_Array< TYP >

Abstract class discribing a column-array in a N tuple.

Definition at line 150 of file NTuple.h.

Public Member Functions

template<class T>
_Array< TYP > & operator= (const _Array< T > &copy)
 Assignment operator.
const TYP & data (long i) const
 Access to data by reference (CONST).
TYP & data (long i)
 Access to data by reference (CONST).

Static Public Member Functions

static _Arraycreate (INTuple *tup, const std::string &name, const std::type_info &info, const std::string &index, long len, TYP min, TYP max, TYP def)
 Create instance.


Member Function Documentation

template<class TYP>
NTuple::_Array< TYP > * NTuple::_Array< TYP >::create ( INTuple tup,
const std::string name,
const std::type_info info,
const std::string index,
long  len,
TYP  min,
TYP  max,
TYP  def 
) [static]

Create instance.

Definition at line 34 of file NTupleItems.cpp.

References INTupleItem::name().

Referenced by createItem(), HbookCnv::createNTupleItem(), and RootHistCnv::createNTupleItem().

00034                                                                                                                                              {
00035   _ArrayImp<TYP>* result = new _ArrayImp<TYP>(tup,name,info,idx,len,min,max,def);
00036   return result;
00037 }

template<class TYP>
template<class T>
_Array<TYP>& NTuple::_Array< TYP >::operator= ( const _Array< T > &  copy  )  [inline]

Assignment operator.

Definition at line 163 of file NTuple.h.

References INTupleItem::buffer(), and INTupleItem::length().

00163                                                     {
00164       long len = this->length();
00165       if ( len == copy.length() )    {
00166         const T* source = (const T*)copy.buffer();
00167         for ( int i = 0; i < len; i++ )  {
00168           *(this->m_buffer + i) = *(source + i);
00169         }
00170         return *this;
00171       }
00172       throw std::out_of_range
00173         ("N-tuple matrix cannot be copied! The index range does not match!");
00174       return *this;
00175     }

template<class TYP>
const TYP& NTuple::_Array< TYP >::data ( long  i  )  const [inline]

Access to data by reference (CONST).

Definition at line 177 of file NTuple.h.

References NTuple::_Data< TYP >::m_buffer.

00177 { return *(this->m_buffer + i);        }

template<class TYP>
TYP& NTuple::_Array< TYP >::data ( long  i  )  [inline]

Access to data by reference (CONST).

Definition at line 179 of file NTuple.h.

References NTuple::_Data< TYP >::m_buffer.

00179 { return *(this->m_buffer + i);        }


The documentation for this class was generated from the following files:
Generated at Fri Jul 18 12:10:54 2008 for Gaudi Framework, version v20r2 by Doxygen version 1.5.1 written by Dimitri van Heesch, © 1997-2004