multithreading - On what thread does a method initiated by NSTimer run on? -
when method amethod
runs result of nstimer so:
nstimer* thetimer = [nstimer scheduledtimerwithtimeinterval: 1.0 target: self selector: @selector(amethod:) userinfo: nil repeats: yes];
does amethod
run on thread thetimer
called (the main thread), or on separate thread? also, nstimer continue repeating while amethod
running, or wait until amethod
has finished?
nstimer
calls selector passed in selector:
parameter on thread timer scheduled. may or may not main thread.
Comments
Post a Comment