Hi Ted Thanks for your help it is really appreciated. I have gone thru the links that you have provided but i am looking for a simple exaplanation of using static classes in Hadoop/MR while syntactically i know how the static classes and variables r referred, i am wondering if there was something more than that we use static classes. In other words assuming static classes r loaded at the time the classes r loaded and not at the time the object is created and the timespan of objects of static classes r less than normal classes. Please let me know if this make sense and provide any additional info if you could. Thanks again. Sai
________________________________ From: Ted Yu <[email protected]> To: [email protected]; Sai Sai <[email protected]> Sent: Thursday, 28 March 2013 9:41 AM Subject: Re: Static class vs Normal Class when to use Take a look at Effective Java 2nd edition: Item 22: Favor static member classes over nonstatic On Wed, Mar 27, 2013 at 9:05 PM, Ted Yu <[email protected]> wrote: See http://stackoverflow.com/questions/1353309/java-static-vs-non-static-inner-class > > >I believe Josh Bloch covers this in his famous book. > > > >On Wed, Mar 27, 2013 at 9:01 PM, Sai Sai <[email protected]> wrote: > >In some examples/articles sometimes they use: >>public static class MyMapper >> >> >>and sometimes they use >> >> >>public class MyMapper >> >> >> >>When/why should we use static vs normal class. >> >> >>ThanksSai >
