35 lines
719 B
PHP
35 lines
719 B
PHP
<?php
|
|
namespace ProVM\Common\Define;
|
|
|
|
interface Parser
|
|
{
|
|
/**
|
|
* Determine if file is multiline
|
|
* @param string $filename
|
|
* @return bool
|
|
*/
|
|
public function isMultiline(string $filename): bool;
|
|
|
|
/**
|
|
* Get the total amount of errors
|
|
* @param string $filename
|
|
* @return int
|
|
*/
|
|
public function total(string $filename): int;
|
|
|
|
/**
|
|
* Parse line(s)
|
|
* @param mixed &$file_handler
|
|
* @return Log
|
|
*/
|
|
public function parse(mixed &$file_handler): Log;
|
|
|
|
/**
|
|
* Advance $offset errors
|
|
* @param mixed $file_handler
|
|
* @param int $offset
|
|
* @return void
|
|
*/
|
|
public function advance(mixed &$file_handler, int $offset): void;
|
|
}
|