stlab.adobe.com Adobe Systems Incorporated

erase [review]
[Container Algorithms]

Functions

template<typename T >
T::iterator erase (T &x, typename T::iterator f, typename T::iterator l)
template<typename T , typename R >
T::iterator erase (T &x, const R &r)
template<typename T >
T::iterator erase (T &x, typename T::iterator f)
template<typename T , typename P >
void erase_if (T &x, typename T::iterator f, typename T::iterator l, P p)
template<typename T , typename P >
void erase_if (T &x, P p)

Detailed Description

The current erase member function on containers does not have a uniform interface. The erase algorithm here provides a normalized interface to erase on all containers.

The erase_if algorithm erases any value from the container (within the optionally supplied range) which satisfies the predicate. The erase is handled efficiently for any container type.

Complexity Guarantees:
Linear. Exactly last - first applications of pred.

Function Documentation

T::iterator adobe::erase ( T &  x,
typename T::iterator  f,
typename T::iterator  l 
)

Definition at line 63 of file erase_if.hpp.

T::iterator adobe::erase ( T &  x,
const R &  r 
)

Definition at line 75 of file erase_if.hpp.

T::iterator adobe::erase ( T &  x,
typename T::iterator  f 
)

Definition at line 85 of file erase_if.hpp.

void adobe::erase_if ( T &  x,
typename T::iterator  f,
typename T::iterator  l,
p 
)

Definition at line 119 of file erase_if.hpp.

void adobe::erase_if ( T &  x,
p 
)

Definition at line 130 of file erase_if.hpp.

Copyright © 2006-2007 Adobe Systems Incorporated.

Use of this website signifies your agreement to the Terms of Use and Online Privacy Policy.

Search powered by Google