24 template <
class T,
class CONTAINER>
30 return std::string::npos;
39 return cont.erase(it);
42 template <
class K,
class V>
52 template <
class K,
class V>
110 cout <<
"List " << i + 1 <<
"/" <<
t.size() << endl <<
"\t";
121 template <
class T1,
class T2>
123 const std::map<T1, T2>& m,
const std::string& sep =
" => ")
131 ss << it->first <<
" => " << it->second << endl;
140 template <
class T1,
class T2>
std::string getMapAsString(const std::map< T1, T2 > &m, const std::string &sep=" => ")
Return contents of map in a string representation.
void printSTLContainer(const T &t)
Print the given vector t.
size_t find_in_vector(const T &value, const CONTAINER &vect)
Returns the index of the value "T" in the container "vect" (std::vector,std::deque,etc), or string::npos if not found.
std::list< T >::iterator erase_return_next(std::list< T > &cont, typename std::list< T >::iterator &it)
Calls the standard "erase" method of a STL container, but also returns an iterator to the next elemen...
GLsizei const GLchar ** string
void printMap(const std::map< T1, T2 > &m)
Print the given map m.
void printSTLContainerOfContainers(const T &t)
Print the given STL container of containers t.
GLsizei const GLfloat * value
const Scalar * const_iterator
std::string getSTLContainerAsString(const T &t)
Return a STL container in std::string form.
double distance(const TPoint2D &p1, const TPoint2D &p2)
Gets the distance between two points in a 2D space.