33#ifndef __H__UTIL__ARRAY_UTIL__
34#define __H__UTIL__ARRAY_UTIL__
56 for(i = 0; i < size; ++i)
67 for(; i < size - 1; ++i)
68 array[i] = array[i+1];
86 for(i = 0; i < size; ++i){
96 swap(array[i], array[size - 1]);
105template <
class TType>
107 const TType& oldEntry,
size_t size)
111 for(i = 0; i < size; ++i)
113 if(array[i] == oldEntry){
void ArraySwapWithLast(TType *array, const TType &entry, size_t size)
Swaps the first entry with the given value with the last entry in the list.
Definition array_util.h:81
bool ArrayReplaceEntry(TType *array, const TType &newEntry, const TType &oldEntry, size_t size)
replaces the first occurance of oldEntry with newEntry
Definition array_util.h:106
int ArrayEraseEntry(TType *array, const TType &entry, size_t size)
removes the first occurance of the specified entry.
Definition array_util.h:52
Definition smart_pointer.h:814