public static function getName($value)
    {
        $key = array_search($value, static::toArray(), true);  // Search using strict comparison

        if ($key === false) {
            static::triggerUndefinedConstantError($value);
        }

        return $key;
    }
public static function getName($value)
    {
        $key = array_search($value, static::toArray(), true);  // Search using strict comparison

        if ($key === false) {
            static::triggerUndefinedConstantError($value);
        }

        return $key;
    }
public static function getName ( $ value ) { $ key = array_search ( $ value , static :: toArray ( ) , true ) ; // Search using strict comparison if ( $ key === false ) { static :: triggerUndefinedConstantError ( $ value ) ; } return $ key ; }
Get the name of the member that holds given value

<p class="alert">This method is type-sensitive - see the example below.</p>
<h3>Use case</h3>
You have a value that is defined in an enumeration and you would like
to know the name of the enumeration member that holds this value.

<h3>Example</h3>
```
class Animal extends Dreamscapes\Enumeration
{
const Horse = 0;
const Dog = 1;
}

echo Animal::getName(0); // Prints 'Horse'
echo Animal::getName('0'); // Returns null, method is type-sensitive
```

@param     string    $value      The member's expected value (type-sensitive)
@return    string    The name of the member that holds this value or null if not defined
Get the name of the member that holds given value