title: kotlin inner class cant access private method outside?
body: <p>Hi i am new to kotlin and trying to simply invoke a private function from inside a inner anonymous class.</p>
  
  <p>Below is the call:</p>
  
  <pre><code>      object callback : Callback&lt;ResponseBody&gt; {
          override fun onResponse(call: Call&lt;ResponseBody&gt;?, response: Response&lt;ResponseBody&gt;?) {
  
              Log.d("jjj", " response is " + response.toString())
              displaySuccess()
  
          }
  
          override fun onFailure(call: Call&lt;ResponseBody&gt;?, t: Throwable?) {
          }
  
      }
  
  
  
        private fun displaySuccess(){
          Toast.makeText(activity,"succesful", Toast.LENGTH_LONG)
      }
  </code></pre>
  
  <p>both these snippet of code resides on a Fragment class and displaySuccess cant be accessed inside onResponse?</p>