Task execution with app not started [duplicate]

1

I want to make an app that will make queries from time to time in an API that returns JSON , processes and creates a notification.

It would be the same as Whatsapp, which even closed (without being open or in the task manager) will run this task.

As I researched, it would be broadcastReceiver , where it will "register" my task (such as a "windows service") and the app being closed, or device restarted, etc., will continue to run .

I would like to know if my understanding is correct (according to my analogy with the "windows service"), if I need to give an "initial command" for it to "register" this task, if there is another way to do it, any kind of past content that will be used to study the case.

    
asked by anonymous 09.03.2018 / 13:27

0 answers