Changeset 5466 in orxonox.OLD for trunk/src/lib/util/t_stack.h
- Timestamp:
- Nov 3, 2005, 12:34:05 AM (20 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/lib/util/t_stack.h
r5388 r5466 27 27 28 28 //! Stack Class that handles dynamic-type Stacks. 29 template< classT>30 29 template<typename T> 30 class tStack 31 31 { 32 32 public: … … 39 39 /** @returns the Size of the Stack (0 if empty) */ 40 40 unsigned int getSize() { return this->entryCount; }; 41 42 // stack copying. 43 // tStack<T>& operator= (const tStack<T>& stack); 41 44 42 45 void debug() const ; … … 52 55 53 56 unsigned int entryCount; //!< The count of Entries in this Array. 54 tStackEntry* topEntry; //!< Pointer to the first Entry of this Array57 tStackEntry* topEntry; //!< Pointer to the first Entry of this Array 55 58 }; 56 59 … … 58 61 * creates and initializes a Stack 59 62 */ 60 template< classT>63 template<typename T> 61 64 tStack<T>::tStack() 62 65 { … … 69 72 * This does not delete the entries of the Stack 70 73 */ 71 template< classT>74 template<typename T> 72 75 tStack<T>::~tStack() 73 76 { … … 86 89 * @param entry the Entry to push into the Stack 87 90 */ 88 template< classT>91 template<typename T> 89 92 void tStack<T>::push(T entry) 90 93 { … … 102 105 * @returns the top-most enrty. 103 106 */ 104 template< classT>107 template<typename T> 105 108 T tStack<T>::pop() 106 109 { … … 117 120 118 121 /** 119 * @returns the topMost entry of the Stack 122 * @returns the topMost entry of the Stack without removing it. 120 123 */ 121 template< classT>124 template<typename T> 122 125 T tStack<T>::getTop() 123 126 {
Note: See TracChangeset
for help on using the changeset viewer.