Pyrogenesis  13997
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
Functions
ps Namespace Reference

Functions

template<class Container , class T >
void remove_first_occurrence (Container &container, const T &value)
 Removes the first occurrence of the specified value from the container. More...
 
template<class Container , class T >
bool exists_in (const Container &container, const T &value)
 
template<class Container , class T >
Tfind_in (const Container &container, const T &value)
 Finds a value in a container. More...
 

Detailed Description

Author
Jorma Rebane
Note
Pyrogenesis STL methods
This file contains useful and optimized methods for use with STL

Function Documentation

template<class Container , class T >
bool ps::exists_in ( const Container &  container,
const T value 
)
inline
Parameters
containerThe STL-compatible container to search in.
valueThe value to search for.
Returns
TRUE if [value] exists in [container].

Definition at line 61 of file ps_stl.h.

template<class Container , class T >
T* ps::find_in ( const Container &  container,
const T value 
)
inline

Finds a value in a container.

Parameters
containerThe STL-compatible container to search in.
valueThe value to search for.
Returns
Pointer to the value if found, NULL if not found.

Definition at line 83 of file ps_stl.h.

template<class Container , class T >
void ps::remove_first_occurrence ( Container &  container,
const T value 
)
inline

Removes the first occurrence of the specified value from the container.

Parameters
containerThe STL-compatible container to remove from.
valueThe value to remove.

Definition at line 39 of file ps_stl.h.