So, I'm working on a barcode decoder, which, after we get the barcode, multiply the API via the Internet to decrypt what was just scanned. The thing is, I need to bind some XML parsing together, and I don't know if I am doing this correctly.
So, after scanning the barcode, my program calls ASyncTask, which passes the API to get the product name. After it has a name, I want it to call another ASyncTask. I know that this is possible by creating an ASyncTaks instance in onPostExecute()
another, but I think this is wrong, because it looks like boxes inside boxes. So is it not possible / better to instantiate a second ASyncTask inside my main operation and make it wait until my first ASyncTask is complete?
(English is not my main language, I hope I have made it clear).
source share