java - Where is "this" pointing at? -


i know piece of code below far perfect want do. problem can't understand object "this" keyword pointing at.

public class browser extends jfilechooser{    public file browser_creation(){      int r;      jfilechooser browser1 = new jfilechooser();             r = browser1.showopendialog(this);       if (r == browser.approve_option) {         return browser1.getselectedfile();     }     else {         return null;     }   }   } 

this points current instance of browser. in other words, referring object being executed in.

here more information java tutorials: http://download.oracle.com/javase/tutorial/java/javaoo/thiskey.html


Comments

Popular posts from this blog

c++ - Is it possible to compile a VST on linux? -

c# - SharpSVN - How to get the previous revision? -

php cli reading files and how to fix it? -