Main Page | Modules | Namespace List | Class Hierarchy | Alphabetical List | Class List | File List | Namespace Members | Class Members | File Members

BTK::SharedVectorBase< T > Class Template Reference

A container that behaves like std::vector, with additional shallow-copy services. More...

#include <shared_vector_base.h>

Inheritance diagram for BTK::SharedVectorBase< T >:

Inheritance graph
[legend]
List of all members.

Public Types

typedef SharedVectorBase< T > self_type
STL-required container typedefs
typedef T value_type
typedef value_typereference
typedef const reference const_reference
typedef value_typepointer
typedef const pointer const_pointer
typedef container_type::size_type size_type
typedef boost::indirect_iterator<
direct_iterator > 
iterator
typedef boost::indirect_iterator<
const_direct_iterator > 
const_iterator

Public Member Functions

 SharedVectorBase (size_type s=0)
template<typename InputIterator>  SharedVectorBase (InputIterator first, InputIterator last)
 SharedVectorBase (const self_type &source)
template<typename T2>  SharedVectorBase (const SharedVectorBase< T2 > &source)
virtual ~SharedVectorBase ()
self_typeoperator= (const self_type &rhs)
template<typename T2> self_typeoperator= (const SharedVectorBase< T2 > &rhs)
Replicated std::vector interface (public)
size_type size () const
 Replication of std::vector function (see std::vector documentation).

iterator begin ()
 Replication of std::vector function (see std::vector documentation).

const_iterator begin () const
 Replication of std::vector function (see std::vector documentation).

iterator end ()
 Replication of std::vector function (see std::vector documentation).

const_iterator end () const
 Replication of std::vector function (see std::vector documentation).

reference operator[] (size_type i)
 Replication of std::vector function (see std::vector documentation).

const_reference operator[] (size_type i) const
 Replication of std::vector function (see std::vector documentation).

reference front ()
 Replication of std::vector function (see std::vector documentation).

const_reference front () const
 Replication of std::vector function (see std::vector documentation).

reference back ()
 Replication of std::vector function (see std::vector documentation).

const_reference back () const
 Replication of std::vector function (see std::vector documentation).


Protected Member Functions

Replicated std::vector interface (protected)
void clear ()
 Replication of std::vector function (see std::vector documentation).

void resize (size_type s)
 Replication of std::vector function (see std::vector documentation).

void reserve (size_type s)
 Replication of std::vector function (see std::vector documentation).

void push_back (const value_type &x)
 Replication of std::vector function (see std::vector documentation).

iterator insert (iterator pos, const value_type &x)
 Replication of std::vector function (see std::vector documentation).

void insert (iterator pos, size_type s, const value_type &x)
 Replication of std::vector function (see std::vector documentation).

template<typename InputIterator> void insert (iterator pos, InputIterator first, InputIterator last)
 Replication of std::vector function (see std::vector documentation).

iterator erase (iterator pos)
 Replication of std::vector function (see std::vector documentation).

iterator erase (iterator first, iterator last)
 Replication of std::vector function (see std::vector documentation).

Shallow std::vector-like functions
void shallow_push_back (value_type *x)
void shallow_insert (iterator pos, const_iterator first, const_iterator last)
Self copy functions
template<typename T2> void deep_copy (const SharedVectorBase< T2 > &source)
void shallow_copy (const self_type &source)

Detailed Description

template<typename T>
class BTK::SharedVectorBase< T >

A container that behaves like std::vector, with additional shallow-copy services.

SharedVectorBase is a container that behaves like a std::vector; it implements a subset of the std::vector interface except that most non-const functions protected; It also includes shallow copy/insert services between other SharedVectorBase objects, so that the same object can be shared between multple vector-like containers.

See also:
SharedVector


Member Typedef Documentation

template<typename T>
typedef boost::indirect_iterator<const_direct_iterator> BTK::SharedVectorBase< T >::const_iterator
 

Reimplemented in BTK::AtomContainer< AtomType >, BTK::BuildableMonomer< AtomType >, BTK::Molecule< AtomType >, BTK::Monomer< AtomType >, BTK::MonomerContainer< MonomerType >, BTK::PeptideBB< AtomType >, BTK::PeptideHeavyAtom< AtomType >, BTK::Polymer< MonomerType >, BTK::SharedVector< T >, BTK::AtomContainer< typename MonomerType::atom_type >, and BTK::Molecule< typename MonomerType::atom_type >.

template<typename T>
typedef const pointer BTK::SharedVectorBase< T >::const_pointer
 

Reimplemented in BTK::AtomContainer< AtomType >, BTK::BuildableMonomer< AtomType >, BTK::Molecule< AtomType >, BTK::Monomer< AtomType >, BTK::MonomerContainer< MonomerType >, BTK::PeptideBB< AtomType >, BTK::PeptideHeavyAtom< AtomType >, BTK::Polymer< MonomerType >, BTK::SharedVector< T >, BTK::AtomContainer< typename MonomerType::atom_type >, and BTK::Molecule< typename MonomerType::atom_type >.

