Where to use Local inner classes
<p>Could you please explain me clearly "where do we need to use local inner classes"?</p>

<p>Example:</p>

<pre><code>public class LocalTest
{

    int b=30;
    void display()
    {
        class Local{ 
            void msg()
            {

                 System.out.println(b);
            }       
        }

        Local l = new Local();
        l.msg();
    }

    public static void main(String args[])
    {
        LocalTest lt = new LocalTest();
        lt.display();
    }
}
</code></pre>

<p>Here <code>Local class</code> is a Local inner class. It is useful only for  <code>display()</code>. In which type of situations do we use these local inner classes ?</p>
