title: Is it possible for an inner class to access outer class instance variables?
body: <p>Say I have the follow code:</p>
  
  <pre><code>class Outer {
     int n;
     class Inner {
     }
  }
  </code></pre>
  
  <p>Is it possible for an object of type Inner to access the instance variable n of its Outer object? (When I say its, I mean the Outer object that its associated with.) I understand that within a method of an inner class you can access outer class instance variables and also within the body (for example an instance variable for Inner could initialize to the value of an instnace variable of Outer), but is it possible to more directly access the Outer instance variables? For example, if inner were an object of type Inner, is there anything like inner.n given the code above?</p>
  
  <p>Sorry for the block of text: <strong>basically</strong>, if inner were an object of type Inner, is there anything like inner.n given the code above?</p>