byReturnType initial implementation.
byReturnType implementation. Refactoring.