template<typename T>
typedef const reference BTK::SharedVectorBase< T >::const_reference
 

Reimplemented in BTK::AtomContainer< AtomType >, BTK::BuildableMonomer< AtomType >, BTK::Molecule< AtomType >, BTK::Monomer< AtomType >, BTK::MonomerContainer< MonomerType >, BTK::PeptideBB< AtomType >, BTK::PeptideHeavyAtom< AtomType >, BTK::Polymer< MonomerType >, BTK::SharedVector< T >, BTK::AtomContainer< typename MonomerType::atom_type >, and BTK::Molecule< typename MonomerType::atom_type >.

template<typename T>
typedef boost::indirect_iterator<direct_iterator> BTK::SharedVectorBase< T >::iterator
 

Reimplemented in BTK::AtomContainer< AtomType >, BTK::BuildableMonomer< AtomType >, BTK::Molecule< AtomType >, BTK::Monomer< AtomType >, BTK::MonomerContainer< MonomerType >, BTK::PeptideBB< AtomType >, BTK::PeptideHeavyAtom< AtomType >, BTK::Polymer< MonomerType >, BTK::SharedVector< T >, BTK::AtomContainer< typename MonomerType::atom_type >, and BTK::Molecule< typename MonomerType::atom_type >.

template<typename T>
typedef value_type* BTK::SharedVectorBase< T >::pointer
 

Reimplemented in BTK::AtomContainer< AtomType >, BTK::BuildableMonomer< AtomType >, BTK::Molecule< AtomType >, BTK::Monomer< AtomType >, BTK::MonomerContainer< MonomerType >, BTK::PeptideBB< AtomType >, BTK::PeptideHeavyAtom< AtomType >, BTK::Polymer< MonomerType >, BTK::SharedVector< T >, BTK::AtomContainer< typename MonomerType::atom_type >, and BTK::Molecule< typename MonomerType::atom_type >.

template<typename T>
typedef value_type& BTK::SharedVectorBase< T >::reference
 

Reimplemented in BTK::AtomContainer< AtomType >, BTK::BuildableMonomer< AtomType >, BTK::Molecule< AtomType >, BTK::Monomer< AtomType >, BTK::MonomerContainer< MonomerType >, BTK::PeptideBB< AtomType >, BTK::PeptideHeavyAtom< AtomType >, BTK::Polymer< MonomerType >, BTK::SharedVector< T >, BTK::AtomContainer< typename MonomerType::atom_type >, and BTK::Molecule< typename MonomerType::atom_type >.

template<typename T>
typedef SharedVectorBase<T> BTK::SharedVectorBase< T >::self_type
 

Reimplemented in BTK::Molecule< AtomType >, BTK::SharedVector< T >, and BTK::Molecule< typename MonomerType::atom_type >.

template<typename T>
typedef container_type::size_type BTK::SharedVectorBase< T >::size_type
 

Reimplemented in BTK::AtomContainer< AtomType >, BTK::BuildableMonomer< AtomType >, BTK::Molecule< AtomType >, BTK::Monomer< AtomType >, BTK::MonomerContainer< MonomerType >, BTK::PeptideBB< AtomType >, BTK::PeptideHeavyAtom< AtomType >, BTK::Polymer< MonomerType >, BTK::SharedVector< T >, BTK::AtomContainer< typename MonomerType::atom_type >, and BTK::Molecule< typename MonomerType::atom_type >.

template<typename T>
typedef T BTK::SharedVectorBase< T >::value_type
 

Reimplemented in BTK::AtomContainer< AtomType >, BTK::BuildableMonomer< AtomType >, BTK::Molecule< AtomType >, BTK::Monomer< AtomType >, BTK::MonomerContainer< MonomerType >, BTK::PeptideBB< AtomType >, BTK::PeptideHeavyAtom< AtomType >, BTK::Polymer< MonomerType >, BTK::SharedVector< T >, BTK::AtomContainer< typename MonomerType::atom_type >, and BTK::Molecule< typename MonomerType::atom_type >.


Constructor & Destructor Documentation

template<typename T>
BTK::SharedVectorBase< T >::SharedVectorBase size_type  s = 0  )  [inline]
 

template<typename T>
template<typename InputIterator>
BTK::SharedVectorBase< T >::SharedVectorBase InputIterator  first,
InputIterator  last
 

Here is the call graph for this function:

template<typename T>
BTK::SharedVectorBase< T >::SharedVectorBase const self_type source  )  [inline]
 

template<typename T>
template<typename T2>
BTK::SharedVectorBase< T >::SharedVectorBase const SharedVectorBase< T2 > &  source  )  [inline]
 

