What is List view context in android? Context defines the current state of object and application. Context provides access to things like creating new Activity …

Nguồn:https://u-os.org/

Author

18 Comments

  1. Ashish Kushwaha Reply

    bro u made see what i was not able to …thanks to made me cross the road

  2. Mohamed Jeylani Reply

    I really admire you the way you explain. You are wonderful. I am very thankful to you. Keep the good work.

  3. raghavendra rao Reply

    Please elaborate more with some examples. If context is an abstract class then explain about the methods to be implemented. You are simply reading the definition, kindly explain what are the application resources and how context will help in getting access to that resources.

  4. Waddah Mustafa Reply

    what i get generally is that objects that are not descendant of the Context class, they need to know to whom they belong,
    eg: you Instantiated a new TextView
    TextView textView;
    and in ur application u have Multiple Activites (lets assume Screens), now in order for that textview object to be created it needs to know in which screen it should appear, and when you pass "this" to the constructor ie:
    TextView textView = new TextView(this);
    u r actually setting the location where it should exist to the current activity. but u can pass any context object other than the current activity depending on what u need.

  5. Waddah Mustafa Reply

    So why should i pass a context anyway, what is the benefit from that?

  6. Geraldo Magalhaes Reply

    Congratulation Dude. You did solve my doubts. That was the explanation i expected to see.

  7. Battambang Innovation Reply

    Omg…this is the very cleared explain video I have ever watch… Thank you very much brother. You saved me to clear this.

  8. Pranay Sawant Reply

    what is difference between getContext, getApplicationContext, MainActivit.this ? what is best scenario to use all of them? also difference between Activity level context and application level context?

  9. Ricardo Avila Reply

    Dude Excellent!!!! I loved the way you explained…. Thanks for sharing your knowledge, the power of universe will pay you off!! Wish you could have a video tutorial for every android concept I dont understand!! jejeje

Write A Comment