Package 

Interface Callback

    • Method Summary

      Modifier and Type Method Description
      abstract void onFailure(Call call, IOException e) Called when the mobonRequest could not be executed due to cancellation, a connectivity problem ortimeout.
      abstract void onResponse(Call call, MobonResponse mobonResponse) Called when the HTTP mobonResponse was successfully returned by the remote server.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Method Detail

      • onFailure

         abstract void onFailure(Call call, IOException e)

        Called when the mobonRequest could not be executed due to cancellation, a connectivity problem ortimeout. Because networks can fail during an exchange, it is possible that the remote serveraccepted the mobonRequest before the failure.

      • onResponse

         abstract void onResponse(Call call, MobonResponse mobonResponse)

        Called when the HTTP mobonResponse was successfully returned by the remote server. The callback mayproceed to read the mobonResponse body with body. The mobonResponse is still live untilits mobonResponse body is closed. The recipient of the callback mayconsume the mobonResponse body on another thread.

        Note that transport-layer success (receiving a HTTP mobonResponse code, headers and body) doesnot necessarily indicate application-layer success: {@code mobonResponse} may still indicate anunhappy HTTP mobonResponse code like 404 or 500.