2013-08-14 21:37:24 +10:00
|
|
|
<?php
|
|
|
|
|
|
|
|
namespace DebugBar\Tests\DataCollector;
|
|
|
|
|
|
|
|
use DebugBar\DataCollector\DataCollector;
|
|
|
|
use DebugBar\DataCollector\Renderable;
|
|
|
|
|
|
|
|
class MockCollector extends DataCollector implements Renderable
|
|
|
|
{
|
|
|
|
protected $data;
|
|
|
|
protected $name;
|
|
|
|
protected $widgets;
|
|
|
|
|
|
|
|
public function __construct($data = array(), $name = 'mock', $widgets = array())
|
|
|
|
{
|
|
|
|
$this->data = $data;
|
|
|
|
$this->name = $name;
|
|
|
|
$this->widgets = $widgets;
|
|
|
|
}
|
2014-01-16 21:41:41 +00:00
|
|
|
|
2013-08-14 21:37:24 +10:00
|
|
|
public function collect()
|
|
|
|
{
|
|
|
|
return $this->data;
|
|
|
|
}
|
|
|
|
|
|
|
|
public function getName()
|
|
|
|
{
|
|
|
|
return $this->name;
|
|
|
|
}
|
|
|
|
|
|
|
|
public function getWidgets()
|
|
|
|
{
|
|
|
|
return $this->widgets;
|
|
|
|
}
|
2014-01-16 21:41:41 +00:00
|
|
|
}
|