title: getClass() returning java.lang.Class [Reflection]
body: <p>So upon getting the parameter(s) for a method via Reflection:</p>
  
  <pre><code>Class&lt;?&gt;[] params = m.getParameterTypes();
  </code></pre>
  
  <p>And assuming I'm looping through methods and looking for a method with only one parameter:</p>
  
  <pre><code>if(params.length &gt; 1) {
       continue;
  }
  </code></pre>
  
  <p>Then getting that parameter if the length of the params array is 1:</p>
  
  <pre><code>Class&lt;?&gt; par = params[0];
  </code></pre>
  
  <p>When I try printing out the parameter's class with the getClass() method, it returns java.lang.Class.</p>
  
  <p>However, when I get the superclass with the getSuperclass() method, it returns the superclass.</p>
  
  <p>So for example:</p>
  
  <pre><code>System.out.println(par.getClass());
  System.out.println(par.getSuperclass());
  </code></pre>
  
  <p>Assume the parameter of the method we have is a class called "PlayerDeathEvent", which extends the abstract "Event" class.</p>
  
  <p>That being said, the output would be:</p>
  
  <pre><code>java.lang.Class
  org.mypackage.Event
  </code></pre>
  
  <p>Is there a reason why this is occurring? I found a way around this with getCanonicalName, but I'm very curious as to why this occurs.</p>