casa  $Rev:20696$
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines
Public Member Functions | Protected Attributes
casa::TabVecTemp< T > Class Template Reference

Templated table vectors held in memory as a temporary. More...

#include <TVecTemp.h>

Inheritance diagram for casa::TabVecTemp< T >:
casa::TabVecRep< T >

List of all members.

Public Member Functions

 TabVecTemp (const Vector< T > &)
 Create table vector containing the given Vector (reference semantics).
 TabVecTemp (uInt leng)
 Create table vector containing a Vector with given length.
 ~TabVecTemp ()
 Destruct the object.
const T & operator() (uInt index) const
 Return a reference to a value.
T & operator() (uInt index)
 Return a reference to a value.
value (uInt index) const
 Get a value (virtual function).
void getVal (uInt index, T &) const
 Get a value (virtual function).
void putVal (uInt index, const T &)
 Put a value (virtual function).
void set (const T &)
 Set entire vector to a value.

Protected Attributes

Vector< T > * vecPtr_p

Detailed Description

template<class T>
class casa::TabVecTemp< T >

Templated table vectors held in memory as a temporary.

Intended use:

Internal

Review Status

Reviewed By:
UNKNOWN
Date Reviewed:
before2004/08/25

Prerequisite

Etymology

TabVecTemp is the class dealing with a table vector when used as a temporary in math operations.

Synopsis

TabVecTemp objects enable the use of Vector objects as table vectors. They are used for 2 purposes:

  1. To convert a Vector to a TableVector. This is used to allow the use of Vectors in TableVector expressions. The TabVecTemp object uses the Vector copy constructor, which is very cheap due to its reference semantics.
  2. To hold the result of an operation (like addition) on two TableVector objects.

Motivation

TabVecTemp is derived from TabVecRep and as such a letter for the envelope class TableVector.

Template Type Argument Requirements (T)

To Do

Definition at line 91 of file TVecTemp.h.


Constructor & Destructor Documentation

template<class T >
casa::TabVecTemp< T >::TabVecTemp ( const Vector< T > &  )

Create table vector containing the given Vector (reference semantics).

It will set the origin to zero.

template<class T >
casa::TabVecTemp< T >::TabVecTemp ( uInt  leng)

Create table vector containing a Vector with given length.

template<class T >
casa::TabVecTemp< T >::~TabVecTemp ( )

Destruct the object.


Member Function Documentation

template<class T >
void casa::TabVecTemp< T >::getVal ( uInt  index,
T &   
) const [virtual]

Get a value (virtual function).

Implements casa::TabVecRep< T >.

template<class T >
const T & casa::TabVecTemp< T >::operator() ( uInt  index) const [inline]

Return a reference to a value.

Definition at line 134 of file TVecTemp.h.

template<class T >
T & casa::TabVecTemp< T >::operator() ( uInt  index) [inline]

Return a reference to a value.

Definition at line 137 of file TVecTemp.h.

template<class T >
void casa::TabVecTemp< T >::putVal ( uInt  index,
const T &   
) [virtual]

Put a value (virtual function).

Implements casa::TabVecRep< T >.

template<class T >
void casa::TabVecTemp< T >::set ( const T &  ) [virtual]

Set entire vector to a value.

Implements casa::TabVecRep< T >.

template<class T >
T casa::TabVecTemp< T >::value ( uInt  index) const [virtual]

Get a value (virtual function).

Implements casa::TabVecRep< T >.


Member Data Documentation

template<class T >
Vector<T>* casa::TabVecTemp< T >::vecPtr_p [protected]

Definition at line 127 of file TVecTemp.h.


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