moved overloaded swap functions to their own class