Added support for const and non const iterators