Main Page | Class Hierarchy | Alphabetical List | Compound List | File List | Compound Members | File Members

legoPArr< T > Class Template Reference

#include <legoPArr.H>

List of all members.

Public Member Functions

 legoPArr ()
 legoPArr (unsigned size, unsigned delta=4)
virtual ~legoPArr ()
 legoPArr (const legoPArr< T > &a, unsigned delta=LARGE_INTVAL)
const legoPArr< T > & operator= (const legoPArr< T > &a)
int operator== (const legoPArr< T > &a)
int operator!= (const legoPArr< T > &a)
T & operator[] (unsigned index)
const T & operator[] (unsigned index) const
unsigned AddItem (T item)
void Insert (T item, unsigned index, unsigned count=1)
void Replace (T item, unsigned index)
void DestroyItem (unsigned index)
virtual unsigned Search (T item, unsigned first, unsigned last, int direction=+1) const
unsigned Search (T item, int direction=+1) const
void SetCount (unsigned newCount)
unsigned GetCount () const
int IsEmpty () const
int IsFull () const
unsigned GetSize () const
unsigned GetDelta () const
void SetDelta (unsigned delta)
void SetSize (unsigned newSize)
void Empty ()
void PEmpty ()
int Valid () const
int IsOwner () const
 legoPArr ()
 legoPArr (unsigned size, unsigned delta=4)
virtual ~legoPArr ()
 legoPArr (const legoPArr< T > &a, unsigned delta=LARGE_INTVAL)
const legoPArr< T > & operator= (const legoPArr< T > &a)
int operator== (const legoPArr< T > &a)
int operator!= (const legoPArr< T > &a)
T & operator[] (unsigned index)
const T & operator[] (unsigned index) const
unsigned AddItem (T item)
void Insert (T item, unsigned index, unsigned count=1)
void Replace (T item, unsigned index)
void DestroyItem (unsigned index)
virtual unsigned Search (T item, unsigned first, unsigned last, int direction=+1) const
unsigned Search (T item, int direction=+1) const
void SetCount (unsigned newCount)
unsigned GetCount () const
int IsEmpty () const
int IsFull () const
unsigned GetSize () const
unsigned GetDelta () const
void SetDelta (unsigned delta)
void SetSize (unsigned newSize)
void Empty ()
void PEmpty ()
int Valid () const
int IsOwner () const

Public Attributes

friend legoPSet<T>

Protected Member Functions

void Expand (unsigned newSize)
void Shrink ()
unsigned ComputeSize (unsigned sz)
void Expand (unsigned newSize)
void Shrink ()
unsigned ComputeSize (unsigned sz)

Protected Attributes

T * data
unsigned _size
unsigned _delta
unsigned count
int shouldDelete
T * data

Friends

class legoPArrItr< T >

template<class T>
class legoPArr< T >


Constructor & Destructor Documentation

template<class T>
legoPArr< T >::legoPArr  ) 
 

Definition at line 339 of file include/legoPArr.H.

References legoPArr< T >::_size, count, legoPArr< T >::data, and legoPArr< T >::shouldDelete.

template<class T>
legoPArr< T >::legoPArr unsigned  size,
unsigned  delta = 4
 

Definition at line 353 of file include/legoPArr.H.

References legoPArr< T >::_size, legoPArr< T >::ComputeSize(), count, legoPArr< T >::data, legoPArr< T >::shouldDelete, and size.

template<class T>
virtual legoPArr< T >::~legoPArr  )  [inline, virtual]
 

Definition at line 98 of file include/legoPArr.H.

template<class T>
legoPArr< T >::legoPArr const legoPArr< T > &  a,
unsigned  delta = LARGE_INTVAL
 

Definition at line 373 of file include/legoPArr.H.

References legoPArr< T >::_delta, legoPArr< T >::_size, legoPArr< T >::ComputeSize(), legoPArr< T >::count, count, legoPArr< T >::data, LARGE_INTVAL, LegoFatal(), memcpy(), legoPArr< T >::shouldDelete, and legoPArr< T >::Valid().

template<class T>
legoPArr< T >::legoPArr  ) 
 

template<class T>
legoPArr< T >::legoPArr unsigned  size,
unsigned  delta = 4
 

template<class T>
virtual legoPArr< T >::~legoPArr  )  [inline, virtual]
 

Definition at line 98 of file src/base/legoPArr.H.

template<class T>
legoPArr< T >::legoPArr const legoPArr< T > &  a,
unsigned  delta = LARGE_INTVAL
 


