4 ACE_BEGIN_VERSIONED_NAMESPACE_DECL
6 template <class T, size_t DEFAULT_SIZE> ACE_INLINE
7 ACE_Vector<T, DEFAULT_SIZE>::ACE_Vector (const size_t init_size,
9 : ACE_Array<T> (init_size == 0 ? DEFAULT_SIZE : init_size, alloc),
12 this->curr_max_size_ = this->max_size ();
15 template <class T, size_t DEFAULT_SIZE> ACE_INLINE
16 size_t ACE_Vector<T, DEFAULT_SIZE>::capacity () const
18 return curr_max_size_;
21 template <class T, size_t DEFAULT_SIZE> ACE_INLINE
22 size_t ACE_Vector<T, DEFAULT_SIZE>::size () const
27 template <class T, size_t DEFAULT_SIZE> ACE_INLINE
28 void ACE_Vector<T, DEFAULT_SIZE>::clear ()
33 template <class T, size_t DEFAULT_SIZE> ACE_INLINE
34 void ACE_Vector<T, DEFAULT_SIZE>::pop_back ()
39 ACE_Array<T>::size (length_);
43 template <class T, size_t DEFAULT_SIZE> ACE_INLINE
44 typename ACE_Array_Base<T>::iterator ACE_Vector<T, DEFAULT_SIZE>::end ()
46 return ACE_Array_Base<T>::array_ + length_;
49 template <class T, size_t DEFAULT_SIZE> ACE_INLINE
50 typename ACE_Array_Base<T>::const_iterator ACE_Vector<T, DEFAULT_SIZE>::end () const
52 return ACE_Array_Base<T>::array_ + length_;
55 // Compare this vector with <s> for inequality.
57 template <class T, size_t DEFAULT_SIZE> ACE_INLINE bool
58 ACE_Vector<T, DEFAULT_SIZE>::operator!= (const ACE_Vector<T, DEFAULT_SIZE> &s) const
63 template <class T, size_t DEFAULT_SIZE> ACE_INLINE void
64 ACE_Vector<T, DEFAULT_SIZE>::swap (ACE_Vector &rhs)
66 ACE_Array<T>::swap (rhs);
67 std::swap (this->length_, rhs.length_);
68 std::swap (this->curr_max_size_, rhs.curr_max_size_);
71 // ****************************************************************
73 template <class T, size_t DEFAULT_SIZE> ACE_INLINE void
74 ACE_Vector_Iterator<T, DEFAULT_SIZE>::dump () const
76 // ACE_TRACE ("ACE_Vector_Iterator<T>::dump");
79 template <class T, size_t DEFAULT_SIZE> ACE_INLINE
80 ACE_Vector_Iterator<T, DEFAULT_SIZE>::ACE_Vector_Iterator (ACE_Vector<T, DEFAULT_SIZE> &v)
84 // ACE_TRACE ("ACE_Vector_Iterator<T>::ACE_Vector_Iterator");
87 template <class T, size_t DEFAULT_SIZE> ACE_INLINE int
88 ACE_Vector_Iterator<T, DEFAULT_SIZE>::advance ()
90 // ACE_TRACE ("ACE_Vector_Iterator<T>::advance");
92 if (this->current_ < vector_.size ())
98 // Already finished iterating.
102 template <class T, size_t DEFAULT_SIZE> ACE_INLINE int
103 ACE_Vector_Iterator<T, DEFAULT_SIZE>::done () const
105 ACE_TRACE ("ACE_Vector_Iterator<T>::done");
107 return this->current_ >= vector_.size ();
110 ACE_END_VERSIONED_NAMESPACE_DECL