\Seld\PharUtilsTimestamps

Summary

Methods
Properties
Constants
__construct()
updateTimestamps()
save()
No public properties found
No constants found
No protected methods found
No protected properties found
N/A
readUint()
determineSignatureBegin()
$contents
N/A

Properties

$contents

$contents : 

Type

Methods

__construct()

__construct(string  $file) 

Parameters

string $file

path to the phar file to use

updateTimestamps()

updateTimestamps(integer|\Seld\PharUtils\DateTime|string  $timestamp = null) 

Updates each file's unix timestamps in the PHAR

The PHAR signature can then be produced in a reproducible manner.

Parameters

integer|\Seld\PharUtils\DateTime|string $timestamp

Date string or DateTime or unix timestamp to use

save()

save(string  $path, integer  $signatureAlgo) : boolean

Saves the updated phar file, optionally with an updated signature.

Parameters

string $path
integer $signatureAlgo

One of Phar::MD5, Phar::SHA1, Phar::SHA256 or Phar::SHA512

Returns

boolean

readUint()

readUint(  $pos,   $bytes) 

Parameters

$pos
$bytes

determineSignatureBegin()

determineSignatureBegin() : integer

Determine the beginning of the signature.

Returns

integer