template<typename T>
virtual BTK::SharedVectorBase< T >::~SharedVectorBase  )  [inline, virtual]
 


Member Function Documentation

template<typename T>
const_reference BTK::SharedVectorBase< T >::back  )  const [inline]
 

Replication of std::vector function (see std::vector documentation).

template<typename T>
reference BTK::SharedVectorBase< T >::back  )  [inline]
 

Replication of std::vector function (see std::vector documentation).

template<typename T>
const_iterator BTK::SharedVectorBase< T >::begin  )  const [inline]
 

Replication of std::vector function (see std::vector documentation).

template<typename T>
iterator BTK::SharedVectorBase< T >::begin  )  [inline]
 

Replication of std::vector function (see std::vector documentation).

template<typename T>
void BTK::SharedVectorBase< T >::clear  )  [inline, protected]
 

Replication of std::vector function (see std::vector documentation).

template<typename T>
template<typename T2>
void BTK::SharedVectorBase< T >::deep_copy const SharedVectorBase< T2 > &  source  )  [protected]
 

Here is the call graph for this function:

template<typename T>
const_iterator BTK::SharedVectorBase< T >::end  )  const [inline]
 

Replication of std::vector function (see std::vector documentation).

template<typename T>
iterator BTK::SharedVectorBase< T >::end  )  [inline]
 

Replication of std::vector function (see std::vector documentation).

template<typename T>
iterator BTK::SharedVectorBase< T >::erase iterator  first,
iterator  last
[inline, protected]
 

Replication of std::vector function (see std::vector documentation).

template<typename T>
iterator BTK::SharedVectorBase< T >::erase iterator  pos  )  [inline, protected]
 

Replication of std::vector function (see std::vector documentation).

template<typename T>
const_reference BTK::SharedVectorBase< T >::front  )  const [inline]
 

Replication of std::vector function (see std::vector documentation).

template<typename T>
reference BTK::SharedVectorBase< T >::front  )  [inline]
 

Replication of std::vector function (see std::vector documentation).

template<typename T>
template<typename InputIterator>
void BTK::SharedVectorBase< T >::insert iterator  pos,
InputIterator  first,
InputIterator  last
[protected]
 

Replication of std::vector function (see std::vector documentation).

Reimplemented in BTK::SharedVector< T >.

template<typename T>
void BTK::SharedVectorBase< T >::insert iterator  pos,
size_type  s,
const value_type x
[protected]
 

Replication of std::vector function (see std::vector documentation).

template<typename T>
iterator BTK::SharedVectorBase< T >::insert iterator  pos,
const value_type x
[inline, protected]
 

Replication of std::vector function (see std::vector documentation).

template<typename T>
template<typename T2>
self_type& BTK::SharedVectorBase< T >::operator= const SharedVectorBase< T2 > &  rhs  )  [inline]
 

template<typename T>
self_type& BTK::SharedVectorBase< T >::operator= const self_type rhs  )  [inline]
 

Reimplemented in BTK::AtomContainer< AtomType >, BTK::BuildableMonomer< AtomType >, BTK::Molecule< AtomType >, BTK::MonomerContainer< MonomerType >, BTK::Polymer< MonomerType >, BTK::SharedVector< T >, BTK::AtomContainer< typename MonomerType::atom_type >, and BTK::Molecule< typename MonomerType::atom_type >.

template<typename T>
const_reference BTK::SharedVectorBase< T >::operator[] size_type  i  )  const [inline]
 

Replication of std::vector function (see std::vector documentation).

template<typename T>
reference BTK::SharedVectorBase< T >::operator[] size_type  i  )  [inline]
 

Replication of std::vector function (see std::vector documentation).

template<typename T>
void BTK::SharedVectorBase< T >::push_back const value_type x  )  [inline, protected]
 

Replication of std::vector function (see std::vector documentation).

template<typename T>
void BTK::SharedVectorBase< T >::reserve size_type  s  )  [inline, protected]
 

Replication of std::vector function (see std::vector documentation).

template<typename T>
void BTK::SharedVectorBase< T >::resize size_type  s  )  [inline, protected]
 

Replication of std::vector function (see std::vector documentation).

template<typename T>
void BTK::SharedVectorBase< T >::shallow_copy const self_type source  )  [protected]
 

Here is the call graph for this function:

template<typename T>
void BTK::SharedVectorBase< T >::shallow_insert iterator  pos,
const_iterator  first,
const_iterator  last
[inline, protected]
 

template<typename T>
void BTK::SharedVectorBase< T >::shallow_push_back value_type x  )  [inline, protected]
 

template<typename T>
size_type BTK::SharedVectorBase< T >::size  )  const [inline]
 

Replication of std::vector function (see std::vector documentation).


The documentation for this class was generated from the following files:
Generated on Wed Apr 14 00:43:28 2004 for BTK by doxygen 1.3.6