Refactored using perfect forwarding.
Refactored overload definitions using variadic templates.