| Classes | Job Modules | Data Objects | Services | Algorithms | Tools | Packages | Directories | Tracs |

In This Package:

NTuple::_Matrix< TYP > Class Template Reference

Abstract class discribing a matrix column in a N tuple. More...

#include <NTuple.h>

Inheritance diagram for NTuple::_Matrix< TYP >:

[legend]
Collaboration diagram for NTuple::_Matrix< TYP >:
[legend]
List of all members.

Public Types

typedef Range< TYP > ItemRange
 Set type definition to make life more easy easy.

Public Member Functions

template<class T>
_Matrix< TYP > & operator= (const _Matrix< T > &copy)
 Assignment operator.
TYP * column (long i)
 Access to data by reference.
const TYP * column (long i) const
 Access to data by reference (CONST).
virtual void setDefault (const TYP d)=0
 Set default value.
virtual const ItemRangerange () const =0
 Access the range if specified.
virtual void release ()=0
 Destruct object.
virtual const std::type_info & typeID () const =0
 Compiler type ID.
virtual std::string typeName () const =0
 Proper type name of the object.
virtual const void * buffer () const =0
 Access data buffer (CONST).
virtual bool hasIndex () const =0
 Is the tuple have an index item?
virtual const std::string & index () const =0
 Access the index _Item.
virtual const std::string & name () const =0
 Access _Item name.
virtual long type () const =0
 Type information of the item.
virtual long length () const =0
 Access the buffer length.
virtual void reset ()=0
 Reset column.
virtual long ndim () const =0
 Dimension.
virtual long dim (long i) const =0
 Access individual dimensions.
virtual long size () const =0
 Size of entire object.
virtual long filled () const =0
 Number of items filled.
virtual INTupleItemindexItem ()=0
 Pointer to index column (if present, 0 else).
virtual const INTupleItemindexItem () const =0
 Pointer to index column (if present, 0 else) (CONST).
virtual INTupletuple ()=0
 NTuple the item belongs to.

Static Public Member Functions

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

Protected Member Functions

virtual void setType (long typ)=0
 Set the properties of the INTupleItem.

Protected Attributes

long m_rows
 Number of rows per column.
TYP * m_buffer
 Pointer to data buffer.

Detailed Description

template<class TYP>
class NTuple::_Matrix< TYP >

Abstract class discribing a matrix column in a N tuple.

Definition at line 184 of file NTuple.h.


Member Typedef Documentation

template<class TYP>
typedef Range<TYP> NTuple::_Data< TYP >::ItemRange [inherited]

Set type definition to make life more easy easy.

Reimplemented in NTuple::_DataImp< TYP >, NTuple::_ItemImp< TYP >, NTuple::_ArrayImp< TYP >, and NTuple::_MatrixImp< TYP >.

Definition at line 118 of file NTuple.h.


Member Function Documentation

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

Create instance.

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

Assignment operator.

Definition at line 201 of file NTuple.h.

00201                                                       {
00202       long len = this->length();
00203       if ( len == copy.length() )    {
00204         const T* source = (const T*)copy.buffer();
00205         for ( int i = 0; i < len; i++ )  {
00206           *(this->m_buffer + i) = *(source + i);
00207         }
00208         return *this;
00209       }
00210       throw std::out_of_range
00211         ("N-tuple matrix cannot be copied! The index range does not match!");
00212       return *this;
00213     }

template<class TYP>
TYP* NTuple::_Matrix< TYP >::column ( long  i  )  [inline]

Access to data by reference.

Definition at line 215 of file NTuple.h.

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

template<class TYP>
const TYP* NTuple::_Matrix< TYP >::column ( long  i  )  const [inline]

Access to data by reference (CONST).

Definition at line 217 of file NTuple.h.

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

template<class TYP>
virtual void NTuple::_Data< TYP >::setDefault ( const TYP  d  )  [pure virtual, inherited]

Set default value.

Implemented in NTuple::_DataImp< TYP >, NTuple::_ItemImp< TYP >, NTuple::_ArrayImp< TYP >, and NTuple::_MatrixImp< TYP >.

template<class TYP>
virtual const ItemRange& NTuple::_Data< TYP >::range (  )  const [pure virtual, inherited]

