title: Jackson returning LinkedHashMap from API generated with openapi-codegen
body: <p>I have a Java Backend that serves an openapi.json specification. Its purpose is that is it possible to create an API Client through openapi-generator. This is what I did. The Client comes out just fine, every class is perfect, they all have the properties they should be having and so on. One example is this class:</p>
  <pre><code>public final data class Project public constructor(
      name: kotlin.String,
      title: kotlin.String,
      previewUrl: kotlin.String,
      connections: kotlin.collections.List&lt;kotlin.String&gt;? /* = compiled code */,
      mapWindows: kotlin.collections.List&lt;kotlin.String&gt;? /* = compiled code */,
      ribbons: kotlin.collections.List&lt;kotlin.String&gt;? /* = compiled code */
  ) {
      @field:com.fasterxml.jackson.annotation.JsonProperty public final val connections: kotlin.collections.List&lt;kotlin.String&gt;? /* compiled code */
      @field:com.fasterxml.jackson.annotation.JsonProperty public final val mapWindows: kotlin.collections.List&lt;kotlin.String&gt;? /* compiled code */
      @field:com.fasterxml.jackson.annotation.JsonProperty public final val name: kotlin.String /* compiled code */
      @field:com.fasterxml.jackson.annotation.JsonProperty public final val previewUrl: kotlin.String /* compiled code */
      @field:com.fasterxml.jackson.annotation.JsonProperty public final val ribbons: kotlin.collections.List&lt;kotlin.String&gt;? /* compiled code */
      @field:com.fasterxml.jackson.annotation.JsonProperty public final val title: kotlin.String /* compiled code */
  }
  </code></pre>
  <p>As you see, this class looks just fine.</p>
  <p>Then I have a service containing functions as the following:</p>
  <pre><code>public final fun getProjects(): 
      kotlin.collections.List&lt;bla.bla.bla.Project&gt; {
          /* compiled code */
      }
  </code></pre>
  <p>So, what do I expect when executing this class? As it returns a List of Projects I also expect to get a List of Projects. But instead I get a List of LinkedHashMaps.</p>
  <p><a href="https://i.stack.imgur.com/dKKFZ.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/dKKFZ.png" alt="enter image description here" /></a></p>
  <p>As soon as I worked with these Lists the App will get an exception. It is not possible to cast these LinkedHashMaps over to Project. As soon as I get this List it means 'Game Over'.</p>
  <p>Actually, I have no clue what to do now. I also tried to use moshi or gson when creating the api client but sadly we have really deeply nested classes that did not work out with these.</p>
  <p>Did anyone ever experience something similar?</p>