Asynctask: pass two or more values from doInBackground to onPostExecute

后端 未结 5 1309
无人及你
无人及你 2020-12-03 01:06

I have an Asynctask which retrieves two int vaules and i want to pass them to onPostExecute to show them on the view.
Here is my code:

    public class Q         


        
5条回答
  •  抹茶落季
    2020-12-03 01:44

    Have you tried making those two ints members of QueryServer?

    onPostExecute() doesn't run until after doInBackground() is finished, so there shouldn't be any threading issues.

提交回复
热议问题