Closed shaiamir closed 7 years ago
Very much appreciated, thank you!
In general, it is better to create separate pull requests for individual features, but we'll be able to dissect this pull request into its original parts here.
It is closed because the target branch does not exist anymore (it was not created against master
).
Regarding the looper: Why did you need to set it manually? Right now, all callbacks should execute on the UI thread already. And if you don't want that, you probably don't want another specific thread but the calling thread (in each individual case), right?
Will do a commit per feature next time.
Regarding the Looper: I have a background thread that works with Meteor (not he UI thread). So it is more convenient to have all Android-DDP callbacks issued on my background thread (using its Looper) instead of having to handle moving the callback event from the UI thread to my background thread. And, if I understand your comment regarding the correlation between the calling thread and the callback thread, I would not tie both of them together and leave the flexibility to the developer (i.e. call Android-DDP from any thread and receive callbacks on the selected Looper thread). Thanks, Shai
Add callback that is executed whenever a subscription stopped and there are no listeners waiting for it (i.e. after subscription is ready).
Added option to select the looper that all callbacks will be fired on. This already makes sure that callbacks are fired on the user thread.
Exposed getLoginToken() so that other access methods (REST calls) can use the same login information.