php abstract class extending another abstract class

前端 未结 3 2115
借酒劲吻你
借酒劲吻你 2021-01-03 17:42

Is it possible in PHP, that an abstract class inherits from an abstract class?

For example,

abstract class Generic {
    abstract public function a(         


        
3条回答
  •  说谎
    说谎 (楼主)
    2021-01-03 18:12

    Yes it is possible however your code would not work if you called $VeryConcreteObject->b()

    Here is more detailed explanation.

提交回复
热议问题