// SWIG typemaps for std::list types
// Modified from: Jing Cao
template<class T> class list
typedef const T& const_reference;
typedef const T& const_iterator;
list(unsigned int size, const T& value = T());
void assign(unsigned int n, const T& value);
void resize(unsigned int n, T c = T());
void push_front(const T& x);
void push_back(const T& x);
unsigned int size() const;
unsigned int max_size() const;
void resize(unsigned int n, const T& value);
void remove(const T& value);
const_reference __getitem__(int i) throw (std::out_of_range)
std::list<T>::iterator first = self->begin();
int size = int(self->size());
else throw std::out_of_range("list index out of range");
void __setitem__(int i, const T& x) throw (std::out_of_range)
std::list<T>::iterator first = self->begin();
int size = int(self->size());
else throw std::out_of_range("list index out of range");
void __delitem__(int i) throw (std::out_of_range)
std::list<T>::iterator first = self->begin();
int size = int(self->size());
else throw std::out_of_range("list index out of range");
std::list<T> __getslice__(int i,int j)
std::list<T>::iterator first = self->begin();
std::list<T>::iterator end = self->end();
int size = int(self->size());
if (i>=0 && i<size && j>=0)
if (j>i) std::copy(first,end,tmp.begin());
else throw std::out_of_range("list index out of range");
void __delslice__(int i,int j)
std::list<T>::iterator first = self->begin();
std::list<T>::iterator end = self->end();
int size = int(self->size());
void __setslice__(int i,int j, const std::list<T>& v)
std::list<T>::iterator first = self->begin();
std::list<T>::iterator end = self->end();
int size = int(self->size());
if (int(v.size()) == j-i)
std::copy(v.begin(),v.end(),first);
if (i+1 <= int(self->size()))
self->insert(first,v.begin(),v.end());
else self->insert(self->end(),v.begin(),v.end());