I mistakenly defined the method signature as
abstract static public function mapAttributeKeys(array $attributes)
It works properly, but while I'm refactoring the code, I see it is not looks well and it should be as following according to my habit.
abstract public static function mapAttributeKeys(array $attributes)
I little surprised how these two works. I was thinking the above syntax is a wrong syntax.
So these two are working. Is there any reason why the definition is not stricted ? Or something like a pattern match here ?
My actual aim is to learn why these flexibility is exist ? Is there any special approach or implementation trick exist ?
Updated :
I saw https://stackoverflow.com/a/10740068/1147648 this explanation really meaningful.
An abstract function will never be static, in any kind of language
if it is true, why there is implementation exist ?
Even in symfony validator loader.
https://github.com/symfony/validator/blob/master/Tests/Mapping/Loader/AbstractStaticMethodLoader.php