我有3节课。。
第一类:
<?php
include "two.php";
include "three.php";
class One{
public function __construct(){
$two = new Two($this);
$three = new Three($two);
}
}
$api = new One;
?>
第 2 类:
<?php
class Two extends AOP {
public function __construct($obj){
//blablabla
}
}
?>
第 3 类:
<?php
class Three extends AOP {
public function __construct($obj){
echo get_class($obj);
}
}
?>
但我希望结果必须输出“一”。如何从对象内部的对象中获取类名?