Reputation: 1794
I have some method that is asynchronous so I cannot get response value from it to use in other place (in this case is Retrofit call back method). So do we have any way to change the asynchronous method to synchronous method and get values from it?
Upvotes: 2
Views: 1946
Reputation: 8304
Retrofit should have synchronous counterparts to asynchronous calls. Check out this tutorial.
Upvotes: 1
Reputation: 546
You just handle result in asynchronous callback then dispatch it to something else to process on business logic, for example a Controller.
Upvotes: 2