You are here

public static function Enum::values in Drupal driver for SQL Server and SQL Azure 7.3

Same name and namespace in other branches
  1. 7.2 sqlsrv/enum.inc \Enum::values()

Returns instances of the Enum class of all Enum constants

Return value

array Constant name in key, Enum instance in value

File

sqlsrv/enum.inc, line 73

Class

Enum
Base Enum class

Code

public static function values() {
  $values = array();
  foreach (self::toArray() as $key => $value) {
    $values[$key] = new static($value);
  }
  return $values;
}