Member Function Documentation

template<class T>
unsigned legoPArr< T >::AddItem item  ) 
 

template<class T>
unsigned legoPArr< T >::AddItem item  ) 
 

Definition at line 277 of file include/legoPArr.H.

References legoPArr< T >::_size, legoPArr< T >::count, legoPArr< T >::data, legoPArr< T >::Expand(), LegoFatal(), and legoPArr< T >::Valid().

template<class T>
unsigned legoPArr< T >::ComputeSize unsigned  sz  )  [inline, protected]
 

Definition at line 80 of file src/base/legoPArr.H.

template<class T>
unsigned legoPArr< T >::ComputeSize unsigned  sz  )  [inline, protected]
 

Definition at line 80 of file include/legoPArr.H.

Referenced by legoPArr< T >::Expand(), legoPArr< T >::legoPArr(), and legoPArr< T >::Shrink().

template<class T>
void legoPArr< T >::DestroyItem unsigned  index  ) 
 

template<class T>
void legoPArr< T >::DestroyItem unsigned  index  ) 
 

Definition at line 693 of file include/legoPArr.H.

References legoPArr< T >::count, legoPArr< T >::data, index(), LegoFatal(), memmove(), legoPArr< T >::shouldDelete, legoPArr< T >::Shrink(), and legoPArr< T >::Valid().

template<class T>
void legoPArr< T >::Empty  ) 
 

template<class T>
void legoPArr< T >::Empty  ) 
 

Definition at line 669 of file include/legoPArr.H.

References legoPArr< T >::count, and legoPArr< T >::Shrink().

Referenced by legoPArr< T >::PEmpty(), and legoPArr< T >::SetSize().

template<class T>
void legoPArr< T >::Expand unsigned  newSize  )  [protected]
 

template<class T>
void legoPArr< T >::Expand unsigned  newSize  )  [protected]
 

Definition at line 556 of file include/legoPArr.H.

References legoPArr< T >::_delta, legoPArr< T >::_size, legoPArr< T >::ComputeSize(), legoPArr< T >::count, legoPArr< T >::data, LegoFatal(), LegoNonFatal(), memcpy(), and legoPArr< T >::Valid().

Referenced by legoPArr< T >::AddItem(), legoPArr< T >::Insert(), legoPArr< T >::SetDelta(), and legoPArr< T >::SetSize().

template<class T>
unsigned legoPArr< T >::GetCount  )  const [inline]
 

Definition at line 161 of file src/base/legoPArr.H.

template<class T>
unsigned legoPArr< T >::GetCount  )  const [inline]
 

Definition at line 161 of file include/legoPArr.H.

template<class T>
unsigned legoPArr< T >::GetDelta  )  const [inline]
 

Definition at line 172 of file src/base/legoPArr.H.

template<class T>
unsigned legoPArr< T >::GetDelta  )  const [inline]
 

Definition at line 172 of file include/legoPArr.H.

template<class T>
unsigned legoPArr< T >::GetSize void   )  const [inline]
 

Definition at line 171 of file src/base/legoPArr.H.

template<class T>
unsigned legoPArr< T >::GetSize void   )  const [inline]
 

Definition at line 171 of file include/legoPArr.H.

template<class T>
void legoPArr< T >::Insert item,
unsigned  index,
unsigned  count = 1
 

template<class T>
void legoPArr< T >::Insert item,
unsigned  index,
unsigned  count = 1
 

Definition at line 454 of file include/legoPArr.H.

References legoPArr< T >::_size, legoPArr< T >::count, legoPArr< T >::data, legoPArr< T >::Expand(), i, index(), LegoFatal(), memmove(), and legoPArr< T >::Valid().

template<class T>
int legoPArr< T >::IsEmpty  )  const [inline]
 

Definition at line 164 of file src/base/legoPArr.H.

template<class T>
int legoPArr< T >::IsEmpty  )  const [inline]
 

Definition at line 164 of file include/legoPArr.H.

template<class T>
int legoPArr< T >::IsFull  )  const [inline]
 

Definition at line 167 of file src/base/legoPArr.H.

template<class T>
int legoPArr< T >::IsFull  )  const [inline]
 

Definition at line 167 of file include/legoPArr.H.

template<class T>
int legoPArr< T >::IsOwner void   )  const [inline]
 

Definition at line 190 of file src/base/legoPArr.H.

template<class T>
int legoPArr< T >::IsOwner  )  const [inline]
 

Definition at line 190 of file include/legoPArr.H.

