You are here

public static function Enum::search in Drupal driver for SQL Server and SQL Azure 8.2

Return key for value

Parameters

$value:

Return value

mixed

1 call to Enum::search()
Enum::getKey in drivers/lib/Drupal/Driver/Database/sqlsrv/Component/Enum.php
Returns the enum key (i.e. the constant name).

File

drivers/lib/Drupal/Driver/Database/sqlsrv/Component/Enum.php, line 141

Class

Enum
Enum class.

Namespace

Drupal\Driver\Database\sqlsrv\Component

Code

public static function search($value) {
  return array_search($value, self::toArray(), true);
}