I am busy learning android and I came across the getApplicationContext
method. I didn't really understand what it was used for and what it's purpose is.
Asked
Active
Viewed 3.3k times
9
-
http://stackoverflow.com/questions/7298731/when-to-call-activity-context-or-application-context. check the link – Raghunandan May 21 '13 at 16:55
1 Answers
4
The Context object is used across the application to do many things like access resources that the Android OS has allocated for you.
- using getSystemService, you get the handle of your service and you can do wonders.
- pass the context object to your classes to do Toast
It is useful and powerful if used correctly.

Siddharth
- 9,349
- 16
- 86
- 148