Esempio n. 1
0
 /**
  * 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;
 }
Esempio n. 2
0
 /**
  * Check all log files.
  */
 private function checkLogFiles()
 {
     foreach ($this->filesystem->all() as $path) {
         $this->checkLogFile($path);
     }
 }
Esempio n. 3
0
 /**
  * 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;
 }
Esempio n. 4
0
 /**
  * Get all valid log files.
  *
  * @return array
  */
 public function files()
 {
     return $this->filesystem->logs();
 }