title: extension function for Kotlin data class
body: <p>I have a data class which looks something like this </p>
  
  <pre><code>data class SuggestionResponse(
    val metadata: Metadata,
    val response: Response
  )
  
  data class Response(
   ///blah blah
  )
  
  data class Metadata(
    val timeleft: String,
    val totalTime: String
  )
  </code></pre>
  
  <p>Now my requirement to transform this data into a different type of data object.I  want to write an extension function to do this task. let the name of function be hello</p>
  
  <p>I would like to call this extension function like this</p>
  
  <p><code>suggestionResponse.hello()</code></p>
  
  <p>how do I write the extension function?.any help would be appreciated</p>