Add javadoc to getNameForFunction