How to create a receiver without registering it in manifest file?
Every component has to get registered in the manifest file.
We can register receiver dynamically in code.
we can register receiver statically in code.
option 1 is true because, with out intent-filter test it is not possible to launch code.
Every component has to get registered in the manifest file. But there is an exception for this rule, a broad cast receiver can get registered dynamically in code. Because there may be some scenarios where we need handle broad casted messages only when our application is running. If we register it in manifest file statically, then even if our app is not running, it may trigger our broad cast receiver.
Back To Top