BaseEnumRoutable : remove unused getEnumName

add NotImplementedException for all unsued methods
This commit is contained in:
Jérémy Munsch 2021-09-11 22:44:06 +02:00
parent 3e654f5d3c
commit 4cc27e6769
No known key found for this signature in database
GPG key ID: 677E1F9F80C16560

View file

@ -21,7 +21,7 @@ abstract class BaseEnumRoutable extends BaseEnum implements UrlRoutable
*/
public function getRouteKey()
{
return $this->value;
throw new NotImplementedException('getRouteKey not implemented, should not be used.');
}
/**
@ -31,7 +31,7 @@ abstract class BaseEnumRoutable extends BaseEnum implements UrlRoutable
*/
public function getRouteKeyName()
{
throw new NotImplementedException('getRouteKeyName not implemented, should not be used');
throw new NotImplementedException('getRouteKeyName not implemented, should not be used.');
}
/**
@ -69,17 +69,6 @@ abstract class BaseEnumRoutable extends BaseEnum implements UrlRoutable
*/
public function resolveChildRouteBinding($childType, $value, $field)
{
throw new NotImplementedException('resolveChildRouteBinding not implemented, should not be used');
}
/**
* Get the Enum name from class name
*
* @return string
*/
public static function getEnumName()
{
$cls = explode('\\', static::class);
return array_pop($cls);
throw new NotImplementedException('resolveChildRouteBinding not implemented, should not be used.');
}
}