protected function isValid($value)
    {
        $value = (string) $value;
        foreach (static::$enumConstants[get_class($this)] as $constantValue) {
            if ($value === (string) $constantValue) {
                return true;
            }
        }
        return false;
    }
protected function isValid($value)
    {
        $value = (string) $value;
        foreach (static::$enumConstants[get_class($this)] as $constantValue) {
            if ($value === (string) $constantValue) {
                return true;
            }
        }
        return false;
    }
protected function isValid ( $ value ) { $ value = ( string ) $ value ; foreach ( static :: $ enumConstants [ get_class ( $ this ) ] as $ constantValue ) { if ( $ value === ( string ) $ constantValue ) { return true ; } } return false ; }
Check if the value on this enum is a valid value for the enum

@param mixed $value
@return boolean
Check if the value on this enum is a valid value for the enum