/** * @param Tombstone $tombstone */ public function addTombstone(Tombstone $tombstone) { $this->tombstones[] = $tombstone; $position = FilePosition::createPosition($tombstone->getFile(), $tombstone->getLine()); $this->fileLineIndex[$position] = $tombstone; $relativePosition = FilePosition::createPosition($this->normalizeAndRelativePath($tombstone->getFile()), $tombstone->getLine()); $this->relativeFileLineIndex[$relativePosition] = $tombstone; $methodName = $tombstone->getMethod(); if (!isset($this->methodIndex[$methodName])) { $this->methodIndex[$methodName] = array(); } $this->methodIndex[$methodName][] = $tombstone; }
/** * @param Tombstone $tombstone */ public function addUndead(Tombstone $tombstone) { $this->undead[] = $tombstone; $this->initFileIndex($tombstone->getFile()); $this->perFile[$tombstone->getFile()]->addUndead($tombstone); }