Added FunctorGeneric classes and tests