src/StreamExtractor.php
public function getHeader()
    {
        if ($this->headerContents) {
            return $this->headerContents;
        }

        if (!$this->headerLen) {
            $this->determineHeaderLength();
        }

        fseek($this->fp, $this->headerStart, SEEK_SET);

        $read = 0;
        $bindata = '';
        while ($read < $this->headerLen && ($buff = fread($this->fp, $this->headerLen - $read))) {
            $read += strlen($buff);
            $bindata .= $buff;
        }
        unset($buff);

        $this->headerContents = gzinflate($bindata, $this->options['memoryLimit']);
        unset($bindata);

        if (!strlen($this->headerContents)) {
            throw new RecAnalystException(
                'Cannot decompress header section',
                RecAnalystException::HEADER_DECOMPRESSERROR
            );
        }

        return $this->headerContents;
    }
public function getHeader()
    {
        if ($this->headerContents) {
            return $this->headerContents;
        }

        if (!$this->headerLen) {
            $this->determineHeaderLength();
        }

        fseek($this->fp, $this->headerStart, SEEK_SET);

        $read = 0;
        $bindata = '';
        while ($read < $this->headerLen && ($buff = fread($this->fp, $this->headerLen - $read))) {
            $read += strlen($buff);
            $bindata .= $buff;
        }
        unset($buff);

        $this->headerContents = gzinflate($bindata, $this->options['memoryLimit']);
        unset($bindata);

        if (!strlen($this->headerContents)) {
            throw new RecAnalystException(
                'Cannot decompress header section',
                RecAnalystException::HEADER_DECOMPRESSERROR
            );
        }

        return $this->headerContents;
    }
public function getHeader ( ) { if ( $ this -> headerContents ) { return $ this -> headerContents ; } if ( ! $ this -> headerLen ) { $ this -> determineHeaderLength ( ) ; } fseek ( $ this -> fp , $ this -> headerStart , SEEK_SET ) ; $ read = 0 ; $ bindata = '' ; while ( $ read < $ this -> headerLen && ( $ buff = fread ( $ this -> fp , $ this -> headerLen - $ read ) ) ) { $ read += strlen ( $ buff ) ; $ bindata .= $ buff ; } unset ( $ buff ) ; $ this -> headerContents = gzinflate ( $ bindata , $ this -> options [ 'memoryLimit' ] ) ; unset ( $ bindata ) ; if ( ! strlen ( $ this -> headerContents ) ) { throw new RecAnalystException ( 'Cannot decompress header section' , RecAnalystException :: HEADER_DECOMPRESSERROR ) ; } return $ this -> headerContents ; }
Read or return the Recorded Game file's header block.

@return string
Read or return the Recorded Game file s header block .