/** * Load all logs. * * @return \Arcanedev\LogViewer\Entities\LogCollection */ private function load() { foreach ($this->filesystem->dates(true) as $date => $path) { $log = Log::make($date, $path, $this->filesystem->read($date)); $this->put($date, $log); } return $this; }
/** * Check all log files. */ private function checkLogFiles() { foreach ($this->filesystem->all() as $path) { $this->checkLogFile($path); } }
/** * Set the log pattern. * * @param string $date * @param string $prefix * @param string $extension * * @return \Arcanedev\LogViewer\Utilities\Factory */ public function setPattern($prefix = FilesystemContract::PATTERN_PREFIX, $date = FilesystemContract::PATTERN_DATE, $extension = FilesystemContract::PATTERN_EXTENSION) { $this->filesystem->setPattern($prefix, $date, $extension); return $this; }
/** * Get all valid log files. * * @return array */ public function files() { return $this->filesystem->logs(); }