Introduce a static method `nameGetter()` that returns this function.