Fixed namespacing problems + introduced iterator into vector