private function getStream() { if (!$this->stream) { Assert::isNotNull($this->queue->getFileName()); $this->stream = FileOutputStream::create($this->queue->getFileName(), true); } return $this->stream; }
public function __construct(CachePeer $peer, $logfile, $isWeb = true, $appendFile = true) { $this->peer = $peer; $this->isWeb = $isWeb; $this->logger = StreamLogger::create()->setOutputStream(FileOutputStream::create($logfile, $appendFile)); }