Phar::setMetadata() - Phar类
Phar::setMetadata()
(PHP 5 >= 5.3.0, PHP 7, PECL phar >= 1.0.0)
Sets phar archive meta-data
说明
publicPhar::setMetadata(mixed $metadata): voidNote:此方法需要将php.ini中的phar.readonly设为0以适合Phar对象.否则,将抛出PharException.
Phar::setMetadata() should be used to store customized data that describes something about the phar archive as a complete entity.PharFileInfo::setMetadata() should be used for file-specific meta-data. Meta-data can slow down the performance of loading a phar archive if the data is large.
Some possible uses for meta-data include specifying which file within the archive should be used to bootstrap the archive, or the location of a file manifest like » PEAR's package.xml file. However, any useful data that describes the phar archive may be stored.
参数
$metadataAny PHP variable containing information to store that describes the phar archive
返回值
没有返回值。
范例
A Phar::setMetadata() example
鹏仔微信 15129739599 鹏仔QQ344225443 鹏仔前端 pjxi.com 共享博客 sharedbk.com
图片声明:本站部分配图来自网络。本站只作为美观性配图使用,无任何非法侵犯第三方意图,一切解释权归图片著作权方,本站不承担任何责任。如有恶意碰瓷者,必当奉陪到底严惩不贷!