/** * @param Report $report * @return string */ public function formatReport(Report $report) { return json_encode($report->toArray(), $this->options); }
public function toArray() { return ['class' => $this->class->getName(), 'methods' => array_map(function (ParsedMethod $cam) { return $cam->getClass()->getName() . '::' . $cam->getMethod()->name . '()'; }, $this->methods)] + parent::toArray(); }