Access the range if specified.

Implemented in NTuple::_DataImp< TYP >, NTuple::_ItemImp< TYP >, NTuple::_ArrayImp< TYP >, and NTuple::_MatrixImp< TYP >.

virtual void INTupleItem::setType ( long  typ  )  [protected, pure virtual, inherited]

Set the properties of the INTupleItem.

Implemented in NTuple::_DataImp< TYP >.

virtual void INTupleItem::release (  )  [pure virtual, inherited]

Destruct object.

Implemented in NTuple::_DataImp< TYP >.

virtual const std::type_info& INTupleItem::typeID (  )  const [pure virtual, inherited]

Compiler type ID.

Implemented in NTuple::_DataImp< TYP >.

virtual std::string INTupleItem::typeName (  )  const [pure virtual, inherited]

Proper type name of the object.

Implemented in NTuple::_DataImp< TYP >.

virtual const void* INTupleItem::buffer (  )  const [pure virtual, inherited]

Access data buffer (CONST).

Implemented in NTuple::_DataImp< TYP >.

virtual bool INTupleItem::hasIndex (  )  const [pure virtual, inherited]

Is the tuple have an index item?

Implemented in NTuple::_DataImp< TYP >.

virtual const std::string& INTupleItem::index (  )  const [pure virtual, inherited]

Access the index _Item.

Implemented in NTuple::_DataImp< TYP >.

virtual const std::string& INTupleItem::name (  )  const [pure virtual, inherited]

Access _Item name.

Implemented in NTuple::_DataImp< TYP >.

virtual long INTupleItem::type (  )  const [pure virtual, inherited]

Type information of the item.

Implemented in NTuple::_DataImp< TYP >.

virtual long INTupleItem::length (  )  const [pure virtual, inherited]

Access the buffer length.

Implemented in NTuple::_DataImp< TYP >.

virtual void INTupleItem::reset (  )  [pure virtual, inherited]

Reset column.

Implemented in NTuple::_DataImp< TYP >.

virtual long INTupleItem::ndim (  )  const [pure virtual, inherited]

Dimension.

Implemented in NTuple::_DataImp< TYP >, NTuple::_ArrayImp< TYP >, and NTuple::_MatrixImp< TYP >.

virtual long INTupleItem::dim ( long  i  )  const [pure virtual, inherited]

Access individual dimensions.

Implemented in NTuple::_DataImp< TYP >, NTuple::_ArrayImp< TYP >, and NTuple::_MatrixImp< TYP >.

virtual long INTupleItem::size (  )  const [pure virtual, inherited]

Size of entire object.

Implemented in NTuple::_DataImp< TYP >, NTuple::_ItemImp< TYP >, NTuple::_ArrayImp< TYP >, and NTuple::_MatrixImp< TYP >.

virtual long INTupleItem::filled (  )  const [pure virtual, inherited]

Number of items filled.

Implemented in NTuple::_DataImp< TYP >.

virtual INTupleItem* INTupleItem::indexItem (  )  [pure virtual, inherited]

Pointer to index column (if present, 0 else).

Implemented in NTuple::_DataImp< TYP >.

virtual const INTupleItem* INTupleItem::indexItem (  )  const [pure virtual, inherited]

Pointer to index column (if present, 0 else) (CONST).

Implemented in NTuple::_DataImp< TYP >.

virtual INTuple* INTupleItem::tuple (  )  [pure virtual, inherited]

NTuple the item belongs to.

Implemented in NTuple::_DataImp< TYP >.


Member Data Documentation

template<class TYP>
long NTuple::_Matrix< TYP >::m_rows [protected]

Number of rows per column.

Definition at line 187 of file NTuple.h.

template<class TYP>
TYP* NTuple::_Data< TYP >::m_buffer [protected, inherited]

Pointer to data buffer.

Definition at line 115 of file NTuple.h.


The documentation for this class was generated from the following file:
| Classes | Job Modules | Data Objects | Services | Algorithms | Tools | Packages | Directories | Tracs |

Generated on Mon Apr 11 19:57:18 2011 for GaudiKernel by doxygen 1.4.7