template<class T>
int legoPArr< T >::operator!= const legoPArr< T > &  a  )  [inline]
 

Definition at line 110 of file src/base/legoPArr.H.

template<class T>
int legoPArr< T >::operator!= const legoPArr< T > &  a  )  [inline]
 

Definition at line 110 of file include/legoPArr.H.

template<class T>
const legoPArr<T>& legoPArr< T >::operator= const legoPArr< T > &  a  ) 
 

template<class T>
const legoPArr< T > & legoPArr< T >::operator= const legoPArr< T > &  a  ) 
 

Definition at line 396 of file include/legoPArr.H.

References legoPArr< T >::_delta, legoPArr< T >::_size, legoPArr< T >::count, legoPArr< T >::data, LegoFatal(), memcpy(), legoPArr< T >::PEmpty(), legoPArr< T >::shouldDelete, and legoPArr< T >::Valid().

template<class T>
int legoPArr< T >::operator== const legoPArr< T > &  a  ) 
 

template<class T>
int legoPArr< T >::operator== const legoPArr< T > &  a  ) 
 

Definition at line 429 of file include/legoPArr.H.

References legoPArr< T >::count, legoPArr< T >::data, i, LegoFatal(), and legoPArr< T >::Valid().

template<class T>
const T& legoPArr< T >::operator[] unsigned  index  )  const [inline]
 

Definition at line 126 of file src/base/legoPArr.H.

template<class T>
T& legoPArr< T >::operator[] unsigned  index  )  [inline]
 

Definition at line 114 of file src/base/legoPArr.H.

template<class T>
const T& legoPArr< T >::operator[] unsigned  index  )  const [inline]
 

Definition at line 126 of file include/legoPArr.H.

template<class T>
T& legoPArr< T >::operator[] unsigned  index  )  [inline]
 

Definition at line 114 of file include/legoPArr.H.

template<class T>
void legoPArr< T >::PEmpty  ) 
 

template<class T>
void legoPArr< T >::PEmpty  ) 
 

Definition at line 679 of file include/legoPArr.H.

References legoPArr< T >::count, legoPArr< T >::data, legoPArr< T >::Empty(), i, and legoPArr< T >::shouldDelete.

Referenced by legoPArr< T >::operator=(), and legoPArr< void * >::~legoPArr().

template<class T>
void legoPArr< T >::Replace item,
unsigned  index
 

template<class T>
void legoPArr< T >::Replace item,
unsigned  index
 

Definition at line 317 of file include/legoPArr.H.

References legoPArr< T >::count, legoPArr< T >::data, index(), LegoFatal(), legoPArr< T >::shouldDelete, and legoPArr< T >::Valid().

template<class T>
unsigned legoPArr< T >::Search item,
int  direction = +1
const [inline]
 

Definition at line 151 of file src/base/legoPArr.H.

template<class T>
virtual unsigned legoPArr< T >::Search item,
unsigned  first,
unsigned  last,
int  direction = +1
const [virtual]
 

template<class T>
unsigned legoPArr< T >::Search item,
int  direction = +1
const [inline]
 

Definition at line 151 of file include/legoPArr.H.

template<class T>
unsigned legoPArr< T >::Search item,
unsigned  first,
unsigned  last,
int  direction = +1
const [virtual]
 

Definition at line 489 of file include/legoPArr.H.

References count, i, LegoFatal(), LegoNonFatal(), and MAX_UNSIGNED.

Referenced by legoPArr< void * >::Search().

template<class T>
void legoPArr< T >::SetCount unsigned  newCount  ) 
 

template<class T>
void legoPArr< T >::SetCount unsigned  newCount  ) 
 

Definition at line 303 of file include/legoPArr.H.

References legoPArr< T >::count, and legoPArr< T >::SetSize().

template<class T>
void legoPArr< T >::SetDelta unsigned  delta  ) 
 

template<class T>
void legoPArr< T >::SetDelta unsigned  delta  ) 
 

Definition at line 636 of file include/legoPArr.H.

References legoPArr< T >::_delta, legoPArr< T >::_size, legoPArr< T >::Expand(), and legoPArr< T >::Shrink().

template<class T>
void legoPArr< T >::SetSize unsigned  newSize  ) 
 

template<class T>
void legoPArr< T >::SetSize unsigned  newSize  ) 
 

Definition at line 654 of file include/legoPArr.H.

References legoPArr< T >::_delta, legoPArr< T >::Empty(), and legoPArr< T >::Expand().

Referenced by legoPArr< T >::SetCount().

