Hi ,
I am trying to use this plugin option 'useObjectMapperForRequestSerialization' for Kotlin generated classes but it doesn't add useObjectMapper as true for relevant field(in toString method).
I tried to debug the code and found that **
type.ftl
** under template/kotlin-lang doesn't check field.serializeUsingObjectMapper for toString generation.
I did tried to fixed this by updating template as below and tested in local it worked fine and i was able to use custom serializer using internal object mapper.
<#if toStringForRequest> joiner.add("${field.originalName}: " + GraphQLRequestSerializer.getEntry(${field.name}**<#if field.serializeUsingObjectMapper>, true</#if>))**; <#else>
Wanted to know if this is a miss or is there any intent behind leaving this option out for KOTLIN generated classes.
Hi ,
I am trying to use this plugin option 'useObjectMapperForRequestSerialization' for Kotlin generated classes but it doesn't add useObjectMapper as true for relevant field(in toString method).
I tried to debug the code and found that **
** under template/kotlin-lang doesn't check field.serializeUsingObjectMapper for toString generation.
I did tried to fixed this by updating template as below and tested in local it worked fine and i was able to use custom serializer using internal object mapper.
<#if toStringForRequest> joiner.add("${field.originalName}: " + GraphQLRequestSerializer.getEntry(${field.name}**<#if field.serializeUsingObjectMapper>, true</#if>))**; <#else>Wanted to know if this is a miss or is there any intent behind leaving this option out for KOTLIN generated classes.