public function create($report, $penaltys = null, $root = null)
{
$out = array();
if (count($report) === 1) {
$out[$root] = array('report' => $this->_parse($report[0]), 'score' => SCORE_FULL + $penaltys);
} else {
foreach ($report as $file => $_) {
$parts = explode('/', trim($file, './'));
$name = array_pop($parts);
$this->_insert($out, $parts, $name, array('report' => $this->_parse($_), 'score' => SCORE_FULL + $penaltys[$file], 'file' => $file));
}
}
$this->_out(json_encode($out));
}