title: Get all public methods declared in the class, not inherited
body: <p>What I want to get is the array of all public methods, and ONLY public ones, from the lowest classes in the inheritance tree. For example:</p>
  
  <pre><code>class MyClass {  }
  
  class MyExtendedClass extends MyClass {  }
  
  class SomeOtherClass extends MyClass {  }
  </code></pre>
  
  <p>And from the inside of MyClass I want to get all PUBLIC methods from MyExtendedClass and SomeOtherClass.</p>
  
  <p>I figured out I can use Reflection Class to do this, however when I do that, I also get methods from the MyClass, and I don't want to get them:</p>
  
  <pre><code>$class = new ReflectionClass('MyClass');
  $methods = $class-&gt;getMethods(ReflectionMethod::IS_PUBLIC);
  </code></pre>
  
  <p>Is there a way to do this? Or the only solution I have in this situation is just to filter out the outcomes of the Reflection Class?</p>