svn: /phpdoc/en/trunk/reference/phar/ Phar/getMetadata.xml Phar/startBuffering.xml PharFileInfo/getMetadata.xml PharFileInfo/setMetadata.xml using.xml
| From: | Jakub Vrana | Date: | Fri, 13 Jan 2012 11:42:48 +0000 |
| Subject: | svn: /phpdoc/en/trunk/reference/phar/ Phar/getMetadata.xml Phar/startBuffering.xml PharFileInfo/getMetadata.xml PharFileInfo/setMetadata.xml using.xml | ||
| Groups: | php.doc.cvs | ||
| Request: | Send a blank email to doc-cvs+get-9457@lists.php.net to get a copy of this message | ||
vrana Fri, 13 Jan 2012 11:42:48 +0000
Revision: http://svn.php.net/viewvc?view=revision&revision=322193
Log:
MetaData is Metadata
Changed paths:
U phpdoc/en/trunk/reference/phar/Phar/getMetadata.xml
U phpdoc/en/trunk/reference/phar/Phar/startBuffering.xml
U phpdoc/en/trunk/reference/phar/PharFileInfo/getMetadata.xml
U phpdoc/en/trunk/reference/phar/PharFileInfo/setMetadata.xml
U phpdoc/en/trunk/reference/phar/using.xml
Modified: phpdoc/en/trunk/reference/phar/Phar/getMetadata.xml
===================================================================
--- phpdoc/en/trunk/reference/phar/Phar/getMetadata.xml 2012-01-13 11:34:53 UTC (rev 322192)
+++ phpdoc/en/trunk/reference/phar/Phar/getMetadata.xml 2012-01-13 11:42:48 UTC (rev 322193)
@@ -1,14 +1,14 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- $Revision$ -->
-<refentry xmlns="http://docbook.org/ns/docbook"
xml:id="phar.getmetadata">
+<refentry xmlns="http://docbook.org/ns/docbook"
xml:id="phar.getMetadata">
<refnamediv>
- <refname>Phar::getMetaData</refname>
+ <refname>Phar::getMetadata</refname>
<refpurpose>Returns phar archive meta-data</refpurpose>
</refnamediv>
<refsect1 role="description">
&reftitle.description;
<methodsynopsis>
- <type>mixed</type><methodname>Phar::getMetaData</methodname>
+ <type>mixed</type><methodname>Phar::getMetadata</methodname>
<void/>
</methodsynopsis>
@@ -35,7 +35,7 @@
&reftitle.examples;
<para>
<example>
- <title>A <function>Phar::getMetaData</function> example</title>
+ <title>A <function>Phar::getMetadata</function> example</title>
<para>
</para>
<programlisting role="php">
@@ -46,8 +46,8 @@
try {
$p = new Phar(dirname(__FILE__) . '/brandnewphar.phar', 0,
'brandnewphar.phar');
$p['file.php'] = '<?php echo "hello";';
- $p->setMetaData(array('bootstrap' => 'file.php'));
- var_dump($p->getMetaData());
+ $p->setMetadata(array('bootstrap' => 'file.php'));
+ var_dump($p->getMetadata());
} catch (Exception $e) {
echo 'Could not modify phar:', $e;
}
Modified: phpdoc/en/trunk/reference/phar/Phar/startBuffering.xml
===================================================================
--- phpdoc/en/trunk/reference/phar/Phar/startBuffering.xml 2012-01-13 11:34:53 UTC (rev 322192)
+++ phpdoc/en/trunk/reference/phar/Phar/startBuffering.xml 2012-01-13 11:42:48 UTC (rev 322193)
@@ -66,7 +66,7 @@
$p['file2.txt'] = 'there';
$p['file2.txt']->setCompressedGZ();
$p['file3.txt'] = 'babyface';
-$p['file3.txt']->setMetaData(42);
+$p['file3.txt']->setMetadata(42);
$p->setStub("<?php
function __autoload($class)
{
Modified: phpdoc/en/trunk/reference/phar/PharFileInfo/getMetadata.xml
===================================================================
--- phpdoc/en/trunk/reference/phar/PharFileInfo/getMetadata.xml 2012-01-13 11:34:53 UTC (rev 322192)
+++ phpdoc/en/trunk/reference/phar/PharFileInfo/getMetadata.xml 2012-01-13 11:42:48 UTC (rev 322193)
@@ -1,14 +1,14 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- $Revision$ -->
-<refentry xmlns="http://docbook.org/ns/docbook"
xml:id="pharfileinfo.getmetadata">
+<refentry xmlns="http://docbook.org/ns/docbook"
xml:id="pharfileinfo.getMetadata">
<refnamediv>
- <refname>PharFileInfo::getMetaData</refname>
+ <refname>PharFileInfo::getMetadata</refname>
<refpurpose>Returns file-specific meta-data saved with a file</refpurpose>
</refnamediv>
<refsect1 role="description">
&reftitle.description;
<methodsynopsis>
- <type>mixed</type><methodname>PharFileInfo::getMetaData</methodname>
+ <type>mixed</type><methodname>PharFileInfo::getMetadata</methodname>
<void/>
</methodsynopsis>
@@ -34,7 +34,7 @@
&reftitle.examples;
<para>
<example>
- <title>A <function>PharFileInfo::getMetaData</function> example</title>
+ <title>A <function>PharFileInfo::getMetadata</function> example</title>
<para>
</para>
<programlisting role="php">
@@ -45,8 +45,8 @@
try {
$p = new Phar(dirname(__FILE__) . '/brandnewphar.phar', 0,
'brandnewphar.phar');
$p['file.txt'] = 'hello';
- $p['file.txt']->setMetaData(array('user' => 'bill',
'mime-type' => 'text/plain'));
- var_dump($p['file.txt']->getMetaData());
+ $p['file.txt']->setMetadata(array('user' => 'bill',
'mime-type' => 'text/plain'));
+ var_dump($p['file.txt']->getMetadata());
} catch (Exception $e) {
echo 'Could not create/modify brandnewphar.phar: ', $e;
}
Modified: phpdoc/en/trunk/reference/phar/PharFileInfo/setMetadata.xml
===================================================================
--- phpdoc/en/trunk/reference/phar/PharFileInfo/setMetadata.xml 2012-01-13 11:34:53 UTC (rev 322192)
+++ phpdoc/en/trunk/reference/phar/PharFileInfo/setMetadata.xml 2012-01-13 11:42:48 UTC (rev 322193)
@@ -2,18 +2,18 @@
<!-- $Revision$ -->
<refentry xmlns="http://docbook.org/ns/docbook"
xml:id="pharfileinfo.setmetadata">
<refnamediv>
- <refname>PharFileInfo::setMetaData</refname>
+ <refname>PharFileInfo::setMetadata</refname>
<refpurpose>Sets file-specific meta-data saved with a file</refpurpose>
</refnamediv>
<refsect1 role="description">
&reftitle.description;
<methodsynopsis>
- <type>void</type><methodname>PharFileInfo::setMetaData</methodname>
+ <type>void</type><methodname>PharFileInfo::setMetadata</methodname>
<methodparam><type>mixed</type><parameter>metadata</parameter></methodparam>
</methodsynopsis>
<para>
- <function>PharFileInfo::setMetaData</function> should only be used to store
customized data in a file
+ <function>PharFileInfo::setMetadata</function> should only be used to store
customized data in a file
that cannot be represented with existing information stored with a file.
Meta-data can significantly slow down the performance of loading a phar
archive if the data is large, or if there are many files containing meta-data.
@@ -61,7 +61,7 @@
&reftitle.examples;
<para>
<example>
- <title>A <function>PharFileInfo::setMetaData</function> example</title>
+ <title>A <function>PharFileInfo::setMetadata</function> example</title>
<para>
</para>
<programlisting role="php">
@@ -72,7 +72,7 @@
try {
$p = new Phar(dirname(__FILE__) . '/brandnewphar.phar', 0,
'brandnewphar.phar');
$p['file.txt'] = 'hello';
- $p['file.txt']->setMetaData(array('user' => 'bill',
'mime-type' => 'text/plain'));
+ $p['file.txt']->setMetadata(array('user' => 'bill',
'mime-type' => 'text/plain'));
var_dump($p['file.txt']->getMetaData());
} catch (Exception $e) {
echo 'Could not create/modify phar: ', $e;
Modified: phpdoc/en/trunk/reference/phar/using.xml
===================================================================
--- phpdoc/en/trunk/reference/phar/using.xml 2012-01-13 11:34:53 UTC (rev 322192)
+++ phpdoc/en/trunk/reference/phar/using.xml 2012-01-13 11:42:48 UTC (rev 322193)
@@ -72,7 +72,7 @@
echo file_get_contents($file->getPathName()) . "\n"; // display contents;
}
if (isset($p['internal/file.php'])) {
- var_dump($p['internal/file.php']->getMetaData());
+ var_dump($p['internal/file.php']->getMetadata());
}
// create a new phar - phar.readonly must be 0 in php.ini
@@ -102,9 +102,9 @@
$p['images/wow.jpg'] = file_get_contents('images/wow.jpg');
// any value can be saved as file-specific meta-data
- $p['images/wow.jpg']->setMetaData(array('mime-type' =>
'image/jpeg'));
+ $p['images/wow.jpg']->setMetadata(array('mime-type' =>
'image/jpeg'));
$p['index.php'] = file_get_contents('index.php');
- $p->setMetaData(array('bootstrap' => 'index.php'));
+ $p->setMetadata(array('bootstrap' => 'index.php'));
// save the phar archive to disk
$p->stopBuffering();
@@ -344,7 +344,7 @@
<para>
In addition, the <classname>Phar</classname> object is the only way to access
Phar-specific metadata, through
- <function>Phar::getMetaData</function>,
+ <function>Phar::getMetadata</function>,
and the only way to set or retrieve a Phar archive's PHP loader stub through
<function>Phar::getStub</function> and
<function>Phar::setStub</function>.