Get class constants list
<blockquote>
  <p><strong>Possible Duplicate:</strong><br>
  <a href="http://stackoverflow.com/questions/956401/can-i-get-consts-defined-on-a-php-class">Can I get CONST&#39;s defined on a PHP class?</a>  </p>
</blockquote>



<pre><code>class ApplicationMode
{
    const production = 0;
    const development = 1;
    const testing = 2;
    public function getApplicationModes()
    {
        return get_class_vars('ApplicationMode');
    }
}
</code></pre>

<p>i've got a class like this, and in getApplicationModes method i would like to return a list of all constants as array(key => value). The problem is that get_class_vars doesnt list constants. is there a way to get all class constants list?</p>
