src/File.php
public function open(string $filePath, string $mode)
    {
        $this->exists($filePath, $mode);

        $ptr = @fopen($filePath, $mode);

        if (false === $ptr) {
            throw new FileException("Unable to open $filePath.");
        }

        return $ptr;
    }
public function open(string $filePath, string $mode)
    {
        $this->exists($filePath, $mode);

        $ptr = @fopen($filePath, $mode);

        if (false === $ptr) {
            throw new FileException("Unable to open $filePath.");
        }

        return $ptr;
    }
public function open ( string $ filePath , string $ mode ) { $ this -> exists ( $ filePath , $ mode ) ; $ ptr = @ fopen ( $ filePath , $ mode ) ; if ( false === $ ptr ) { throw new FileException ( "Unable to open $filePath." ) ; } return $ ptr ; }
Open file in given mode.

@param string $filePath
@param string $mode

@throws FileException

@return resource
Open file in given mode .