Пример #1
0
 /**
  * Scan for a list of pseudo-constants. A pseudo-constant is recognized by listing
  * any static properties which have corresponding static methods.
  *
  * This may be inefficient and should generally be avoided.
  *
  * @return array
  *   Array of string, constant names
  */
 public static function findConstants()
 {
     if (self::$constants === NULL) {
         self::$constants = array();
         foreach (self::$constantClasses as $class) {
             foreach (self::findConstantsByClass($class) as $constant) {
                 self::$constants[$constant] = $class;
             }
         }
     }
     return array_keys(self::$constants);
 }