A Service ਇੱਕ Android component ਹੈ UI ਤੋਂ ਬਿਨਾਂ operations ਕਰਨ ਲਈ — ਆਮ ਤੌਰ ਤੇ background ਵਿੱਚ ਲੰਬੇ ਸਮੇਂ ਚੱਲਣ ਵਾਲਾ ਕੰਮ। ਵੱਖ-ਵੱਖ ਕਿਸਮਾਂ (foreground, background, bound) ਹਨ, ਹਰ ਇੱਕ ਵੱਖਰੀ ਲੋੜਾਂ ਲਈ ਢੁਕਵੀਂ ਹੈ, ਹਾਲਾਂਕਿ ਆਧੁਨਿਕ Android ਬਹੁਤ ਮਾਮਲਿਆਂ ਵਿੱਚ WorkManager ਨੂੰ ਪਸੰਦ ਕਰਦਾ ਹੈ।
Service ਕਿਆ ਹੈ
A SERVICE runs operations WITHOUT a UI (not tied to a screen):
→ for work that should continue regardless of UI (or independent of any activity)
→ declared in the manifest; runs in the app's process (main thread by default — must
move heavy work off it!)
