Qualified this construct
Member Inner Class have an implicit reference to an instance of the enclosing (outer) class. Qualified This refers to this instance.
If the outer class is A and inner class is B, you can refer to this instance of A from B as A.this
.
Since we are using a Qualifier along with this
Object Context Qualifiers in Java, to form a fully Qualified Identifier, it is called "Qualified" this
.
Reference
What does "qualified this" construct mean in java?
In Effective Java inside the item "Item 22: Favor static member classes over nonstatic" Josh Bloch says:
Each instance of a nonstatic member class is implicitly associated with an enclosing instance of its containing class. Within instance methods of a nonstatic member class, you can invoke methods on the enclosing instance or obtain a reference to the enclosing instance using the qualified this construct.
Backlinks