title: Java/JRE version change, Errors in Eclipse and more
body: <p>This might be a very stupid question but bear with me since I am new to Java/J2EE. I have installed JRE6 and JRE7 on my machine. I have set JAVA_HOME environment variable to point to my JRE6 directory. Also, in my eclipse, I have pointed the working JRE to JRE6. However, if run "java -version" in the terminal, it says current java version is 1.7 (pointing to JRE7).</p>
  
  <p>The problem I am actually facing is that eclipse gives me errors for the following iunterface:-</p>
  
  <pre><code>public interface IServiceHelper {
      public &lt;T extends Document&gt; Document SomeMethod(Object obj);
  
            // Error - Duplicate method SomeMethod(Object) in type IServiceHelper
      public &lt;T extends SomeClass&gt; SomeClass SomeMethod(Object obj);  
  
            // Error - Duplicate method SomeMethod(Object) in type IServiceHelper
      public &lt;T extends String&gt; String SomeMethod(Object obj);
  }
  </code></pre>
  
  <p>However, a maven build outside of eclipse in a terminal succeeds.</p>
  
  <p>The above interface may not be a good design and may be really some tricky code. Since this is an existing piece of code, I am not supposed to make changes. Please help me find out what is wrong with eclipse and/or JRE version.</p>