public function getApiVersion()
    {
        $this->reader->seek($this->offset + 8);

        $version = unpack('H*', $this->reader->read(2));
        $version = hexdec($version[1]);

        // @codeCoverageIgnoreStart
        $version = sprintf(
            '%u.%u.%u',
            $version >> 12,
            ($version >> 8) & 0xF,
            ($version >> 4) & 0xF
        );
        // @codeCoverageIgnoreEnd

        return $version;
    }
public function getApiVersion()
    {
        $this->reader->seek($this->offset + 8);

        $version = unpack('H*', $this->reader->read(2));
        $version = hexdec($version[1]);

        // @codeCoverageIgnoreStart
        $version = sprintf(
            '%u.%u.%u',
            $version >> 12,
            ($version >> 8) & 0xF,
            ($version >> 4) & 0xF
        );
        // @codeCoverageIgnoreEnd

        return $version;
    }
public function getApiVersion ( ) { $ this -> reader -> seek ( $ this -> offset + 8 ) ; $ version = unpack ( 'H*' , $ this -> reader -> read ( 2 ) ) ; $ version = hexdec ( $ version [ 1 ] ) ; // @codeCoverageIgnoreStart $ version = sprintf ( '%u.%u.%u' , $ version >> 12 , ( $ version >> 8 ) & 0xF , ( $ version >> 4 ) & 0xF ) ; // @codeCoverageIgnoreEnd return $ version ; }
Returns the version of the archive file format.

This method will return the version of the file format used for this
archive file.

$version = $archive->getApiVersion();

> Note that this version number is not to be confused with the version
> number returned by `Phar::apiVersion()`, as that version number is
> used for new archives.

@see Phar::getVersion

@return string The version of the archive file formats.

@api
Returns the version of the archive file format .