_VDBL_colbase< _TR > Class Template Reference
[Classes and types for internal use]

The type dependent base class of the internal column structure. More...

#include <vdbl_col.h>

Inheritance diagram for _VDBL_colbase< _TR >:

Inheritance graph
[legend]
Collaboration diagram for _VDBL_colbase< _TR >:

Collaboration graph
[legend]

List of all members.

Public Types

typedef _TR return_type
 return_type is the type of object stored

Public Member Functions

virtual _Selfnew_copy () const VDBL_PURE_VIRTUALvirtual void setcontext(const context *_c
virtual _Self *const _VDBL_row
*_r virtual VDBL_PURE_VIRTUAL
void 
get (return_type &c) const VDBL_PURE_VIRTUALvirtual void def(return_type &d) const VDBL_PURE_VIRTUALvirtual void get_ptr(return_type const *&c) const VDBL_PURE_VIRTUALvirtual void get_copy(return_type *&c) const
virtual void def_copy (return_type *&d) const
virtual void get_copy (_VDBL_alltype_base *&v) const
virtual void def_copy (_VDBL_alltype_base *&v) const
virtual const std::type_info & return_type_id () const
virtual std::ostream & print_contents (std::ostream &o) const
 _VDBL_colbase ()
 _VDBL_colbase (const _Self &__c)
virtual ~_VDBL_colbase ()


Detailed Description

template<class _TR>
class _VDBL_colbase< _TR >

_VDBL_colbase is the templated base class of all columns of the same type - for copy-constructor and get-operation overload. This class is the second step. The first step is done in __VDBL_colbase, which makes columns "type independent". The second step makes it possible to have different kinds of columns of the same type. All type dependent member functions are virtual in this class.

Definition at line 132 of file vdbl_col.h.


Constructor & Destructor Documentation

template<class _TR>
_VDBL_colbase< _TR >::_VDBL_colbase (  )  [inline]

standard constructor, copy constructor, and destructor

Definition at line 144 of file vdbl_col.h.

template<class _TR>
_VDBL_colbase< _TR >::_VDBL_colbase ( const _Self __c  )  [inline]

standard constructor, copy constructor, and destructor

Definition at line 145 of file vdbl_col.h.

template<class _TR>
virtual _VDBL_colbase< _TR >::~_VDBL_colbase (  )  [inline, virtual]

standard constructor, copy constructor, and destructor

Definition at line 146 of file vdbl_col.h.


Member Function Documentation

template<class _TR>
virtual void _VDBL_colbase< _TR >::def_copy ( _VDBL_alltype_base *&  v  )  const [inline, virtual]

This version of get_copy returns a copy of the columns default value within an alltype. This is useful for passing on column values. It can also be used to circumvent the strict run-time type checking. The user is, however, DISCOURAGED to do so.

Reimplemented in _VDBL_stdcol< _TT >, and _VDBL_stdcol< _TT >.

Definition at line 210 of file vdbl_col.h.

template<class _TR>
virtual void _VDBL_colbase< _TR >::def_copy ( return_type *&  d  )  const [inline, virtual]

This function returns a pointer to a copy of the column's default value. The copy of the value is allocated by new. It has to be deleted by the user to avoid memory leaks.

Definition at line 188 of file vdbl_col.h.

template<class _TR>
virtual _Self* const _VDBL_row* _r virtual VDBL_PURE_VIRTUAL void _VDBL_colbase< _TR >::get ( return_type c  )  const [inline, virtual]

This function stores a copy of the column value into c. This function stores a copy of the column default value into d. This function sets c to a const pointer pointing to the column's actual value. Here, no copying is done. This function returns a pointer to a copy of the column's value. The copy of the value is allocated by new. It has to be deleted by the user to avoid memory leaks.

Reimplemented in _VDBL_stdcol< _TT >, _VDBL_mthdcol< _TC, _TM, _TR >, _VDBL_stdcol< _TT >, and _VDBL_mthdcol< _TM::context, _TM, _TM::return_type >.

Definition at line 162 of file vdbl_col.h.

template<class _TR>
virtual void _VDBL_colbase< _TR >::get_copy ( _VDBL_alltype_base *&  v  )  const [inline, virtual]

This version of get_copy returns a copy of the columns value within an alltype. This is useful for passing on column values. It can also be used to circumvent the strict run-time type checking. The user is, however, DISCOURAGED to do so.

Reimplemented in _VDBL_stdcol< _TT >, and _VDBL_stdcol< _TT >.

Definition at line 197 of file vdbl_col.h.

template<class _TR>
virtual _Self* _VDBL_colbase< _TR >::new_copy (  )  const [virtual]

new_copy is the clone operation for copy-constructor overloading. setcontext sets the context for value retrieval.

Reimplemented from __VDBL_colbase.

Reimplemented in _VDBL_stdcol< _TT >, _VDBL_mthdcol< _TC, _TM, _TR >, _VDBL_stdcol< _TT >, and _VDBL_mthdcol< _TM::context, _TM, _TM::return_type >.

template<class _TR>
virtual std::ostream& _VDBL_colbase< _TR >::print_contents ( std::ostream &  o  )  const [inline, virtual]

This function is needed for the operator<< for columns of type return_type.

Reimplemented in _VDBL_stdcol< _TT >, _VDBL_mthdcol< _TC, _TM, _TR >, _VDBL_stdcol< _TT >, and _VDBL_mthdcol< _TM::context, _TM, _TM::return_type >.

Definition at line 228 of file vdbl_col.h.

template<class _TR>
virtual const std::type_info& _VDBL_colbase< _TR >::return_type_id (  )  const [inline, virtual]

This function returns the type_info of the column type. This information is used during run-time type checking.

Definition at line 221 of file vdbl_col.h.


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

Generated on Tue Feb 9 14:59:34 2010 for Vienna Database Library by  doxygen 1.5.8