Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What is the "context" meaning in Android? [duplicate]

Tags:

android

Possible Duplicate:
What is Context in Android?

I think its a very interesting question: What is the "context" meaning/concept in Android ?

Almost any things/object need context to working properly. What is the "context" represented? An integer ? a block of memory ?? or .....

like image 242
hxc Avatar asked Oct 15 '10 11:10

hxc


People also ask

What is an Context in Android?

Definition. it's the context of current state of the application/object. It lets newly-created objects understand what has been going on. Typically, you call it to get information regarding another part of your program (activity and package/application).

What is Context in app?

A Context provides access to information about the application state. It provides Activities, Fragments, and Services access to resource files, images, themes/styles, and external directory locations.

What is context menu android?

A context menu is a floating menu that appears when the user performs a long-click on an element. It provides actions that affect the selected content or context frame.

What is Context and intent in android?

context. startActivity(new Intent(context, ActivityClass. class)); This call to startActivity sends the Intent to the Android system, which is then in charge of creating and opening the activity that you have specified.


1 Answers

Interface to global information about an application environment. This is an abstract class whose implementation is provided by the Android system. It allows access to application-specific resources and classes, as well as up-calls for application-level operations such as launching activities, broadcasting and receiving intents, etc.

Source: http://developer.android.com/reference/android/content/Context.html

like image 55
Asahi Avatar answered Sep 24 '22 22:09

Asahi