11package  com.fasterxml.jackson.module.kotlin 
22
3- import  com.fasterxml.jackson.annotation.JsonCreator 
43import  com.fasterxml.jackson.annotation.JsonProperty 
54import  com.fasterxml.jackson.databind.JavaType 
65import  com.fasterxml.jackson.databind.cfg.MapperConfig 
76import  com.fasterxml.jackson.databind.introspect.Annotated 
87import  com.fasterxml.jackson.databind.introspect.AnnotatedClass 
9- import  com.fasterxml.jackson.databind.introspect.AnnotatedConstructor 
108import  com.fasterxml.jackson.databind.introspect.AnnotatedMember 
119import  com.fasterxml.jackson.databind.introspect.AnnotatedMethod 
1210import  com.fasterxml.jackson.databind.introspect.AnnotatedParameter 
@@ -16,18 +14,15 @@ import java.lang.reflect.Constructor
1614import  java.util.Locale 
1715import  kotlin.reflect.KClass 
1816import  kotlin.reflect.KFunction 
19- import  kotlin.reflect.full.companionObject 
20- import  kotlin.reflect.full.declaredFunctions 
2117import  kotlin.reflect.full.hasAnnotation 
2218import  kotlin.reflect.full.memberProperties 
2319import  kotlin.reflect.full.primaryConstructor 
24- import  kotlin.reflect.jvm.javaConstructor 
2520import  kotlin.reflect.jvm.javaGetter 
2621import  kotlin.reflect.jvm.javaType 
2722
2823internal  class  KotlinNamesAnnotationIntrospector (
2924    private  val  cache :  ReflectionCache ,
30-     private  val  useKotlinPropertyNameForGetter :  Boolean 
25+     private  val  kotlinPropertyNameAsImplicitName :  Boolean 
3126) : NopAnnotationIntrospector() {
3227    private  fun  getterNameFromJava (member :  AnnotatedMethod ): String?  {
3328        val  name =  member.name
@@ -67,7 +62,7 @@ internal class KotlinNamesAnnotationIntrospector(
6762
6863        return  when  (member) {
6964            is  AnnotatedMethod  ->  if  (member.parameterCount ==  0 ) {
70-                 if  (useKotlinPropertyNameForGetter ) {
65+                 if  (kotlinPropertyNameAsImplicitName ) {
7166                    //  Fall back to default if it is a getter-like function
7267                    getterNameFromKotlin(member) ? :  getterNameFromJava(member)
7368                } else  getterNameFromJava(member)
0 commit comments