template<class T>
void legoPArr< T >::Shrink  )  [protected]
 

template<class T>
void legoPArr< T >::Shrink  )  [protected]
 

Definition at line 602 of file include/legoPArr.H.

References legoPArr< T >::_delta, legoPArr< T >::_size, legoPArr< T >::ComputeSize(), legoPArr< T >::count, legoPArr< T >::data, LegoFatal(), LegoNonFatal(), memcpy(), and legoPArr< T >::Valid().

Referenced by legoPArr< T >::DestroyItem(), legoPArr< T >::Empty(), and legoPArr< T >::SetDelta().

template<class T>
int legoPArr< T >::Valid  )  const [inline]
 

Definition at line 187 of file src/base/legoPArr.H.

template<class T>
int legoPArr< T >::Valid  )  const [inline]
 

Definition at line 187 of file include/legoPArr.H.

Referenced by legoPArr< T >::AddItem(), legoPArr< T >::DestroyItem(), legoPArr< T >::Expand(), legoPArr< T >::Insert(), legoPArr< T >::legoPArr(), legoPArr< T >::operator=(), legoPArr< T >::operator==(), legoPArr< T >::Replace(), and legoPArr< T >::Shrink().


Friends And Related Function Documentation

template<class T>
legoPArrItr< T > [friend]
 

Definition at line 194 of file include/legoPArr.H.


Member Data Documentation

template<class T>
unsigned legoPArr< T >::_delta [protected]
 

Definition at line 71 of file src/base/legoPArr.H.

Referenced by legoPArr< void * >::ComputeSize(), legoPArr< T >::Expand(), legoPArr< void * >::GetDelta(), legoPArr< void * >::IsFull(), legoPArr< T >::legoPArr(), legoPArr< T >::operator=(), legoPArr< T >::SetDelta(), legoPArr< T >::SetSize(), and legoPArr< T >::Shrink().

template<class T>
unsigned legoPArr< T >::_size [protected]
 

Definition at line 71 of file src/base/legoPArr.H.

Referenced by legoPArr< T >::AddItem(), legoPArr< T >::Expand(), legoPArr< void * >::GetSize(), legoPArr< T >::Insert(), legoPArr< void * >::IsFull(), legoPArr< T >::legoPArr(), legoPArr< T >::operator=(), legoPArr< T >::SetDelta(), and legoPArr< T >::Shrink().

template<class T>
unsigned legoPArr< T >::count [protected]
 

Definition at line 72 of file src/base/legoPArr.H.

Referenced by legoPArr< T >::AddItem(), legoPArr< T >::DestroyItem(), legoPArr< T >::Empty(), legoPArr< T >::Expand(), legoPArr< void * >::GetCount(), legoPArr< T >::Insert(), legoPArr< void * >::IsEmpty(), legoPArr< void * >::IsFull(), legoPArr< T >::legoPArr(), legoPArr< T >::operator=(), legoPArr< T >::operator==(), legoPArr< void * >::operator[](), legoPArr< T >::PEmpty(), legoPArr< T >::Replace(), legoPArr< void * >::Search(), legoPArr< T >::SetCount(), and legoPArr< T >::Shrink().

template<class T>
T* legoPArr< T >::data [protected]
 

Definition at line 70 of file src/base/legoPArr.H.

template<class T>
T* legoPArr< T >::data [protected]
 

Definition at line 70 of file include/legoPArr.H.

Referenced by legoPArr< T >::AddItem(), legoPArr< T >::DestroyItem(), legoPArr< T >::Expand(), legoPArr< T >::Insert(), legoPArr< T >::legoPArr(), legoPArr< T >::operator=(), legoPArr< T >::operator==(), legoPArr< void * >::operator[](), legoPArr< T >::PEmpty(), legoPArr< T >::Replace(), legoPArr< T >::Shrink(), and legoPArr< void * >::Valid().

template<class T>
friend legoPArr< T >::legoPSet<T>
 

Definition at line 89 of file src/base/legoPArr.H.

template<class T>
int legoPArr< T >::shouldDelete [protected]
 

Definition at line 73 of file src/base/legoPArr.H.

Referenced by legoPArr< T >::DestroyItem(), legoPArr< void * >::IsOwner(), legoPArr< T >::legoPArr(), legoPArr< T >::operator=(), legoPArr< T >::PEmpty(), and legoPArr< T >::Replace().


The documentation for this class was generated from the following files:
Generated on Mon Jul 21 20:31:12 2003 for TINKER LEGO DOC by doxygen 1.3.2