如何使原子php-debug显示数组的所有元素?

时间:2016-11-07 08:21:49

标签: php atom-editor

67个数组元素中只有31个显示在watchpoints

php-debug elements

3 个答案:

答案 0 :(得分:1)

如果您使用带有atom的xdebug,请检查以下xdebug设置:

xdebug.var_display_max_depth
xdebug.var_display_max_children
xdebug.var_display_max_data

另见帖子:How to get xdebug var_dump to show full object/array

原子中显示的子项数量可能也有限制。

答案 1 :(得分:-1)

get_class_methods(' classname'),只能获得公共功能

$class = new ReflectionClass($_brand);
$methods = $class->getMethods();
var_dump($methods);

答案 2 :(得分:-1)

get_class_methods()对当前范围敏感,这意味着如果您这样做:

class brand{
  public    function publicMethod(){}
  private   function privateMethod(){}
  protected function protectedMethod(){}

  static    function getMethods(){
    return get_class_methods(__CLASS__);
  }
}

print_r(brand::getMethods());

您将收到公共,私人,受保护和静态方法的完整列表。