templating some std::vector container in order to use both set and vecto...

Small add of container templating in order to avoid some container conversions (from std::set and std::vector)